GameDecoration constructor

GameDecoration({
  1. Sprite? sprite,
  2. required Vector2 position,
  3. required double height,
  4. required double width,
  5. SpriteAnimation? animation,
})

Implementation

GameDecoration({
  this.sprite,
  required Vector2 position,
  required double height,
  required double width,
  SpriteAnimation? animation,
}) {
  this.animation = animation;
  this.position = generateRectWithBleedingPixel(
    position,
    width,
    height,
  );
}