MrDoubleA wrote: ↑Sun Jun 28, 2020 8:03 am
Instead of detecting a key press you'd be better off using onJump, like this:
function onJump()
triggerEvent("a")
end
Is onJump reliable? Last I checked it doesn't work for short hops.
If you only want jumps that started on a solid ground surface, you could also try:
Code: Select all
function onTick()
if player:isOnGround() and player.keys.jump == KEYS_PRESSED then
-- do stuff
end
end