diff options
author | Clyne Sullivan <tullivan99@gmail.com> | 2015-09-13 10:01:21 -0400 |
---|---|---|
committer | Clyne Sullivan <tullivan99@gmail.com> | 2015-09-13 10:01:21 -0400 |
commit | a8fb538152c5e7d83b161a3868870aa4009ea36f (patch) | |
tree | 9cae69fc2ef26b6d57bab56e3912d6a4545800ff /src/UIClass.cpp | |
parent | 384005bf1ebb0f303fec721a62970a78792b49c3 (diff) |
colors
Diffstat (limited to 'src/UIClass.cpp')
-rw-r--r-- | src/UIClass.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/UIClass.cpp b/src/UIClass.cpp index 00456f5..46c7124 100644 --- a/src/UIClass.cpp +++ b/src/UIClass.cpp @@ -19,8 +19,10 @@ void UIClass::handleEvents(){ if(e.key.keysym.sym == SDLK_a) player.left = true; if(e.key.keysym.sym == SDLK_LSHIFT) player.speed = 3; if(e.key.keysym.sym == SDLK_SPACE){ - player.loc.y += HLINE*1.2; - player.vel.y += .004; + if(player.vel.y<=0){ + player.loc.y += HLINE*1.2; + player.vel.y += .004; + } } if(e.key.keysym.sym == SDLK_i){ if(currentWorld->behind){ |