mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2025-01-18 07:22:28 +00:00
Merge branch 'amyhearts-fix' into 'next'
Fix NPC Amy's love hearts crashing if they didn't have a set fuse See merge request STJr/SRB2!641
This commit is contained in:
commit
fc1eff6eee
1 changed files with 10 additions and 6 deletions
16
src/p_mobj.c
16
src/p_mobj.c
|
@ -7977,15 +7977,19 @@ static void P_MobjSceneryThink(mobj_t *mobj)
|
|||
mobj->x = mobj->extravalue1 + P_ReturnThrustX(mobj, mobj->movedir, mobj->cvmem*mobj->scale);
|
||||
mobj->y = mobj->extravalue2 + P_ReturnThrustY(mobj, mobj->movedir, mobj->cvmem*mobj->scale);
|
||||
P_SetThingPosition(mobj);
|
||||
if ((--mobj->fuse) < 6)
|
||||
|
||||
if (!mobj->fuse)
|
||||
{
|
||||
if (!mobj->fuse)
|
||||
{
|
||||
#ifdef HAVE_BLUA
|
||||
if (!LUAh_MobjFuse(mobj))
|
||||
#endif
|
||||
P_RemoveMobj(mobj);
|
||||
return;
|
||||
}
|
||||
mobj->frame = (mobj->frame & ~FF_TRANSMASK) | ((10 - (mobj->fuse*2)) << (FF_TRANSSHIFT));
|
||||
return;
|
||||
}
|
||||
if (mobj->fuse < 0)
|
||||
return;
|
||||
if ((--mobj->fuse) < 6)
|
||||
mobj->frame = (mobj->frame & ~FF_TRANSMASK) | ((10 - (mobj->fuse*2)) << (FF_TRANSSHIFT));
|
||||
}
|
||||
break;
|
||||
case MT_VWREF:
|
||||
|
|
Loading…
Reference in a new issue