public void LaunchSnowball(Vector3 velocity)
 {
     if (currentState != PenguinSnowballThrowState.Charge)
     {
         commandQueue.Enqueue(new LaunchSnowballCommand(this, velocity));
         return;
     }
     currentState           = PenguinSnowballThrowState.Throw;
     snowballInst.LaunchVel = velocity;
     anim.SetTrigger(launchAnimTrigger);
 }
Example #2
0
 private void setState(PenguinSnowballThrowState newState)
 {
     currentState = newState;
 }