mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-11-11 07:11:39 +00:00
Misc small fixes
git-svn-id: https://svn.eduke32.com/eduke32@1390 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
82211327e8
commit
8474211c95
10 changed files with 43 additions and 23 deletions
|
@ -268,6 +268,7 @@ typedef struct s_pranimatespritesinfo {
|
|||
|
||||
// EXTERNAL FUNCTIONS
|
||||
int32_t polymer_init(void);
|
||||
void polymer_uninit(void);
|
||||
void polymer_glinit(void);
|
||||
void polymer_loadboard(void);
|
||||
void polymer_drawrooms(int32_t daposx, int32_t daposy, int32_t daposz, int16_t daang, int32_t dahoriz, int16_t dacursectnum);
|
||||
|
@ -284,7 +285,7 @@ static void polymer_displayrooms(int16_t sectnum);
|
|||
static void polymer_drawplane(_prplane* plane);
|
||||
static inline void polymer_inb4mirror(GLfloat* buffer, GLfloat* plane);
|
||||
static void polymer_animatesprites(void);
|
||||
static void polymer_clearmapdata(void);
|
||||
static void polymer_freeboard(void);
|
||||
static void polymer_editorselect(void);
|
||||
// SECTORS
|
||||
static int32_t polymer_initsector(int16_t sectnum);
|
||||
|
|
|
@ -5698,6 +5698,9 @@ void uninitengine(void)
|
|||
polymost_glreset();
|
||||
hicinit();
|
||||
freeallmodels();
|
||||
#ifdef POLYMER
|
||||
polymer_uninit();
|
||||
#endif
|
||||
/* if (cachefilehandle > -1)
|
||||
Bclose(cachefilehandle);
|
||||
if (cacheindexptr != NULL)
|
||||
|
|
|
@ -625,6 +625,11 @@ int32_t polymer_init(void)
|
|||
return (1);
|
||||
}
|
||||
|
||||
void polymer_uninit(void)
|
||||
{
|
||||
polymer_freeboard();
|
||||
}
|
||||
|
||||
void polymer_glinit(void)
|
||||
{
|
||||
bglClearColor(0.0f, 0.0f, 0.0f, 1.0f);
|
||||
|
@ -668,7 +673,7 @@ void polymer_loadboard(void)
|
|||
{
|
||||
int32_t i;
|
||||
|
||||
polymer_clearmapdata();
|
||||
polymer_freeboard();
|
||||
|
||||
i = 0;
|
||||
while (i < numsectors)
|
||||
|
@ -1563,7 +1568,7 @@ static void polymer_animatesprites(void)
|
|||
asi.animatesprites(globalposx, globalposy, viewangle, asi.smoothratio);
|
||||
}
|
||||
|
||||
static void polymer_clearmapdata(void)
|
||||
static void polymer_freeboard(void)
|
||||
{
|
||||
int32_t i;
|
||||
|
||||
|
|
|
@ -341,7 +341,7 @@ void initprintf(const char *f, ...)
|
|||
va_end(va);
|
||||
|
||||
OSD_Printf(buf);
|
||||
Bprintf(buf);
|
||||
Bprintf("%s", buf);
|
||||
|
||||
if (Bstrlen(dabuf) + Bstrlen(buf) > 1022)
|
||||
{
|
||||
|
|
|
@ -38,7 +38,7 @@
|
|||
#include "build.h"
|
||||
#include "a.h"
|
||||
#include "osd.h"
|
||||
|
||||
#include "mmulti.h"
|
||||
|
||||
// undefine to restrict windowed resolutions to conventional sizes
|
||||
#define ANY_WINDOWED_SIZE
|
||||
|
@ -626,7 +626,7 @@ void initprintf(const char *f, ...)
|
|||
|
||||
Bstrcat(dabuf,buf);
|
||||
|
||||
if (++cnt < 16 || flushlogwindow || Bstrlen(dabuf) > 768)
|
||||
if (++cnt < 16 || flushlogwindow || Bstrlen(dabuf) > 768 || numplayers > 1)
|
||||
{
|
||||
startwin_puts(dabuf);
|
||||
handleevents();
|
||||
|
|
|
@ -2285,6 +2285,8 @@ static void G_MoveWeapons(void)
|
|||
// if( g_sounds[WIERDSHOT_FLY].num == 0 )
|
||||
// A_PlaySound(WIERDSHOT_FLY,i);
|
||||
|
||||
Bmemcpy(&davect,s,sizeof(vec3_t));
|
||||
|
||||
if (ActorExtra[i].projectile.flashcolor)
|
||||
G_AddGameLight(0, s->sectnum, s->x, s->y, s->z-((s->yrepeat*tilesizy[s->picnum])<<1), 2048, ActorExtra[i].projectile.flashcolor,PR_LIGHT_PRIO_LOW_GAME);
|
||||
|
||||
|
@ -2299,7 +2301,7 @@ static void G_MoveWeapons(void)
|
|||
{
|
||||
k = A_Spawn(i,ActorExtra[i].projectile.spawns);
|
||||
|
||||
Bmemcpy(&sprite[k],&davect,sizeof(vec3_t));
|
||||
// Bmemcpy(&sprite[k],&davect,sizeof(vec3_t));
|
||||
/*
|
||||
sprite[k].x = dax;
|
||||
sprite[k].y = day;
|
||||
|
@ -2350,8 +2352,6 @@ static void G_MoveWeapons(void)
|
|||
ll = s->zvel>>1;
|
||||
}
|
||||
|
||||
Bmemcpy(&davect,s,sizeof(vec3_t));
|
||||
|
||||
A_GetZLimits(i);
|
||||
qq = CLIPMASK1;
|
||||
|
||||
|
|
|
@ -50,7 +50,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
|||
#include <shellapi.h>
|
||||
#endif
|
||||
|
||||
#define BUILDDATE " 20090512"
|
||||
#define BUILDDATE " 20090522"
|
||||
|
||||
static int32_t floor_over_floor;
|
||||
|
||||
|
@ -166,10 +166,11 @@ void create_map_snapshot(void)
|
|||
while (next->prev)
|
||||
{
|
||||
next = next->prev;
|
||||
if (next->next->sectors && next->next->sectors != next->sectors) Bfree(next->next->sectors);
|
||||
if (next->next->walls && next->next->walls != next->walls) Bfree(next->next->walls);
|
||||
if (next->next->sprites && next->next->sprites != next->sprites) Bfree(next->next->sprites);
|
||||
if (next->next->sectors && (next->next->sectors != next->sectors)) Bfree(next->next->sectors);
|
||||
if (next->next->walls && (next->next->walls != next->walls)) Bfree(next->next->walls);
|
||||
if (next->next->sprites && (next->next->sprites != next->sprites)) Bfree(next->next->sprites);
|
||||
Bfree(next->next);
|
||||
next->next = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -265,14 +266,18 @@ void map_undoredo_free(void)
|
|||
while (next->prev)
|
||||
{
|
||||
next = next->prev;
|
||||
if (next->next->sectors && next->next->sectors != next->sectors) Bfree(next->next->sectors);
|
||||
if (next->next->walls && next->next->walls != next->walls) Bfree(next->next->walls);
|
||||
if (next->next->sprites && next->next->sprites != next->sprites) Bfree(next->next->sprites);
|
||||
if (next->next->sectors && (next->next->sectors != next->sectors)) Bfree(next->next->sectors);
|
||||
if (next->next->walls && (next->next->walls != next->walls)) Bfree(next->next->walls);
|
||||
if (next->next->sprites && (next->next->sprites != next->sprites)) Bfree(next->next->sprites);
|
||||
if (next->next == mapstate)
|
||||
mapstate = NULL;
|
||||
Bfree(next->next);
|
||||
next->next = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
Bfree(mapstate);
|
||||
if (mapstate)
|
||||
Bfree(mapstate);
|
||||
mapstate = NULL;
|
||||
}
|
||||
|
||||
|
|
|
@ -196,7 +196,7 @@ void CONFIG_SetDefaults(void)
|
|||
#endif
|
||||
ud.config.useprecache = 1;
|
||||
ud.config.ForceSetup = 1;
|
||||
ud.config.NoAutoLoad = 0;
|
||||
ud.config.NoAutoLoad = 1;
|
||||
ud.config.AmbienceToggle = 1;
|
||||
ud.config.AutoAim = 1;
|
||||
ud.config.FXDevice = 0;
|
||||
|
|
|
@ -1011,6 +1011,7 @@ void C_FreeHashes(void)
|
|||
hash_free(&labelH);
|
||||
}
|
||||
|
||||
// "magic" number for { and }, overrides line number in compiled code for later detection
|
||||
#define IFELSE_MAGIC 31337
|
||||
static int32_t g_ifElseAborted;
|
||||
|
||||
|
@ -1097,12 +1098,17 @@ static int32_t C_SetScriptSize(int32_t size)
|
|||
// Bmemset(&bitptr[osize],0,size-osize);
|
||||
Bmemcpy(newbitptr,bitptr,sizeof(uint8_t) *((osize+7)>>3));
|
||||
}
|
||||
else if (size < osize)
|
||||
else
|
||||
Bmemcpy(newbitptr,bitptr,sizeof(uint8_t) *((size+7)>>3));
|
||||
|
||||
Bfree(bitptr);
|
||||
bitptr = newbitptr;
|
||||
script = newscript;
|
||||
if (script != newscript)
|
||||
{
|
||||
initprintf("Relocating compiled code from to 0x%x to 0x%x\n", script, newscript);
|
||||
script = newscript;
|
||||
}
|
||||
|
||||
g_scriptPtr = (intptr_t *)(script+oscriptPtr);
|
||||
// initprintf("script: %d, bitptr: %d\n",script,bitptr);
|
||||
|
||||
|
@ -1122,7 +1128,7 @@ static int32_t C_SetScriptSize(int32_t size)
|
|||
}
|
||||
}
|
||||
|
||||
if (size > osize)
|
||||
if (size >= osize)
|
||||
{
|
||||
for (i=g_scriptSize-(size-osize)-1; i>=0; i--)
|
||||
if (scriptptrs[i])
|
||||
|
|
|
@ -23,7 +23,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
|||
//-------------------------------------------------------------------------
|
||||
#include "duke3d.h"
|
||||
|
||||
const char *s_buildDate = "20090512";
|
||||
const char *s_buildDate = "20090522";
|
||||
char *MusicPtr = NULL;
|
||||
int32_t g_musicSize;
|
||||
|
||||
|
@ -115,7 +115,7 @@ char *label;
|
|||
char ActorType[MAXTILES];
|
||||
intptr_t *script = NULL;
|
||||
|
||||
int32_t g_scriptSize = 16384;
|
||||
int32_t g_scriptSize = 1048576;
|
||||
|
||||
char typebuflen,typebuf[141];
|
||||
|
||||
|
|
Loading…
Reference in a new issue