protected override void Move(float time)
{
if (tornado == null)
{
}
else
{
switch (state)
{
case State.Flying:
updateErrorDist(tornado.Radius / 8, tornado.Radius / 1.5f); //generates a new error term
updateErrorSpeed(tornado.RotationalSpeed / 10.0f, tornado.RotationalSpeed / 2); //generates a new error speed term
moveAngle = getAngleToPoint(tornado.Position) + (float)Math.PI / (2 * (getDistanceFromTornado() / (tornado.Radius + errorDist)));
#region performmove
this.bounds.X += (float)(Math.Sin(moveAngle) * (tornado.RotationalSpeed + errorSpeed)) * time * timeScaleFactor;
this.bounds.Y -= (float)(Math.Cos(moveAngle) * (tornado.RotationalSpeed + errorSpeed)) * time * timeScaleFactor;
#endregion
#region RubberBand
RubberBandMe(time);
#endregion
break;
}
}
}