- two more

This commit is contained in:
Christoph Oelckers 2020-11-02 23:18:44 +01:00
parent ac5ea2f1c9
commit 4add2b5839
4 changed files with 10 additions and 20 deletions

View file

@ -181,21 +181,11 @@ inline int bossguy(DDukeActor* pSprite)
// old interface versions of already changed functions // old interface versions of already changed functions
inline void RANDOMSCRAP(spritetype* s, int i)
{
return RANDOMSCRAP(&hittype[s - sprite]);
}
inline void deletesprite(int num) inline void deletesprite(int num)
{ {
deletesprite(&hittype[num]); deletesprite(&hittype[num]);
} }
inline int ssp(int i, unsigned int cliptype) //The set sprite function
{
return ssp(&hittype[i], cliptype);
}
int movesprite_ex_d(DDukeActor* actor, int xchange, int ychange, int zchange, unsigned int cliptype, Collision& result); int movesprite_ex_d(DDukeActor* actor, int xchange, int ychange, int zchange, unsigned int cliptype, Collision& result);
int movesprite_ex_r(DDukeActor* actor, int xchange, int ychange, int zchange, unsigned int cliptype, Collision& result); int movesprite_ex_r(DDukeActor* actor, int xchange, int ychange, int zchange, unsigned int cliptype, Collision& result);

View file

@ -640,7 +640,7 @@ void resetpspritevars(int g)
j = connectpoint2[j]; j = connectpoint2[j];
} }
else deletesprite(i); else deletesprite(act);
} }
} }

View file

@ -342,7 +342,7 @@ int spawn_d(int j, int pn)
sp->hitag = i; sp->hitag = i;
sp->xvel = 16; sp->xvel = 16;
ssp(i,CLIPMASK0); ssp(act, CLIPMASK0);
act->temp_data[0] = 17; act->temp_data[0] = 17;
act->temp_data[2] = 0; act->temp_data[2] = 0;
act->temp_data[5] = sp->ang; act->temp_data[5] = sp->ang;
@ -987,7 +987,7 @@ int spawn_d(int j, int pn)
sp->lotag = 0; sp->lotag = 0;
sp->z -= (32<<8); sp->z -= (32<<8);
sp->zvel = -1024; sp->zvel = -1024;
ssp(i,CLIPMASK0); ssp(act, CLIPMASK0);
sp->cstat = krand()&4; sp->cstat = krand()&4;
} }
else else
@ -1091,7 +1091,7 @@ int spawn_d(int j, int pn)
sp->cstat = 16+128+2; sp->cstat = 16+128+2;
sp->xrepeat=sp->yrepeat=1; sp->xrepeat=sp->yrepeat=1;
sp->xvel = -8; sp->xvel = -8;
ssp(i,CLIPMASK0); ssp(act, CLIPMASK0);
} }
case CEILINGSTEAM: case CEILINGSTEAM:
changespritestat(i,STAT_STANDABLE); changespritestat(i,STAT_STANDABLE);
@ -1146,7 +1146,7 @@ int spawn_d(int j, int pn)
sp->owner = i; sp->owner = i;
changespritestat(i,6); changespritestat(i,6);
sp->xvel = 8; sp->xvel = 8;
ssp(i,CLIPMASK0); ssp(act, CLIPMASK0);
break; break;
case TOILET: case TOILET:

View file

@ -1160,7 +1160,7 @@ int spawn_r(int j, int pn)
{ {
sp->zvel = 0; sp->zvel = 0;
} }
ssp(i,CLIPMASK0); ssp(act, CLIPMASK0);
sp->cstat = krand()&4; sp->cstat = krand()&4;
} }
else else
@ -1172,7 +1172,7 @@ int spawn_r(int j, int pn)
if( ( ud.multimode < 2 && sp->pal != 0) || (sp->lotag > ud.player_skill) ) if( ( ud.multimode < 2 && sp->pal != 0) || (sp->lotag > ud.player_skill) )
{ {
sp->xrepeat = sp->yrepeat = 0; sp->xrepeat = sp->yrepeat = 0;
changespritestat(i, STAT_MISC); changespritestat(act, STAT_MISC);
break; break;
} }
@ -1355,10 +1355,10 @@ int spawn_r(int j, int pn)
sp->cstat = 16+128+2; sp->cstat = 16+128+2;
sp->xrepeat=sp->yrepeat=1; sp->xrepeat=sp->yrepeat=1;
sp->xvel = -8; sp->xvel = -8;
ssp(i,CLIPMASK0); ssp(act, CLIPMASK0);
} }
case CEILINGSTEAM: case CEILINGSTEAM:
changespritestat(i,STAT_STANDABLE); changespritestat(act, STAT_STANDABLE);
break; break;
case SECTOREFFECTOR: case SECTOREFFECTOR:
spawneffector(act); spawneffector(act);
@ -1397,7 +1397,7 @@ int spawn_r(int j, int pn)
sp->owner = i; sp->owner = i;
changespritestat(i,6); changespritestat(i,6);
sp->xvel = 8; sp->xvel = 8;
ssp(i,CLIPMASK0); ssp(act, CLIPMASK0);
break; break;
case EMPTYBIKE: case EMPTYBIKE: