Command: | Listen for Key Press Down |
Codeskulptor Explaination: | frame.set_keydown_handler(key_handler) |
Codeskulptor Literal: | frame.set_keydown_handler(key_handler) |
EspzJs Explaination: | window.onkeydown = Name_of_Function; |
EspzJs Literal: | window.onkeydown = KeydownControl; |
EzpzJs Notes: | This command is not from EzpzJs. It is the correct direct Javascript Command. I just don't see a reason to tamper with this formula. It is also interesting to note that we don't pass a variable in to the function. This means that the variable might be the key press itself |
Command: | Listen for Key Release |
Codeskulptor Explaination: | frame.set_keyup_handler(key_handler) |
Codeskulptor Literal: | frame.set_keyup_handler(key_handler) |
EzpzJs Explaination: | window.onkeyup = Name_of_Function; |
EzpzJs Literal: | window.onkeyup = KeyupControl; |
EzpzJs Notes: | This command is not from EzpzJs. It is the correct direct Javascript Command. I just don't see a reason to tamper with this formula. |
Command: | Key Finder |
EzpzJs Only: | button = KeyFinder(e.keyCode); |
button will return the value of the key in the function of the key up or down |
Command: | Listen for a press of the mouse |
Codeskulptor Explaination: | frame.set_mouseclick_handler(functionName) |
Codeskulptor Literal: | frame.set_mouseclick_handler(mouse_handler) |
EzpzJs Explaination: | Please comment on youtube if you can explain this! |
EzpzJs Literal: | myCanvas.addEventListener("mousedown", MouseDown, false); |
Command: | Canvas Click finds for mouse press |
EzpzJs Only: | canvas_x = event.pageX; |
canvas_y = event.pageY; |
Keys to listen for: |
Special Keys |
"Backspace", "Tab", "Enter", "Shift", "Ctrl", "Alt", "Space", "Page Up", "Page Down", "End", "Home", "Left", "Up", "Right", "Down", "Insert", "Delete" |
Number Keys |
"0", "1", "2", "3", "4", "5", "6", "7", "8", "9" |
"A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K", "L", "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V", "W", "X", "Y", "Z" |
F Keys |
"F1", "F2", "F3", "F4", "F5", "F6", "F7", "F8", "F9", "F10", "F11", "F12" |