Ejemplo n.º 1
0
        public void TestGravity()
        {
            Vec2F oldVelocity = physics.GetRawVelocity();

            physics.UpdateVelocity();
            Vec2F newVelocity = physics.GetRawVelocity();

            Assert.Greater(oldVelocity.Y, newVelocity.Y);
        }
Ejemplo n.º 2
0
        /// <summary>
        /// Moves the player around in with the given velocity and direction
        /// </summary>
        public void Move()
        {
            //Engage the thrusters
            Booster();

            Entity.Shape.AsDynamicShape().Direction = physics.GetVelocity();
            Entity.Shape.AsDynamicShape().Move();
            physics.UpdateVelocity();
        }