diff --git a/polymer/eduke32/build/include/build.h b/polymer/eduke32/build/include/build.h index 16738b481..8e13e4c7e 100644 --- a/polymer/eduke32/build/include/build.h +++ b/polymer/eduke32/build/include/build.h @@ -30,7 +30,8 @@ extern "C" { #define MAXSPRITES MAXSPRITESV8 // additional space beyond wall, in walltypes: -#define M32_FIXME_WALLS 1024 +#define M32_FIXME_WALLS 512 +#define M32_FIXME_SECTORS 2 #define MAXTILES 15360 #define MAXVOXELS 4096 diff --git a/polymer/eduke32/build/src/engine.c b/polymer/eduke32/build/src/engine.c index 8633f0520..572726a12 100644 --- a/polymer/eduke32/build/src/engine.c +++ b/polymer/eduke32/build/src/engine.c @@ -6157,8 +6157,8 @@ static int32_t preinitcalled = 0; #ifndef DYNALLOC_ARRAYS static spriteext_t spriteext_s[MAXSPRITES+MAXUNIQHUDID]; static spritesmooth_t spritesmooth_s[MAXSPRITES+MAXUNIQHUDID]; -static sectortype sector_s[MAXSECTORS]; -static walltype wall_s[MAXWALLS]; +static sectortype sector_s[MAXSECTORS + M32_FIXME_SECTORS]; +static walltype wall_s[MAXWALLS + M32_FIXME_WALLS]; static spritetype sprite_s[MAXSPRITES]; static spritetype tsprite_s[MAXSPRITESONSCREEN]; #else @@ -6186,7 +6186,7 @@ int32_t preinitengine(void) dynarray[] = { { (void **) §or, sizeof(sectortype) *MAXSECTORS }, - { (void **) &wall, sizeof(walltype) *MAXWALLS }, // +1024: editor quirks. FIXME! + { (void **) &wall, sizeof(walltype) *MAXWALLS }, // +512: editor quirks. FIXME! { (void **) &sprite, sizeof(spritetype) *MAXSPRITES }, { (void **) &tsprite, sizeof(spritetype) *MAXSPRITESONSCREEN }, { (void **) &spriteext, sizeof(spriteext_t) *(MAXSPRITES+MAXUNIQHUDID) }, @@ -6197,7 +6197,7 @@ int32_t preinitengine(void) if (editstatus) { - dynarray[0].size += 2*sizeof(sectortype); // join sectors needs a temp. sector + dynarray[0].size += M32_FIXME_SECTORS*sizeof(sectortype); // join sectors needs a temp. sector dynarray[1].size += M32_FIXME_WALLS*sizeof(walltype); Bprintf("FIXME: Allocating additional space beyond wall[] for editor bugs.\n"); }