From 3401a0bddcdce075f8cda8b6392c541050fd36e2 Mon Sep 17 00:00:00 2001 From: sparky4 Date: Sat, 12 Mar 2016 21:33:34 -0600 Subject: [PATCH] inputest manipulates d and q like scroll.exe --- src/lib/16_in.c | 7 ++----- src/lib/16_in.h | 4 ++-- 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/src/lib/16_in.c b/src/lib/16_in.c index 062e3bee..52a76774 100755 --- a/src/lib/16_in.c +++ b/src/lib/16_in.c @@ -919,16 +919,13 @@ register KeyboardDef *def; // player[pn].info.dir = DirTable[((my + 1) * 3) + (mx + 1)]; conpee=(((my + 1) * 2) + (mx + 1))-1; //if(conpee) conpee--; player[pn].info.dir = DirTable[conpee]; + + //TODO: overwriting direction must be added if(DIRECTIONIFELSEGFXTEST && player[pn].d != player[pn].info.dir) player[pn].pdir=DirTable[conpee]; if(player[pn].q==1 && (mx!=motion_None || my!=motion_None)) { player[pn].d = player[pn].info.dir; - //printf("q =%d ", player[pn].q); - //if(testcontrolnoisy > 0) - //if(testcontrolnoisy > 0) - //printf("cpee=%d ", conpee); } - if(testcontrolnoisy > 0) #if DEMO0 if (DemoMode == demo_Record) diff --git a/src/lib/16_in.h b/src/lib/16_in.h index e39c400e..ad625ed1 100755 --- a/src/lib/16_in.h +++ b/src/lib/16_in.h @@ -45,8 +45,8 @@ extern byte testkeyin,testcontrolnoisy,gfxtest; //if else for gfxtesting and direction -#define DIRECTIONIFELSEGFXTEST (player[pn].d == 2 && gfxtest) || (player[pn].info.dir == 2 && !gfxtest) -#define NDIRECTIONIFELSEGFXTEST (player[pn].d != 2 && gfxtest) || (player[pn].info.dir != 2 && !gfxtest) +#define DIRECTIONIFELSEGFXTEST (player[pn].d == 2 || player[pn].info.dir == 2) +#define NDIRECTIONIFELSEGFXTEST (player[pn].d != 2 || player[pn].info.dir != 2) #define KeyInt 9 // The keyboard ISR number -- 2.39.5