Thread: New Stuff!
View Single Post
Old
x2495iiii
Super Moderator
 
x2495iiii's Avatar
 
Status: Offline
Posts: 3,508
Join Date: Dec 2008
Location: Somewhere in the Continental U.S.
Default 01-21-2010, 01:24 PM

Instead of having each motion key move the character directly, have it call a method instead. Then, in that method, set a boolean, like moveLeft or moveUp, to true. Finally, put in an if/else if statement that checks to see if any of the other three boolean variables are true, and have it do nothing if they are, and put the walking code in the else part of the statement.


(')>
   
Reply With Quote