- Rewrote MusicVolumes handling so it's a list and not an array.
- Removed I_SetMusicVolume(). It isn't used. - Moved P_IsFriend(), P_IsHostile(), and P_GetSpecies() into AActor. SVN r18 (trunk)
This commit is contained in:
parent
cf11cbdb30
commit
75d072c09a
17 changed files with 135 additions and 175 deletions
|
|
@ -96,18 +96,20 @@ StateCallData StateCall;
|
|||
|
||||
//==========================================================================
|
||||
//
|
||||
// ACustomInventory :: CallStateChain
|
||||
//
|
||||
// Executes the code pointers in a chain of states
|
||||
// until there is no next state
|
||||
//
|
||||
//==========================================================================
|
||||
|
||||
bool CallStateChain(AActor * actor, FState * State)
|
||||
bool ACustomInventory::CallStateChain (AActor *actor, FState * State)
|
||||
{
|
||||
bool result = false;
|
||||
int counter=0;
|
||||
int counter = 0;
|
||||
|
||||
StateCall.State = State;
|
||||
while (StateCall.State !=NULL)
|
||||
while (StateCall.State != NULL)
|
||||
{
|
||||
// Assume success. The code pointer will set this to false if necessary
|
||||
StateCall.Result = true;
|
||||
|
|
@ -119,7 +121,7 @@ bool CallStateChain(AActor * actor, FState * State)
|
|||
|
||||
// Since there are no delays it is a good idea to check for infinite loops here!
|
||||
counter++;
|
||||
if (counter>=10000) break;
|
||||
if (counter >= 10000) break;
|
||||
|
||||
if (StateCall.State == CallingState)
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue