Search the Community
Showing results for tags 'waking'.
Found 1 result
-
Download: MIL_SleepingAI - Dropbox/Armaholic Demo SP Mission - Dropbox Description: Uses beds and other user-defined objects to have AI start a mission sleeping on them. AI can then be left asleep or woken up on command. Features: - SP/MP - Predefined support for: - Vanilla sleeping bags. - Vanilla sleeping mats. - Vanilla shooting mats. - LoW stretchers. - The vanilla bed. - Ability to define other objects as beds. To use: - Copy the folder MIL_sleepingAI to your mission folder. - Place a sleeping bag, mat, bed or other custom object into the mission. - Position a unit near their required bed. They must be within 5m of the object to work. - Run this command where the unit is local before the mission starts (e.g. initServer.sqf if created on the server, or init.sqf for SP): nul = [_units,_otherBeds] execVM "MIL_SleepingAI\initSleepingAI.sqf"; _units - array - list of objects to start asleep. _otherBeds - array (embedded) - optional. Default - []. - list of other object classnames ,their [x,y,z] offsets and direction adjustments (solution to units laying perpendicular to objects). - offset and angle adjustment MUST be defined, and should be tested and adjusted for best positioning of AI. Examples: nul = [units group1] execVM "MIL_SleepingAI\initSleepingAI.sqf"; _otherBeds = [ ["Land_Stretcher_01_F",[0,0,0],0], //AI will be at 0 degrees to object's "north axis" ["Land_WoodenTable_large_F",[0,0,0],90] //AI will be at 90 degrees to object's "north axis" ]; nul = [units group1,_otherBeds] execVM "MIL_SleepingAI\initSleepingAI.sqf"; - To wake the AI up, run this command: nul = [_unit,_pos,_enableMoving] spawn MIL_fnc_WakeUp; _unit - object - name given to the sleeping unit. _pos - string - stance that the unit is to be in, example: - "Up", "Middle", "Down", "NotProne" (uses either "Up" or "Middle"), "Auto" (normally the default AI setting). - optional. Default - "Auto" _enableMoving - boolean - allow AI to move from bed once woken up. - optional. Default - false. - NOTE - to get AI moving at a later stage, use: - _unit enableAI "PATH" Examples: nul = [unit1] spawn MIL_fnc_WakeUp; //setUnitPos "Auto" is used. {nul = [_x,"NotProne"] spawn MIL_fnc_WakeUp;} forEach (units group1); nul = [unit2,"Auto",true] spawn MIL_fnc_WakeUp; Media: Demo (38s): If anyone finds any problems please let me know. Thank you. Change log: