NSTrigger: Add 'Trigger' input, this will make interacting between GoldSrc and Source triggers easier.
This commit is contained in:
parent
1ca716d4fe
commit
9252682c53
2 changed files with 12 additions and 0 deletions
|
@ -52,6 +52,7 @@ class NSTrigger:NSIO
|
|||
/* overrides */
|
||||
virtual void(float) Save;
|
||||
virtual void(string,string) Restore;
|
||||
virtual void(entity, string, string) Input;
|
||||
#endif
|
||||
virtual void(string, string) SpawnKey;
|
||||
};
|
||||
|
|
|
@ -152,6 +152,17 @@ NSTrigger::Restore(string strKey, string strValue)
|
|||
super::Restore(strKey, strValue);
|
||||
}
|
||||
}
|
||||
void
|
||||
NSTrigger::Input(entity eAct, string strInput, string strData)
|
||||
{
|
||||
switch (strInput) {
|
||||
case "Trigger":
|
||||
Trigger(eAct, TRIG_TOGGLE);
|
||||
break;
|
||||
default:
|
||||
super:: Input(eAct, strInput, strData);
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
void
|
||||
|
|
Loading…
Reference in a new issue