aboutsummaryrefslogtreecommitdiffstats
path: root/src/ui.cpp
diff options
context:
space:
mode:
authordrumsetmonkey <abelleisle@roadrunner.com>2015-10-07 08:35:15 -0400
committerdrumsetmonkey <abelleisle@roadrunner.com>2015-10-07 08:35:15 -0400
commitf49eb15dbc7b8d77ff9580ccd44d42b9969969fc (patch)
tree825f84366d9f9212369a3ab10743873eb7a405f6 /src/ui.cpp
parent6986331694adb60265c815af6637caf2dbc23ede (diff)
Added walking animation to player
Diffstat (limited to 'src/ui.cpp')
-rw-r--r--src/ui.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/ui.cpp b/src/ui.cpp
index cd5de15..e4af3e2 100644
--- a/src/ui.cpp
+++ b/src/ui.cpp
@@ -214,6 +214,7 @@ namespace ui {
if(SDL_KEY==SDLK_i)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;
}
if(SDL_KEY==SDLK_F3)debug^=true;
break;
@@ -225,7 +226,7 @@ namespace ui {
if(SDL_KEY==SDLK_d){right=false;}
if(!left&&!right)player->vel.x=0;
if(SDL_KEY==SDLK_LSHIFT)player->speed = 1;
-
+ if(SDL_KEY==SDLK_LCTRL)player->speed = 1;
break;
default:
break;