mirror of
https://github.com/EpochModTeam/Epoch.git
synced 2024-08-30 18:22:13 +00:00
Ryans Support
Dynamically execFSM a file and return handle.
This commit is contained in:
parent
9f322a0047
commit
62b797f317
@ -0,0 +1,30 @@
|
||||
/*
|
||||
Author: Andrew Gregory - EpochMod.com
|
||||
|
||||
Contributors:
|
||||
|
||||
Description:
|
||||
Dynamically call an FSM and return handle.
|
||||
|
||||
Licence:
|
||||
Arma Public License Share Alike (APL-SA) - https://www.bistudio.com/community/licenses/arma-public-license-share-alike
|
||||
|
||||
Github:
|
||||
https://github.com/EpochModTeam/Epoch/tree/master/Sources/epoch_code/compile/functions/EPOCH_fnc_dynamicFSM.sqf
|
||||
|
||||
Example:
|
||||
_handle = [] call EPOCH_fnc_dynamicFSM.;
|
||||
|
||||
Parameter(s):
|
||||
_this select 0: STRING - FSM Name (without the .fsm)
|
||||
_this select 1: STRING - FSM Path e.g. epoch_code\system
|
||||
_this select 2: ARRAY - Vars to pass to FSM
|
||||
|
||||
Returns:
|
||||
HANDLE
|
||||
*/
|
||||
params ["_file","_path",["_vars",[]],["_ret",-1]];
|
||||
call compile format["
|
||||
_ret = _vars execFSM ""%1\%2.fsm"";
|
||||
",_path,_file];
|
||||
_ret
|
Loading…
Reference in New Issue
Block a user