mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-12-24 02:30:46 +00:00
Minimal changes to get it compiling (and not crashing when ran under
valgrind. Changes don't affect 32 bit mode). Changed aplWeaponClip and friends to int* ,but intptr_t* works as well for me. Final type will determined once the con code has been checked. git-svn-id: https://svn.eduke32.com/eduke32@709 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
60fbc40611
commit
168573d5aa
8 changed files with 36 additions and 36 deletions
|
@ -34,7 +34,7 @@ inline void updateinterpolations(void) //Stick at beginning of domovethings
|
|||
for (;i>=0;i--) oldipos[i] = *curipos[i];
|
||||
}
|
||||
|
||||
void setinterpolation(intptr_t *posptr)
|
||||
void setinterpolation(int *posptr)
|
||||
{
|
||||
int i=numinterpolations-1;
|
||||
|
||||
|
@ -46,7 +46,7 @@ void setinterpolation(intptr_t *posptr)
|
|||
numinterpolations++;
|
||||
}
|
||||
|
||||
void stopinterpolation(intptr_t *posptr)
|
||||
void stopinterpolation(int *posptr)
|
||||
{
|
||||
int i=numinterpolations-1;
|
||||
|
||||
|
|
|
@ -593,7 +593,7 @@ extern char display_mirror,loadfromgrouponly,rtsplaying;
|
|||
extern int groupfile;
|
||||
extern int ototalclock;
|
||||
|
||||
extern intptr_t *animateptr[MAXANIMATES];
|
||||
extern int *animateptr[MAXANIMATES];
|
||||
extern int animategoal[MAXANIMATES];
|
||||
extern int animatevel[MAXANIMATES];
|
||||
// extern int oanimateval[MAXANIMATES];
|
||||
|
@ -691,9 +691,9 @@ extern int everyothertime;
|
|||
extern int mymaxlag, otherminlag, bufferjitter;
|
||||
|
||||
extern int numinterpolations, startofdynamicinterpolations;
|
||||
extern intptr_t oldipos[MAXINTERPOLATIONS];
|
||||
extern intptr_t bakipos[MAXINTERPOLATIONS];
|
||||
extern intptr_t *curipos[MAXINTERPOLATIONS];
|
||||
extern int oldipos[MAXINTERPOLATIONS];
|
||||
extern int bakipos[MAXINTERPOLATIONS];
|
||||
extern int *curipos[MAXINTERPOLATIONS];
|
||||
|
||||
extern short numclouds,clouds[128],cloudx[128],cloudy[128];
|
||||
extern int cloudtotalclock,totalmemory;
|
||||
|
|
|
@ -6356,7 +6356,7 @@ int spawn(int j, int pn)
|
|||
void animatesprites(int x,int y,int a,int smoothratio)
|
||||
{
|
||||
int i, j, k, p, sect;
|
||||
int l, t1,t3,t4;
|
||||
intptr_t l, t1,t3,t4;
|
||||
spritetype *s,*t;
|
||||
int switchpic;
|
||||
|
||||
|
@ -6914,7 +6914,7 @@ PALONLY:
|
|||
|
||||
if (t4)
|
||||
{
|
||||
l = *(int *)(t4+8);
|
||||
l = *(((intptr_t *)t4)+2);
|
||||
|
||||
#if defined(POLYMOST) && defined(USE_OPENGL)
|
||||
if (bpp > 8 && usemodels && md_tilehasmodel(s->picnum,t->pal) >= 0 && !(spriteext[i].flags&SPREXT_NOTMD))
|
||||
|
@ -6970,7 +6970,7 @@ PALONLY:
|
|||
break;
|
||||
}
|
||||
|
||||
t->picnum += k + (*(int *)t4) + l * t3;
|
||||
t->picnum += k + (*(intptr_t *)t4) + l * t3;
|
||||
|
||||
if (l > 0) while (tilesizx[t->picnum] == 0 && t->picnum > 0)
|
||||
t->picnum -= l; //Hack, for actors
|
||||
|
|
|
@ -45,23 +45,23 @@ static int num_braces = 0;
|
|||
|
||||
int redefined_quote_count = 0;
|
||||
|
||||
intptr_t *aplWeaponClip[MAX_WEAPONS]; // number of items in magazine
|
||||
intptr_t *aplWeaponReload[MAX_WEAPONS]; // delay to reload (include fire)
|
||||
intptr_t *aplWeaponFireDelay[MAX_WEAPONS]; // delay to fire
|
||||
intptr_t *aplWeaponHoldDelay[MAX_WEAPONS]; // delay after release fire button to fire (0 for none)
|
||||
intptr_t *aplWeaponTotalTime[MAX_WEAPONS]; // The total time the weapon is cycling before next fire.
|
||||
intptr_t *aplWeaponFlags[MAX_WEAPONS]; // Flags for weapon
|
||||
intptr_t *aplWeaponShoots[MAX_WEAPONS]; // what the weapon shoots
|
||||
intptr_t *aplWeaponSpawnTime[MAX_WEAPONS]; // the frame at which to spawn an item
|
||||
intptr_t *aplWeaponSpawn[MAX_WEAPONS]; // the item to spawn
|
||||
intptr_t *aplWeaponShotsPerBurst[MAX_WEAPONS]; // number of shots per 'burst' (one ammo per 'burst'
|
||||
intptr_t *aplWeaponWorksLike[MAX_WEAPONS]; // What original the weapon works like
|
||||
intptr_t *aplWeaponInitialSound[MAX_WEAPONS]; // Sound made when initialy firing. zero for no sound
|
||||
intptr_t *aplWeaponFireSound[MAX_WEAPONS]; // Sound made when firing (each time for automatic)
|
||||
intptr_t *aplWeaponSound2Time[MAX_WEAPONS]; // Alternate sound time
|
||||
intptr_t *aplWeaponSound2Sound[MAX_WEAPONS]; // Alternate sound sound ID
|
||||
intptr_t *aplWeaponReloadSound1[MAX_WEAPONS]; // Sound of magazine being removed
|
||||
intptr_t *aplWeaponReloadSound2[MAX_WEAPONS]; // Sound of magazine being inserted
|
||||
int *aplWeaponClip[MAX_WEAPONS]; // number of items in magazine
|
||||
int *aplWeaponReload[MAX_WEAPONS]; // delay to reload (include fire)
|
||||
int *aplWeaponFireDelay[MAX_WEAPONS]; // delay to fire
|
||||
int *aplWeaponHoldDelay[MAX_WEAPONS]; // delay after release fire button to fire (0 for none)
|
||||
int *aplWeaponTotalTime[MAX_WEAPONS]; // The total time the weapon is cycling before next fire.
|
||||
int *aplWeaponFlags[MAX_WEAPONS]; // Flags for weapon
|
||||
int *aplWeaponShoots[MAX_WEAPONS]; // what the weapon shoots
|
||||
int *aplWeaponSpawnTime[MAX_WEAPONS]; // the frame at which to spawn an item
|
||||
int *aplWeaponSpawn[MAX_WEAPONS]; // the item to spawn
|
||||
int *aplWeaponShotsPerBurst[MAX_WEAPONS]; // number of shots per 'burst' (one ammo per 'burst'
|
||||
int *aplWeaponWorksLike[MAX_WEAPONS]; // What original the weapon works like
|
||||
int *aplWeaponInitialSound[MAX_WEAPONS]; // Sound made when initialy firing. zero for no sound
|
||||
int *aplWeaponFireSound[MAX_WEAPONS]; // Sound made when firing (each time for automatic)
|
||||
int *aplWeaponSound2Time[MAX_WEAPONS]; // Alternate sound time
|
||||
int *aplWeaponSound2Sound[MAX_WEAPONS]; // Alternate sound sound ID
|
||||
int *aplWeaponReloadSound1[MAX_WEAPONS]; // Sound of magazine being removed
|
||||
int *aplWeaponReloadSound2[MAX_WEAPONS]; // Sound of magazine being inserted
|
||||
|
||||
int g_iReturnVarID=-1; // var ID of "RETURN"
|
||||
int g_iWeaponVarID=-1; // var ID of "WEAPON"
|
||||
|
|
|
@ -37,9 +37,9 @@ extern int g_iHiTagID; // var ID of "HITAG"
|
|||
extern int g_iTextureID; // var ID of "TEXTURE"
|
||||
extern int g_iThisActorID; // var ID of "THISACTOR"
|
||||
|
||||
extern int *actorLoadEventScrptr[MAXTILES];
|
||||
extern intptr_t *actorLoadEventScrptr[MAXTILES];
|
||||
|
||||
extern int *apScriptGameEvent[MAXGAMEEVENTS];
|
||||
extern intptr_t *apScriptGameEvent[MAXGAMEEVENTS];
|
||||
|
||||
extern int otherp;
|
||||
extern int g_currentweapon;
|
||||
|
|
|
@ -4476,8 +4476,8 @@ static int parse(void)
|
|||
insptr++;
|
||||
g_t[5] = *insptr++; // Ai
|
||||
g_t[4] = *(intptr_t *)(g_t[5]); // Action
|
||||
g_t[1] = *(intptr_t *)(g_t[5]+4); // move
|
||||
g_sp->hitag = *(intptr_t *)(g_t[5]+8); // move flags
|
||||
g_t[1] = *(((intptr_t *)g_t[5])+1); // move
|
||||
g_sp->hitag = *(((intptr_t *)g_t[5])+2); // move flags
|
||||
g_t[0] = g_t[2] = g_t[3] = 0; // count, actioncount... g_t[3] = ???
|
||||
if (g_sp->hitag&random_angle)
|
||||
g_sp->ang = TRAND&2047;
|
||||
|
|
|
@ -479,14 +479,14 @@ int AddGameVar(const char *pszLabel, int lValue, unsigned int dwFlags)
|
|||
if (aGameVars[i].dwFlags & GAMEVAR_FLAG_PERPLAYER)
|
||||
{
|
||||
if (!aGameVars[i].plValues)
|
||||
aGameVars[i].plValues=Bcalloc(MAXPLAYERS,sizeof(int));
|
||||
aGameVars[i].plValues=Bcalloc(MAXPLAYERS,sizeof(intptr_t));
|
||||
for (j=0;j<MAXPLAYERS;j++)
|
||||
aGameVars[i].plValues[j]=lValue;
|
||||
}
|
||||
else if (aGameVars[i].dwFlags & GAMEVAR_FLAG_PERACTOR)
|
||||
{
|
||||
if (!aGameVars[i].plValues)
|
||||
aGameVars[i].plValues=Bcalloc(MAXSPRITES,sizeof(int));
|
||||
aGameVars[i].plValues=Bcalloc(MAXSPRITES,sizeof(intptr_t));
|
||||
for (j=0;j<MAXSPRITES;j++)
|
||||
aGameVars[i].plValues[j]=lValue;
|
||||
}
|
||||
|
|
|
@ -39,7 +39,7 @@ actordata_t hittype[MAXSPRITES];
|
|||
short spriteq[1024],spriteqloc,spriteqamount=64;
|
||||
animwalltype animwall[MAXANIMWALLS];
|
||||
short numanimwalls;
|
||||
intptr_t *animateptr[MAXANIMATES];
|
||||
int *animateptr[MAXANIMATES];
|
||||
int animategoal[MAXANIMATES], animatevel[MAXANIMATES], animatecnt;
|
||||
// int oanimateval[MAXANIMATES];
|
||||
short animatesect[MAXANIMATES];
|
||||
|
@ -165,9 +165,9 @@ int mymaxlag, otherminlag, bufferjitter = 1;
|
|||
short numclouds,clouds[128],cloudx[128],cloudy[128];
|
||||
int cloudtotalclock = 0,totalmemory = 0;
|
||||
int numinterpolations = 0, startofdynamicinterpolations = 0;
|
||||
intptr_t oldipos[MAXINTERPOLATIONS];
|
||||
intptr_t bakipos[MAXINTERPOLATIONS];
|
||||
intptr_t *curipos[MAXINTERPOLATIONS];
|
||||
int oldipos[MAXINTERPOLATIONS];
|
||||
int bakipos[MAXINTERPOLATIONS];
|
||||
int *curipos[MAXINTERPOLATIONS];
|
||||
|
||||
int nextvoxid = 0;
|
||||
|
||||
|
|
Loading…
Reference in a new issue