public AnimationAtlasPlayer(IAnimationAtlas atlas, IAnimationAtlasAction action) { _atlas = atlas; this.action = action; _currentFrame = action.StartFrame; _frameSpeed = 0.15f; Color = Color.White; }
public Sprite(IAnimationAtlas atlas, Dictionary <string, IAnimationAtlasAction> actions) { Atlas = atlas; AtlasManager = Factory.CreateAnimAtlasManager(this, actions); Position = new Vector2(0, 0); Speed = 5f; Mover = Factory.CreateMover(this); CollisionHandler = new CollisionHandler(this); }
public static IAnimationAtlasPlayer CreateAnimAtlasPlayer(IAnimationAtlas atlas, IAnimationAtlasAction action) { return(new AnimationAtlasPlayer(atlas, action)); }
public static ISprite CreateSprite(IAnimationAtlas atlas, Dictionary <string, IAnimationAtlasAction> actions) { return(new Sprite(atlas, actions)); }