Merge branch 'EOL-28' into EOL

# Conflicts:
#	src/p_enemy.c
This commit is contained in:
Alam Ed Arias 2018-11-27 23:08:58 -05:00
commit 87f9cef564
2 changed files with 11 additions and 3 deletions

View file

@ -10954,7 +10954,10 @@ void A_FlickyAim(mobj_t *actor)
return;
#endif
if (actor->momx == actor->momy && actor->momy == 0)
if ((actor->momx == actor->momy && actor->momy == 0)
|| (actor->target && P_IsFlickyCenter(actor->target->type)
&& actor->target->extravalue1 && (actor->target->flags & MF_SLIDEME)
&& P_AproxDistance(actor->x - actor->target->x, actor->y - actor->target->y) >= actor->target->extravalue1))
flickyhitwall = true;
P_InternalFlickyBubble(actor);
@ -10986,7 +10989,10 @@ void A_FlickyAim(mobj_t *actor)
}
else if (flickyhitwall)
{
actor->angle += ANGLE_180;
if (actor->target && P_IsFlickyCenter(actor->target->type))
actor->angle = R_PointToAngle2(actor->target->x, actor->target->y, actor->x, actor->y) + P_RandomRange(112, 248) * ANG1;
else
actor->angle += P_RandomRange(112, 248)*ANG1; //P_RandomRange(160, 200) * ANG1;//ANGLE_180;
actor->threshold = 0;
}
}

View file

@ -7137,7 +7137,9 @@ void P_MobjThinker(mobj_t *mobj)
case MT_FLICKY_16_CENTER:
case MT_SECRETFLICKY_01_CENTER:
case MT_SECRETFLICKY_02_CENTER:
if (mobj->tracer && (mobj->flags & MF_NOCLIPTHING))
if (mobj->tracer && (mobj->flags & MF_NOCLIPTHING)
&& (mobj->flags & MF_GRENADEBOUNCE))
// for now: only do this bounce routine if flicky is in-place. \todo allow in all movements
{
if (!(mobj->tracer->flags2 & MF2_OBJECTFLIP) && mobj->tracer->z <= mobj->tracer->floorz)
mobj->tracer->momz = 7*FRACUNIT;