- added a virtual 'used' method that gets called when the player presses use on an actor. This method will only be called if the actor does not have the USESPECIAL flag - that one will be handled as before.
This commit is contained in:
parent
c01289e999
commit
8d7a64bd17
2 changed files with 14 additions and 1 deletions
|
|
@ -5287,6 +5287,14 @@ bool P_UseTraverse(AActor *usething, const DVector2 &start, const DVector2 &end,
|
|||
if (P_ActivateThingSpecial(in->d.thing, usething))
|
||||
return true;
|
||||
}
|
||||
IFVIRTUALPTR(usething, AActor, Used)
|
||||
{
|
||||
VMValue params[] = { usething, in->d.thing };
|
||||
int ret;
|
||||
VMReturn vret(&ret);
|
||||
GlobalVMStack.Call(func, params, 2, &vret, 1);
|
||||
if (ret) return true;
|
||||
}
|
||||
continue;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue