Hi everyone,
I'm trying to make my first game, it's now just a block moving right, left and up using physics and :applyForce(), but I want my lil' cube to jump only when he is on something. So is there a way for me to get the vertical velocity and the vertical velocity only?
Thanks in advance,
-Echamiq
Need help with jump cooldown
Forum rules
Before you make a thread asking for help, read this.
Before you make a thread asking for help, read this.
Need help with jump cooldown
- Attachments
-
- loveq.love
- The .love
- (1.64 KiB) Downloaded 112 times
Re: Need help with jump cooldown
Correct me if I'm wrong, but wouldn't it be:
?
Code: Select all
velX, velY = player.body:getLinearVelocity()
-- Then just use the velY
Who is online
Users browsing this forum: Ahrefs [Bot], Google [Bot] and 5 guests