mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-11-10 23:02:03 +00:00
- use symbolic constants for some statnums
This commit is contained in:
parent
4cfeb9b2cc
commit
4b69a181c3
3 changed files with 6 additions and 15 deletions
|
@ -166,14 +166,15 @@ void animatesprites_d(int x,int y,int a,int smoothratio)
|
||||||
}
|
}
|
||||||
|
|
||||||
if( t->statnum == 99 ) continue;
|
if( t->statnum == 99 ) continue;
|
||||||
if( s->statnum != 1 && s->picnum == APLAYER && ps[s->yvel].newowner == -1 && s->owner >= 0 )
|
if( s->statnum != STAT_ACTOR && s->picnum == APLAYER && ps[s->yvel].newowner == -1 && s->owner >= 0 )
|
||||||
{
|
{
|
||||||
t->x -= mulscale16(MaxSmoothRatio-smoothratio,ps[s->yvel].posx-ps[s->yvel].oposx);
|
t->x -= mulscale16(MaxSmoothRatio-smoothratio,ps[s->yvel].posx-ps[s->yvel].oposx);
|
||||||
t->y -= mulscale16(MaxSmoothRatio-smoothratio,ps[s->yvel].posy-ps[s->yvel].oposy);
|
t->y -= mulscale16(MaxSmoothRatio-smoothratio,ps[s->yvel].posy-ps[s->yvel].oposy);
|
||||||
t->z = ps[s->yvel].oposz + mulscale16(smoothratio,ps[s->yvel].posz-ps[s->yvel].oposz);
|
t->z = ps[s->yvel].oposz + mulscale16(smoothratio,ps[s->yvel].posz-ps[s->yvel].oposz);
|
||||||
t->z += (40<<8);
|
t->z += (40<<8);
|
||||||
}
|
}
|
||||||
else if( ( s->statnum == 0 && s->picnum != CRANEPOLE) || s->statnum == 10 || s->statnum == 6 || s->statnum == 4 || s->statnum == 5 || s->statnum == 1 )
|
else if( ( s->statnum == STAT_DEFAULT && s->picnum != CRANEPOLE) || s->statnum == STAT_PLAYER ||
|
||||||
|
s->statnum == STAT_STANDABLE || s->statnum == STAT_PROJECTILE || s->statnum == STAT_MISC || s->statnum == STAT_ACTOR )
|
||||||
{
|
{
|
||||||
t->x -= mulscale16(MaxSmoothRatio-smoothratio,s->x-hittype[i].bposx);
|
t->x -= mulscale16(MaxSmoothRatio-smoothratio,s->x-hittype[i].bposx);
|
||||||
t->y -= mulscale16(MaxSmoothRatio-smoothratio,s->y-hittype[i].bposy);
|
t->y -= mulscale16(MaxSmoothRatio-smoothratio,s->y-hittype[i].bposy);
|
||||||
|
|
|
@ -153,7 +153,7 @@ void animatesprites_r(int x,int y,int a,int smoothratio)
|
||||||
}
|
}
|
||||||
|
|
||||||
if( t->statnum == 99 ) continue;
|
if( t->statnum == 99 ) continue;
|
||||||
if( s->statnum != 1 && s->picnum == APLAYER && ps[s->yvel].newowner == -1 && s->owner >= 0 )
|
if( s->statnum != STAT_ACTOR && s->picnum == APLAYER && ps[s->yvel].newowner == -1 && s->owner >= 0 )
|
||||||
{
|
{
|
||||||
t->x -= mulscale16(MaxSmoothRatio-smoothratio,ps[s->yvel].posx-ps[s->yvel].oposx);
|
t->x -= mulscale16(MaxSmoothRatio-smoothratio,ps[s->yvel].posx-ps[s->yvel].oposx);
|
||||||
t->y -= mulscale16(MaxSmoothRatio-smoothratio,ps[s->yvel].posy-ps[s->yvel].oposy);
|
t->y -= mulscale16(MaxSmoothRatio-smoothratio,ps[s->yvel].posy-ps[s->yvel].oposy);
|
||||||
|
@ -162,7 +162,8 @@ void animatesprites_r(int x,int y,int a,int smoothratio)
|
||||||
s->xrepeat = 24;
|
s->xrepeat = 24;
|
||||||
s->yrepeat = 17;
|
s->yrepeat = 17;
|
||||||
}
|
}
|
||||||
else if( ( s->statnum == 0 && s->picnum != CRANEPOLE) || s->statnum == 10 || s->statnum == 6 || s->statnum == 4 || s->statnum == 5 || s->statnum == 1 )
|
else if ((s->statnum == STAT_DEFAULT && s->picnum != CRANEPOLE) || s->statnum == STAT_PLAYER ||
|
||||||
|
s->statnum == STAT_STANDABLE || s->statnum == STAT_PROJECTILE || s->statnum == STAT_MISC || s->statnum == STAT_ACTOR)
|
||||||
{
|
{
|
||||||
t->x -= mulscale16(MaxSmoothRatio-smoothratio,s->x-hittype[i].bposx);
|
t->x -= mulscale16(MaxSmoothRatio-smoothratio,s->x-hittype[i].bposx);
|
||||||
t->y -= mulscale16(MaxSmoothRatio-smoothratio,s->y-hittype[i].bposy);
|
t->y -= mulscale16(MaxSmoothRatio-smoothratio,s->y-hittype[i].bposy);
|
||||||
|
|
|
@ -1,11 +0,0 @@
|
||||||
#pragma once
|
|
||||||
BEGIN_SW_NS
|
|
||||||
int DoBeginJump(short SpriteNum);
|
|
||||||
int DoJump(short SpriteNum);
|
|
||||||
int DoBeginFall(short SpriteNum);
|
|
||||||
int DoFall(short SpriteNum);
|
|
||||||
void KeepActorOnFloor(short SpriteNum);
|
|
||||||
int DoActorSlide(short SpriteNum);
|
|
||||||
int DoActorSectorDamage(short SpriteNum);
|
|
||||||
int DoScaleSprite(short SpriteNum);
|
|
||||||
END_SW_NS
|
|
Loading…
Reference in a new issue