- scriptified the functions in a_possessed.cpp and added the needed exports and constants.
- fixed: Script functions did not receive the function name when being created. - relaxed the asserts for PARAM_STATE, because the VM knows nothing about ATAG_STATE. Any state variable's content (e.g. Actor.SeeState) will receive ATAG_GENERIC, rather than ATAG_STATE. - added a 'NeedResult' flag so that certain operations can create shorter code if the result of the expression is not needed. So far only used for postdecrement/increment statements on local variables (which is the most frequent case where this matters.) - fixed postincrement and decrement for local variables. Due to the result preservation semantics it created faulty code.
This commit is contained in:
parent
33d00070b5
commit
823c52aeb2
16 changed files with 246 additions and 170 deletions
|
|
@ -510,6 +510,14 @@ bool AActor::SetState (FState *newstate, bool nofunction)
|
|||
return true;
|
||||
}
|
||||
|
||||
DEFINE_ACTION_FUNCTION(AActor, SetState)
|
||||
{
|
||||
PARAM_SELF_PROLOGUE(AActor);
|
||||
PARAM_STATE(state);
|
||||
PARAM_BOOL_OPT(nofunction) { nofunction = false; }
|
||||
ACTION_RETURN_BOOL(self->SetState(state, nofunction));
|
||||
};
|
||||
|
||||
//============================================================================
|
||||
//
|
||||
// AActor :: AddInventory
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue