main
Henri Vasserman 2024-12-30 12:20:09 +02:00
parent 44279a48dd
commit bd22ce173b
1 changed files with 4 additions and 4 deletions

View File

@ -39,16 +39,16 @@ int main() {
if (keys[SDL_SCANCODE_ESCAPE] || keys[SDL_SCANCODE_Q]) {
break;
}
if (keys[SDL_SCANCODE_LEFT]) {
if (keys[SDL_SCANCODE_LEFT] || keys[SDL_SCANCODE_A]) {
f.offset.x -= 16;
}
if (keys[SDL_SCANCODE_RIGHT]) {
if (keys[SDL_SCANCODE_RIGHT] || keys[SDL_SCANCODE_D]) {
f.offset.x += 16;
}
if (keys[SDL_SCANCODE_UP]) {
if (keys[SDL_SCANCODE_UP] || keys[SDL_SCANCODE_W]) {
f.offset.y -= 16;
}
if (keys[SDL_SCANCODE_DOWN]) {
if (keys[SDL_SCANCODE_DOWN] || keys[SDL_SCANCODE_S]) {
f.offset.y += 16;
}