OFPEC Forum
Editors Depot - Mission Editing and Scripting => Arma2 - Editing/Scripting General => Topic started by: bardosy on 03 Sep 2009, 17:33:26
-
How can I syncronize a sript created unit/group to the Firstaid module?
EDIT:
I found syncronizeObjectsAdd, but
leader grp_name syncronizeObjectsAdd [firstaidmodul_name]wont work.
-
I had the same problem last week but I managed to find solution - Adding these three lines enable all three "first aid"-modules for the group (You may still need to place the modules on map):
nul=[groupname] execVM "\ca\Modules\AIS\data\scripts\IS.sqf";
nul=[groupname] execVM "\ca\Modules\BC\data\scripts\BC.sqf";
nul =[groupname,leader groupname,true] execVM "\ca\Modules\FA\data\scripts\FA.sqf";
-
Nice find! Note though that the First Aid Simulation module and First Aid Module shouldn't be used together. Just one or the other.
-
nul=[groupname] execVM "\ca\Modules\AIS\data\scripts\IS.sqf";
nul=[groupname] execVM "\ca\Modules\BC\data\scripts\BC.sqf";
nul =[groupname,leader groupname,true] execVM "\ca\Modules\FA\data\scripts\FA.sqf";
nice !
where do you exec that code ?
on the server, players who are in the group ? (I want to use this on a pvp mission)
-
I have no experience on MP scripting but I only exec(ed) those three lines once (in FSMscript) for each group. I think you can exec it from anywhere (triggers/sqs/sqf) but if it requires the modules placed on map (and they work same way as ambiet modules with startup time) then the init.sqf and unit-initbox could be too early.
Here is the orginal post where I found the lines for MP:
http://forums.bistudio.com/showpost.php?p=1396448&postcount=10
I followed the same root with pboview and found the scripts for SP.
-
Thank you SaOK!!! It was a huge help!