Attention | Topic was automatically imported from the old Question2Answer platform. | |
Asked By | sparrow666 |
hi, help please
i have a double jump working correctly, but i want to print the jumps but due to resetting at the floor the jump count at the floor it doesn’t print the first jump, only 2nd
if Input.is_action_just_pressed("jump"):
jumps_count -= 1
if jumps_count != 0:
motion.y = JUMP_HEIGHT
if is_on_floor():
jumps_count = 3
print(jumps_count)
printout is 3 on floor, 3 for first jump and 2 for second!
pretty sure it’s to do with the resetting on is_on_floor() but not sure how to solve
any help would be great, driving me nuts
thanks