Skip to content

Commit

Permalink
Merge pull request #103 from jackyyzhang03/master
Browse files Browse the repository at this point in the history
Fixed jumping in air bug
  • Loading branch information
mx0c authored Oct 6, 2021
2 parents 750503d + 291cd71 commit 5623213
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion traits/jump.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ def __init__(self, entity):

def jump(self, jumping):
if jumping:
if not self.entity.inAir and not self.entity.inJump: # redundant check
if self.entity.onGround:
self.entity.sound.play_sfx(self.entity.sound.jump)
self.entity.vel.y = self.verticalSpeed
self.entity.inAir = True
Expand Down

0 comments on commit 5623213

Please sign in to comment.