Skip to content

Instantly share code, notes, and snippets.

@predominant
Created January 20, 2013 11:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save predominant/4578054 to your computer and use it in GitHub Desktop.
Save predominant/4578054 to your computer and use it in GitHub Desktop.
if (Input.GetKeyDown(this.KeyRight) || Input.GetKeyUp(this.KeyLeft))
{
this.Turning++;
}
if (Input.GetKeyUp(this.KeyRight) || Input.GetKeyDown(this.KeyLeft))
{
this.Turning--;
}
if (this.Turning != 0)
{
this.Strafe(this.Turning * this.AgilityBase * this.ShipDetail.Agility);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment