Esempio n. 1
0
 private void Running_FixedUpdate()
 {
     if (inputHandler.Direction != Vector3.zero) //Comment this to enable always moving mechanic
     {
         if (groundMovement.InsideWaterStream)
         {
             groundMovement.Move(inputHandler.Direction, 0.35f);
         }
         else
         {
             groundMovement.Move(inputHandler.Direction);
         }
     }
     else
     {
         currentState = PlayerStates.Idle;
     }
 }
        public void TestUnderGroundMovement()
        {
            var movement = new GroundMovement();
            var monster  = new Monster {
                MonsterIndex = 1, Position = 1
            };

            movement.Move(monster);

            Assert.True(monster.Position == 2 && monster.MonsterIndex == 1);
        }
 // Update is called once per frame
 public void ManageGraphics()
 {
     m_Ground.Move();
 }