Layer constructor

Layer({
  1. required int? id,
  2. required List<Tile> tiles,
  3. String? name,
  4. String? layerClass,
  5. bool visible = true,
  6. Vector2? position,
  7. Vector2? offset,
  8. double opacity = 1,
  9. Map<String, dynamic>? properties,
  10. int priority = 0,
})

Implementation

Layer({
  required this.id,
  required this.tiles,
  this.name,
  this.layerClass,
  this.visible = true,
  Vector2? position,
  Vector2? offset,
  this.opacity = 1,
  this.properties,
  this.priority = 0,
})  : position = position ?? Vector2.zero(),
      offset = offset ?? Vector2.zero();