mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2026-03-20 11:59:43 +00:00
HyperRogue ported to SDL2 (in mymake do -sdl2)
This commit is contained in:
@@ -876,8 +876,12 @@ void movePlayer(monster *m, int delta) {
|
||||
}
|
||||
|
||||
#if CAP_SDL
|
||||
Uint8 *keystate = SDL_GetKeyState(NULL);
|
||||
const Uint8 *keystate = SDL12_GetKeyState(NULL);
|
||||
#if CAP_SDL2
|
||||
bool forcetarget = (keystate[SDL_SCANCODE_RSHIFT] | keystate[SDL_SCANCODE_LSHIFT]);
|
||||
#else
|
||||
bool forcetarget = (keystate[SDLK_RSHIFT] | keystate[SDLK_LSHIFT]);
|
||||
#endif
|
||||
if(((mousepressed && !forcetarget) || facemouse) && delta > 0 && !mouseout() && !stdracing && GDIM == 2) {
|
||||
// playermoved = true;
|
||||
hyperpoint h = inverse_shift(m->pat, mouseh);
|
||||
|
||||
Reference in New Issue
Block a user