Jump to content

Physics cursor: Difference between revisions

Guest-1052 (talk | contribs)
beautifier.io
Dat Hack3r (talk | contribs)
m Removed incorrectly placed semicolon and added new lines for readability.
 
(5 intermediate revisions by the same user not shown)
Line 1: Line 1:
<p></p><syntaxhighlight lang="javascript">
/* Physics cursor script by fp, used for most physics parkour worlds. Often combined with the improved Guest cursors script and used with a ratelimit of 0 chars per second. */
/* Physics cursor script by fp, used for most physics parkour worlds. Often edited and also mixed with the improved Guest cursors script, Also often mixed with a ratelimit of 0 chars per second */
keyConfig.cursorUp = "";
keyConfig.cursorUp = "";
keyConfig.cursorDown = "";
keyConfig.cursorDown = "";
Line 12: Line 11:
var keyRight = false;
var keyRight = false;
var keyUp = false;
var keyUp = false;
document.addEventListener("keydown", function(e) {
document.addEventListener("keydown", function(e) {
     if (checkKeyPress(e, "UP")) {
     if (checkKeyPress(e, "UP")) {
Line 81: Line 81:
         }
         }
     }
     }
};
}
 
setInterval(tick, 1000 / 30);
setInterval(tick, 1000 / 30);
</syntaxhighlight>
 
[[Category:Scripts]]
 
/* [[Category:Scripts]] */