소스 검색

core: port everything to SDL 1.3.

legacy
Sam Hocevar sam 13 년 전
부모
커밋
71844c65bb
1개의 변경된 파일4개의 추가작업 그리고 0개의 파일을 삭제
  1. +4
    -0
      src/input.cpp

+ 4
- 0
src/input.cpp 파일 보기

@@ -63,7 +63,11 @@ vec2 Input::GetAxis(int axis)

#if defined USE_SDL
/* Simulate a joystick using the keyboard. This SDL call is free. */
#if SDL_MAJOR_VERSION == 1 && SDL_MINOR_VERSION >= 3
Uint8 *keystate = SDL_GetKeyboardState(NULL);
#else
Uint8 *keystate = SDL_GetKeyState(NULL);
#endif
int left = keystate[SDLK_d] - (keystate[SDLK_a] | keystate[SDLK_q]);
int up = (keystate[SDLK_w] | keystate[SDLK_z]) - keystate[SDLK_s] ;
ret.x += left;


불러오는 중...
취소
저장