public DungeonTile(Sprite sprite, Rectangle extent, TileType type, AnimationScript script) : base(sprite, script) { SubRect = extent; _extent = extent; _type = type; if (script != null) script.Loop = true; // hack: this really shouldn't beee heeeeere FrameSize = new Point(24, 24); }
public Sprite(Image sprite, Transformation transformation, AnimationScript animation, SATCollisionVolume collider) { this.Image = sprite; SubRect = new Rectangle(0, 0, sprite.Texture.Width, sprite.Texture.Height); this.Transformation = new Transformation(transformation); this.AnimationScript = animation; this.CollisionVolume = collider; OnDraw += this.Draw; if (CollisionVolume != null) { OnUpdate += delegate(GameTime time) { collider.TransformCollisionVolume(this.Transformation); }; } }
public Sprite(Image sprite, AnimationScript animation) : this(sprite, new Transformation(), animation, null) { }
public Tile(Sprite sprite, AnimationScript animation) : this(sprite, new Transformation(), animation, null) { }