From a7ec60390cd8ec777c63fff83e99ce776de4e483 Mon Sep 17 00:00:00 2001 From: zombie Date: Fri, 4 Mar 2022 11:21:54 -0500 Subject: [PATCH] i forgot to add zom_getch --- src/linux.h | 5 ++++- src/main.c | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/linux.h b/src/linux.h index 526b709..3ad7380 100644 --- a/src/linux.h +++ b/src/linux.h @@ -15,6 +15,9 @@ int zom_screxit(void) { return 0; } int zom_putcharat(int x, int y, char chara){ - mvaddch(y, x, chara); + mvaddch(y, x, chara); //flipped to match screen coords return 0; } +char zom_getch(void){ + return getch(); +} diff --git a/src/main.c b/src/main.c index 30a1a2b..d37463b 100644 --- a/src/main.c +++ b/src/main.c @@ -39,7 +39,7 @@ int main( int argc, char *argv[] ) { //yoinked from the internet argc is number debugent_y.xold = debugent_y.x; debugent_y.yold = debugent_y.y; - switch (getch()) { + switch (zom_getch()) { case 'a': player.x--; break;