mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2024-11-18 02:21:47 +00:00
Revert pointless change to A_RandomState.
This commit is contained in:
parent
826fad4c78
commit
f04c5292c7
1 changed files with 2 additions and 15 deletions
|
@ -8035,7 +8035,7 @@ void A_BossJetFume(mobj_t *actor)
|
|||
|
||||
// Function: A_RandomState
|
||||
//
|
||||
// Description: Chooses one of either two or three state numbers supplied randomly.
|
||||
// Description: Chooses one of the two state numbers supplied randomly.
|
||||
//
|
||||
// nextstate = state number 0
|
||||
// var1 = state number 1
|
||||
|
@ -8045,25 +8045,12 @@ void A_RandomState(mobj_t *actor)
|
|||
{
|
||||
INT32 locvar1 = var1;
|
||||
INT32 locvar2 = var2;
|
||||
UINT8 rand;
|
||||
#ifdef HAVE_BLUA
|
||||
if (LUA_CallAction("A_RandomState", actor))
|
||||
return;
|
||||
#endif
|
||||
|
||||
rand = (var2 ? P_RandomKey(3) : P_RandomKey(2));
|
||||
switch (rand)
|
||||
{
|
||||
case 0:
|
||||
P_SetMobjState(actor, actor->state->nextstate);
|
||||
return;
|
||||
case 1:
|
||||
P_SetMobjState(actor, locvar1);
|
||||
return;
|
||||
case 2:
|
||||
P_SetMobjState(actor, locvar2);
|
||||
return;
|
||||
}
|
||||
P_SetMobjState(actor, P_RandomChance(FRACUNIT/2) ? locvar1 : locvar2);
|
||||
}
|
||||
|
||||
// Function: A_RandomStateRange
|
||||
|
|
Loading…
Reference in a new issue