aboutsummaryrefslogtreecommitdiffstats
path: root/src/ui.cpp
diff options
context:
space:
mode:
authorClyne Sullivan <tullivan99@gmail.com>2015-10-29 08:13:09 -0400
committerClyne Sullivan <tullivan99@gmail.com>2015-10-29 08:13:09 -0400
commit9542d9a8a022fe1d3390510e8a135a4917df7aa7 (patch)
tree19386c919e375a8185939fcda73b841901d20602 /src/ui.cpp
parent2ae6503dd2aa1be80ed2b679cdcce1286fa85d60 (diff)
fixed world
Diffstat (limited to 'src/ui.cpp')
-rw-r--r--src/ui.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/ui.cpp b/src/ui.cpp
index 8f19e34..e6d18d2 100644
--- a/src/ui.cpp
+++ b/src/ui.cpp
@@ -237,7 +237,11 @@ namespace ui {
player->ground=false;
}
}
- if(SDL_KEY==SDLK_i)currentWorld=currentWorld->goWorldBack(player); // Go back a layer if possible
+ if(SDL_KEY==SDLK_i){
+ player->vel.y=.5;
+ player->ground=false;
+ currentWorld=currentWorld->goWorldBack(player); // Go back a layer if possible
+ }
if(SDL_KEY==SDLK_k)currentWorld=currentWorld->goWorldFront(player); // Go forward a layer if possible
if(SDL_KEY==SDLK_LSHIFT)player->speed = 3; // Sprint
if(SDL_KEY==SDLK_LCTRL)player->speed = .5;