- implemented VMCallWithDefaults and used it for all calls with variable arguments.
This isn't used for the 3 action function calls because it requires an array allocation which would be a bit too costly for something as frequently called as action functions. They will need a different approach.
This commit is contained in:
parent
6d7710165c
commit
97573a0452
6 changed files with 23 additions and 12 deletions
|
|
@ -175,13 +175,13 @@ bool FState::CallAction(AActor *self, AActor *stateowner, FStateParamInfo *info,
|
|||
|
||||
if (stateret == nullptr)
|
||||
{
|
||||
VMCallWithDefaults(ActionFunc, params, ActionFunc->ImplicitArgs, nullptr, 0);
|
||||
VMCallAction(ActionFunc, params, ActionFunc->ImplicitArgs, nullptr, 0);
|
||||
}
|
||||
else
|
||||
{
|
||||
VMReturn ret;
|
||||
ret.PointerAt((void **)stateret);
|
||||
VMCallWithDefaults(ActionFunc, params, ActionFunc->ImplicitArgs, &ret, 1);
|
||||
VMCallAction(ActionFunc, params, ActionFunc->ImplicitArgs, &ret, 1);
|
||||
}
|
||||
}
|
||||
catch (CVMAbortException &err)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue