author | andyq <andyq> | 2003-02-28 23:56:03 (UTC) |
---|---|---|
committer | andyq <andyq> | 2003-02-28 23:56:03 (UTC) |
commit | 7dd36872a3eb63eb1c3c7a17549f3eeba92f1b32 (patch) (unidiff) | |
tree | b0628e9a3c75129d24301e30c44c55a23f03d963 /noncore/games/sfcave-sdl/game.cpp | |
parent | 64423f1852a13178f23365f2bba995ef2c355b3b (diff) | |
download | opie-7dd36872a3eb63eb1c3c7a17549f3eeba92f1b32.zip opie-7dd36872a3eb63eb1c3c7a17549f3eeba92f1b32.tar.gz opie-7dd36872a3eb63eb1c3c7a17549f3eeba92f1b32.tar.bz2 |
Changed keyboard handling to accept UP, ENTER and RETURN for moving ship
Diffstat (limited to 'noncore/games/sfcave-sdl/game.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/games/sfcave-sdl/game.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/noncore/games/sfcave-sdl/game.cpp b/noncore/games/sfcave-sdl/game.cpp index e41e510..1ee0230 100644 --- a/noncore/games/sfcave-sdl/game.cpp +++ b/noncore/games/sfcave-sdl/game.cpp | |||
@@ -70,5 +70,9 @@ void Game :: init() | |||
70 | void Game :: handleKeys( SDL_KeyboardEvent &key ) | 70 | void Game :: handleKeys( SDL_KeyboardEvent &key ) |
71 | { | 71 | { |
72 | if ( !replay && key.keysym.sym == SDLK_SPACE ) | 72 | if ( !replay && |
73 | (key.keysym.sym == SDLK_SPACE || | ||
74 | key.keysym.sym == SDLK_KP_ENTER || | ||
75 | key.keysym.sym == SDLK_RETURN || | ||
76 | key.keysym.sym == SDLK_UP) ) | ||
73 | { | 77 | { |
74 | if ( key.type == SDL_KEYDOWN ) | 78 | if ( key.type == SDL_KEYDOWN ) |