mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-11-11 07:11:39 +00:00
Comment out the A_GetZLimits() call right before the Bassert() in A_MoveSprite(). This call is a problem because the assertion expects "dasectnum" and spr->sectnum to match, but A_GetZLimits() can itself call A_SetSprite() which results in another call to A_MoveSprite() and can potentially change the sectnum again.
This commit also adds the NOTELEPORT sprite flag, which of course prevents sprites from teleporting. git-svn-id: https://svn.eduke32.com/eduke32@3094 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
67c7d67166
commit
067baf626a
2 changed files with 22 additions and 16 deletions
|
@ -399,7 +399,7 @@ int32_t A_MoveSprite(int32_t spritenum, const vec3_t *change, uint32_t cliptype)
|
|||
else if (dasectnum != spr->sectnum)
|
||||
{
|
||||
changespritesect(spritenum, dasectnum);
|
||||
A_GetZLimits(spritenum);
|
||||
// A_GetZLimits(spritenum);
|
||||
}
|
||||
|
||||
Bassert(dasectnum == spr->sectnum);
|
||||
|
@ -3220,8 +3220,12 @@ static void P_FinishWaterChange(int32_t j, DukePlayer_t *ps, int32_t sectlotag,
|
|||
}
|
||||
}
|
||||
|
||||
static int32_t A_CheckNonTeleporting(int32_t pic)
|
||||
static int32_t A_CheckNonTeleporting(int32_t s)
|
||||
{
|
||||
int32_t pic = sprite[s].picnum;
|
||||
|
||||
if (A_CheckSpriteFlags(s, SPRITE_NOTELEPORT)) return 1;
|
||||
|
||||
return (pic == SHARK || pic == COMMANDER || pic == OCTABRAIN
|
||||
|| (pic >= GREENSLIME && pic <= GREENSLIME+7));
|
||||
}
|
||||
|
@ -3355,7 +3359,7 @@ ACTOR_STATIC void G_MoveTransports(void)
|
|||
// comment out to make RPGs pass through water: (r1450 breaks this)
|
||||
// if (sectlotag != 0) goto JBOLT;
|
||||
case STAT_ACTOR:
|
||||
if (sprite[j].extra > 0 && A_CheckNonTeleporting(sprite[j].picnum))
|
||||
if (sprite[j].extra > 0 && A_CheckNonTeleporting(j))
|
||||
goto JBOLT;
|
||||
case STAT_MISC:
|
||||
case STAT_FALLER:
|
||||
|
|
|
@ -168,19 +168,21 @@ typedef struct {
|
|||
#pragma pack(pop)
|
||||
|
||||
enum sflags_t {
|
||||
SPRITE_SHADOW = 0x00000001,
|
||||
SPRITE_NVG = 0x00000002,
|
||||
SPRITE_NOSHADE = 0x00000004,
|
||||
SPRITE_PROJECTILE = 0x00000008,
|
||||
SPRITE_DECAL = 0x00000010,
|
||||
SPRITE_BADGUY = 0x00000020,
|
||||
SPRITE_NOPAL = 0x00000040,
|
||||
SPRITE_NOEVENTCODE = 0x00000080,
|
||||
SPRITE_NOLIGHT = 0x00000100,
|
||||
SPRITE_USEACTIVATOR = 0x00000200,
|
||||
SPRITE_NULL = 0x00000400, // null sprite in multiplayer
|
||||
SPRITE_NOCLIP = 0x00000800, // clipmove it with cliptype 0
|
||||
SPRITE_NOFLOORSHADOW= 0x00001000, // for temp. internal use, per-tile flag not checked
|
||||
SPRITE_SHADOW = 0x00000001,
|
||||
SPRITE_NVG = 0x00000002,
|
||||
SPRITE_NOSHADE = 0x00000004,
|
||||
SPRITE_PROJECTILE = 0x00000008,
|
||||
SPRITE_DECAL = 0x00000010,
|
||||
SPRITE_BADGUY = 0x00000020,
|
||||
SPRITE_NOPAL = 0x00000040,
|
||||
SPRITE_NOEVENTCODE = 0x00000080,
|
||||
SPRITE_NOLIGHT = 0x00000100,
|
||||
SPRITE_USEACTIVATOR = 0x00000200,
|
||||
SPRITE_NULL = 0x00000400, // null sprite in multiplayer
|
||||
SPRITE_NOCLIP = 0x00000800, // clipmove it with cliptype 0
|
||||
SPRITE_NOFLOORSHADOW = 0x00001000, // for temp. internal use, per-tile flag not checked
|
||||
SPRITE_SMOOTHMOVE = 0x00002000,
|
||||
SPRITE_NOTELEPORT = 0x00004000,
|
||||
};
|
||||
|
||||
// custom projectiles
|
||||
|
|
Loading…
Reference in a new issue