GameDecoration constructor

GameDecoration({
  1. required Vector2 position,
  2. required Vector2 size,
  3. Sprite? sprite,
  4. SpriteAnimation? animation,
  5. Anchor anchor = Anchor.topLeft,
  6. double angle = 0,
  7. LightingConfig? lightingConfig,
  8. bool renderAboveComponents = false,
})

Implementation

GameDecoration({
  required super.position,
  required super.size,
  Sprite? sprite,
  SpriteAnimation? animation,
  super.anchor,
  super.angle,
  super.lightingConfig,
  super.renderAboveComponents,
}) {
  this.sprite = sprite;
  setAnimation(animation);
  applyBleedingPixel(position: position, size: size);
}