View Single Post
  #4  
Old 12-16-2011, 03:18 AM
fowlplay4 fowlplay4 is offline
team canada
fowlplay4's Avatar
Join Date: Jul 2004
Location: Canada
Posts: 5,200
fowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond repute
If you don't know how to style your code and want to make it easier for the forum folk to read please use my GS2 Beautifier to clean it up before posting.

The two checks in your key pressed are redundant which also make it confusing in the process.

Not a fan of using temp once then not using it through out.

You don't really need to evaluate for true/false like that either you could just use but that's ultimately personal preference:

PHP Code:
if (this.boots == true) {  // if (this.boots) { // is also fine.
  // boots are on
} else {
  
// boots are off

__________________
Quote:
Reply With Quote