Quote:
Originally Posted by Crow
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