View Single Post
  #9  
Old 02-28-2010, 10:10 PM
xAndrewx xAndrewx is offline
Registered User
xAndrewx's Avatar
Join Date: Sep 2004
Posts: 5,260
xAndrewx has much to be proud ofxAndrewx has much to be proud ofxAndrewx has much to be proud ofxAndrewx has much to be proud ofxAndrewx has much to be proud ofxAndrewx has much to be proud ofxAndrewx has much to be proud of
Quote:
Originally Posted by Crow View Post
Doesn't matter, he's just trying to show how he debugs his code. I'd say it'd be easier (better even) to use a this.var instead, and then monitoring it with Jerret's debugger.
of-course it matters.

HTML Code:
function onKeyPressed(code, key) {
  if (temp.key == "w") {
    player.z = 0.05;
    for (temp.i = 0; temp.i < 1; temp.i += 0.05) {
      if (player.z > 0) {
        player.z += (temp.i > 0.5? -temp.i: temp.i);
      } else {
        player.z = 0;
      }
      sleep(0.05);
    }
  }
}
A basic jump script
__________________

Last edited by xAndrewx; 02-28-2010 at 10:23 PM..
Reply With Quote