From f1311c515db33e7adf2179d89559140356bf12f9 Mon Sep 17 00:00:00 2001 From: toasterbabe Date: Tue, 19 Jul 2016 13:45:31 +0100 Subject: [PATCH] Making FF_MIDDLESTARTCHANCE more useful for FF_ANIMATE animations. --- src/p_mobj.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/p_mobj.c b/src/p_mobj.c index 5e85e4de2..eec959b62 100644 --- a/src/p_mobj.c +++ b/src/p_mobj.c @@ -533,7 +533,7 @@ boolean P_SetPlayerMobjState(mobj_t *mobj, statenum_t state) mobj->sprite = st->sprite; mobj->frame = st->frame; if ((st->frame & (FF_ANIMATE|FF_MIDDLESTARTCHANCE)) == (FF_ANIMATE|FF_MIDDLESTARTCHANCE)) - mobj->frame += (st->var1)/2; + mobj->frame += P_RandomKey(st->var1); } // Modified handling. @@ -648,7 +648,7 @@ boolean P_SetMobjState(mobj_t *mobj, statenum_t state) mobj->sprite = st->sprite; mobj->frame = st->frame; if ((st->frame & (FF_ANIMATE|FF_MIDDLESTARTCHANCE)) == (FF_ANIMATE|FF_MIDDLESTARTCHANCE)) - mobj->frame += (st->var1)/2; + mobj->frame += P_RandomKey(st->var1); } // Modified handling.