public override void Enter(Entity context)
 {
     transform = context.transform;
     direction = context.GetMedrashPosition() - transform.position;
     direction.y = 0.0f;
     context.SetSpeed(context.GetBaseSpeed()*1.5f);
     context.SetDirection(direction);
 }
Пример #2
0
 public override void Enter(Entity context)
 {
     context.SetSpeed(context.GetBaseSpeed());
     float r = Random.value;
     rotateAngle = 120.0f*(2*r - 1)*Mathf.PI/180.0f;
     if (r < 0.4)
         context.RotateBy(rotateAngle);
     else if (r < 0.8)
         context.RotateBy(-rotateAngle);
     direction = context.transform.forward;
     direction.y = 0.0f;
     context.SetDirection(direction);
 }
Пример #3
0
 public override void Enter(Entity context)
 {
     context.SetSpeed(context.GetBaseSpeed());
 }
Пример #4
0
 public override void Enter(Entity context)
 {
     context.SetSpeed(context.GetBaseSpeed());
     context.SetRunAnimation();
 }