From 2cef17641ae0e013a9df1b3e851d5f18968004fd Mon Sep 17 00:00:00 2001 From: helixhorned Date: Sun, 6 May 2012 20:23:20 +0000 Subject: [PATCH] A couple of misc. Wii changes. - Make MAXXDIM and MAXYDIM macros be 860 and 490, respectively. tueidj says max. screen size is 848x480, but there are oob access bugs in the classic renderer when running with the maximum possible resolution - don't allocate additional sector/wall storage for Mapster (saves ~16k) - Add ud.config.UseJoystick = 1 in config.c, but make it conditional on Wii - remove one comment I no longer believe true, add one TODO comment git-svn-id: https://svn.eduke32.com/eduke32@2645 1a8010ca-5511-0410-912e-c29ae57300e0 --- polymer/eduke32/build/include/build.h | 15 +++++++++------ polymer/eduke32/build/include/pragmas.h | 2 -- polymer/eduke32/build/src/engine.c | 2 ++ polymer/eduke32/source/config.c | 4 ++++ 4 files changed, 15 insertions(+), 8 deletions(-) diff --git a/polymer/eduke32/build/include/build.h b/polymer/eduke32/build/include/build.h index acb7c0251..3c42eb045 100644 --- a/polymer/eduke32/build/include/build.h +++ b/polymer/eduke32/build/include/build.h @@ -31,21 +31,24 @@ extern "C" { # define MAXXDIM 7680 # define MAXYDIM 3200 + +// additional space beyond wall, in walltypes: +# define M32_FIXME_WALLS 512 +# define M32_FIXME_SECTORS 2 #else # define MAXSECTORS MAXSECTORSV7 # define MAXWALLS MAXWALLSV7 # define MAXSPRITES MAXSPRITESV7 -# define MAXXDIM 1600 -# define MAXYDIM 1200 +# define MAXXDIM 860 +# define MAXYDIM 490 + +# define M32_FIXME_WALLS 0 +# define M32_FIXME_SECTORS 0 #endif #define MAXWALLSB ((MAXWALLS>>2)+(MAXWALLS>>3)) -// additional space beyond wall, in walltypes: -#define M32_FIXME_WALLS 512 -#define M32_FIXME_SECTORS 2 - #define MAXTILES 30720 #define MAXVOXELS 4096 #define MAXSTATUS 1024 diff --git a/polymer/eduke32/build/include/pragmas.h b/polymer/eduke32/build/include/pragmas.h index badf91155..4dad0594f 100644 --- a/polymer/eduke32/build/include/pragmas.h +++ b/polymer/eduke32/build/include/pragmas.h @@ -24,8 +24,6 @@ extern int32_t dmval; #include static inline int32_t divscale(int32_t eax, int32_t ebx, int32_t ecx) { - // XXX: potential loss of precision? double has only 52 bits in the - // significand, after all... return ldexp(eax, ecx) / ebx; } diff --git a/polymer/eduke32/build/src/engine.c b/polymer/eduke32/build/src/engine.c index 7636bceac..e9eecbfab 100644 --- a/polymer/eduke32/build/src/engine.c +++ b/polymer/eduke32/build/src/engine.c @@ -9013,6 +9013,8 @@ int32_t loadboard(char *filename, char flags, int32_t *daposx, int32_t *daposy, initspritelists(); +// TODO: need checking for engine compiled with V7 limits, so we +// load V8+ maps ONLY if they don't exceed them. #define MYMAXSECTORS (mapversion==7?MAXSECTORSV7:MAXSECTORSV8) #define MYMAXWALLS (mapversion==7?MAXWALLSV7:MAXWALLSV8) #define MYMAXSPRITES (mapversion==7?MAXSPRITESV7:MAXSPRITESV8) diff --git a/polymer/eduke32/source/config.c b/polymer/eduke32/source/config.c index acde021df..9a7c56a80 100644 --- a/polymer/eduke32/source/config.c +++ b/polymer/eduke32/source/config.c @@ -251,7 +251,11 @@ void CONFIG_SetDefaults(void) ud.weaponsway = 1; ud.weaponswitch = 3; // new+empty ud.angleinterpolation = 0; +#ifdef GEKKO + ud.config.UseJoystick = 1; +#else ud.config.UseJoystick = 0; +#endif ud.config.UseMouse = 1; ud.config.VoiceToggle = 5; // bitfield, 1 = local, 2 = dummy, 4 = other players in DM ud.display_bonus_screen = 1;