Esempio n. 1
0
 public Player(double x, double y, int width, int height, string texture, StateMachine stateMachine, TileMap map, GameLevel level) : base(x, y, width, height, texture, stateMachine, map, level)
 {
     Score = 0;
 }
Esempio n. 2
0
 public Snail(string texture, double x, double y, int width, int height, StateMachine stateMachine, TileMap map, GameLevel level) : base(x, y, width, height, texture, stateMachine, map, level)
 {
 }
Esempio n. 3
0
        public Entity(double x, double y, int width, int height, string texture, StateMachine stateMachine, TileMap map, GameLevel level)
        {
            // position
            X = x;
            Y = y;

            // velocity
            Dx = 0;
            Dy = 0;

            // dimensions
            Width  = width;
            Height = height;

            Texture      = texture;
            StateMachine = stateMachine;

            Direction = Direction.Left;

            // reference to tilemap so we can check collisions
            Map = map;

            // reference to level for tests against other entities + objects
            Level = level;
        }