stagexl_isometric 0.1.2

  • README.md
  • CHANGELOG.md
  • Example
  • Installing
  • Versions
  • 48

StageXL_Isometric

An isometric graphics extension for StageXL.

This is work in progress...

Change Log

This file contains highlights of what changes on each version of the StageXL_Isometric package. This file is normally updated whenever we push a new version to pub.

Pub version 0.1.2

  • Added support for strong mode
  • Raised dependency to Dart SDK 1.22.0 (reason: covariant keyword)

example/example.dart

library example01;

import 'dart:html' as html;
import 'package:stagexl/stagexl.dart';
import 'package:stagexl_isometric/stagexl_isometric.dart';

void main() {

  StageXL.stageOptions.renderEngine = RenderEngine.Canvas2D;
  StageXL.stageOptions.backgroundColor = Color.AntiqueWhite;

  var canvas = html.querySelector('#stage');
  var stage = new Stage(canvas);
  var renderLoop = new RenderLoop();
  renderLoop.addStage(stage);

  var background = new Bitmap(new BitmapData(800,600, 0x869ca7));
  stage.addChild(background);

  //var app = new IsoApplication1();
  //var app = new IsoApplication2();
  var app = new IsoApplication3();
  app.x = 400;
  app.y = 200;
  stage.addChild(app);

}

class IsoApplication1 extends Sprite {
  IsoApplication1() {
    var box = new IsoBox();
    box.setSize(25, 25, 25);
    box.moveTo(0, 0, 0);

    var grid = new IsoGrid();
    grid.showOrigin = true;
    grid.setGridSize(10, 10);
    grid.moveTo(0, 0, 0);

    var scene = new IsoScene();
    scene.hostContainer = this;
    scene.addChild(box);
    scene.addChild(grid);
    scene.isoRender();
  }
}

class IsoApplication2 extends Sprite {
  IsoApplication2() {
    var box = new IsoBox();
    box.styleType = RenderStyleType.SHADED;
    box.fills = [
      new SolidColorFill(0xff0000, .5),
      new SolidColorFill(0x00ff00, .5),
      new SolidColorFill(0x0000ff, .5),
      new SolidColorFill(0xff0000, .5),
      new SolidColorFill(0x00ff00, .5),
      new SolidColorFill(0x0000ff, .5)];
    box.setSize(25, 50, 40);
    box.moveTo(0, 0, 0);

    var grid = new IsoGrid();
    grid.showOrigin = true;
    grid.setGridSize(10, 10);
    grid.moveTo(0, 0, 0);

    var scene = new IsoScene();
    scene.hostContainer = this;
    scene.addChild(grid);
    scene.addChild(box);
    scene.isoRender();
  }
}

class IsoApplication3 extends Sprite {
  IsoApplication3() {
    var box = new IsoBox();
    box.setSize(25, 25, 25);
    box.fills = [
      new SolidColorFill(0xff00ff, 1),
      new SolidColorFill(0xff00ff, 1),
      new SolidColorFill(0xff00ff, 1),
      new SolidColorFill(0xff00ff, 1),
      new SolidColorFill(0xff00ff, 1),
      new SolidColorFill(0xff00ff, 1)];
    box.moveTo(0, 25, 0);

    var box2 = new IsoBox();
    box2.setSize(25, 25, 25);
    box2.fills = [
      new SolidColorFill(0xffff00, 1),
      new SolidColorFill(0xffff00, 1),
      new SolidColorFill(0xffff00, 1),
      new SolidColorFill(0xffff00, 1),
      new SolidColorFill(0xffff00, 1),
      new SolidColorFill(0xffff00, 1)];
    box2.moveTo(25, 25, 0);

    var box3 = new IsoBox();
    box3.setSize(25, 25, 25);
    box3.moveTo(25, 0, 0);

    var grid = new IsoGrid();
    grid.showOrigin = true;
    grid.setGridSize(10, 10);
    grid.moveTo(0, 0, 0);

    var scene = new IsoScene();
    scene.hostContainer = this;
    scene.addChild(grid);

    scene.addChild(box2);
    scene.addChild(box);
    scene.addChild(box3);
    scene.layoutEnabled = true;
    scene.isoRender();
  }
}

Use this package as a library

1. Depend on it

Add this to your package's pubspec.yaml file:


dependencies:
  stagexl_isometric: "^0.1.2"

2. Install it

You can install packages from the command line:

with pub:


$ pub get

with Flutter:


$ flutter packages get

Alternatively, your editor might support pub get or flutter packages get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:


      import 'package:stagexl_isometric/stagexl_isometric.dart';
  
Version Uploaded Documentation Archive
0.1.2 Jun 27, 2017 Go to the documentation of stagexl_isometric 0.1.2 Download stagexl_isometric 0.1.2 archive

Analysis

We analyzed this package on Jun 19, 2018, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.0.0-dev.63.0
  • pana: 0.11.3

Scores

Popularity:
Describes how popular the package is relative to other packages. [more]
0 / 100
Health:
Code health derived from static analysis. [more]
97 / 100
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
94 / 100
Overall score:
Weighted score of the above. [more]
48
Learn more about scoring.

Platforms

Detected platforms: Flutter, web, other

No platform restriction found in primary library package:stagexl_isometric/stagexl_isometric.dart.

Suggestions

  • Use constrained dependencies.

    The pubspec.yaml contains 1 dependency without version constraints. Specify version ranges for the following dependencies: browser.

  • Fix analysis and formatting issues.

    Analysis or formatting checks reported 91 hints.

    Run dartfmt to format lib/src/bounds/bounds_base.dart.

    Run dartfmt to format lib/src/bounds/primitive_bounds.dart.

    Similar analysis of the following files failed:

    • lib/src/bounds/scene_bounds.dart (hint)
    • lib/src/core/class_factory.dart (hint)
    • lib/src/core/factory_base.dart (hint)
    • lib/src/core/invalidation_base.dart (hint)
    • lib/src/core/iso_container.dart (hint)
    • lib/src/core/iso_container_base.dart (hint)
    • lib/src/core/iso_display_object.dart (hint)
    • lib/src/core/iso_display_object_base.dart (hint)
    • lib/src/data/node.dart (hint)
    • lib/src/data/node_base.dart (hint)
    • lib/src/data/render_data.dart (hint)
    • lib/src/display/iso_group.dart (hint)
    • lib/src/display/iso_sprite.dart (hint)
    • lib/src/display/iso_view.dart (hint)
    • lib/src/display/iso_view_base.dart (hint)
    • lib/src/display/primitive/iso_box.dart (hint)
    • lib/src/display/primitive/iso_hex_box.dart (hint)
    • lib/src/display/primitive/iso_polygon.dart (hint)
    • lib/src/display/primitive/iso_primitive.dart (hint)
    • lib/src/display/primitive/iso_primitive_base.dart (hint)
    • lib/src/display/primitive/iso_rectangle.dart (hint)
    • lib/src/display/renderers/default_scene_layout_renderer.dart (hint)
    • lib/src/display/renderers/default_shadow_renderer.dart (hint)
    • lib/src/display/renderers/default_view_renderer.dart (hint)
    • lib/src/display/renderers/scene_blitting_renderer.dart (hint)
    • lib/src/display/renderers/scene_layout_renderer_base.dart (hint)
    • lib/src/display/renderers/scene_renderer_base.dart (hint)
    • lib/src/display/renderers/simple_scene_layout_renderer.dart (hint)
    • lib/src/display/renderers/view_bounds_renderer.dart (hint)
    • lib/src/display/renderers/view_renderer_base.dart (hint)
    • lib/src/display/scene/iso_grid.dart (hint)
    • lib/src/display/scene/iso_hex_grid.dart (hint)
    • lib/src/display/scene/iso_origin.dart (hint)
    • lib/src/display/scene/iso_scene.dart (hint)
    • lib/src/display/scene/iso_scene_base.dart (hint)
    • lib/src/enum/iso_orientation.dart (hint)
    • lib/src/enum/render_style_type.dart (hint)
    • lib/src/errors/iso_error.dart (hint)
    • lib/src/events/iso_event.dart (hint)
    • lib/src/geom/iso_math.dart (hint)
    • lib/src/geom/pt.dart (hint)
    • lib/src/geom/transformations/axonometric_transformation_base.dart (hint)
    • lib/src/geom/transformations/default_isometric_transformation.dart (hint)
    • lib/src/geom/transformations/dimetric_transformation.dart (hint)
    • lib/src/geom/transformations/isometric_transformation.dart (hint)
    • lib/src/graphics/bitmap_fill.dart (hint)
    • lib/src/graphics/bitmap_fill_base.dart (hint)
    • lib/src/graphics/fill_base.dart (hint)
    • lib/src/graphics/solid_color_fill.dart (hint)
    • lib/src/graphics/stroke.dart (hint)
    • lib/src/graphics/stroke_base.dart (hint)
    • lib/src/utils/iso_drawing_util.dart (hint)
    • lib/stagexl_isometric.dart (hint)
  • The description is too short.

    Add more detail about the package, what it does and what is its target use case. Try to write at least 60 characters.

  • Package is pre-v1 release.

    While there is nothing inherently wrong with versions of 0.*.*, it usually means that the author is still experimenting with the general direction API.

  • Use analysis_options.yaml.

    Rename old .analysis_options file to analysis_options.yaml.

Dependencies

Package Constraint Resolved Available
Direct dependencies
Dart SDK >=1.22.0 <2.0.0
browser any 0.10.0+3
stagexl ^1.0.0 1.3.1+4
Transitive dependencies
collection 1.14.10
matcher 0.12.3
path 1.6.1
petitparser 1.7.6
stack_trace 1.9.2
xml 3.0.0