Jump to content
Sign in to follow this  
themenwithgreenfaces

ACE3 Medical - Having issues with fnc_isBleeding

Recommended Posts

Hello everyone and happy holidays!

 

Recently I have been experimenting a mission scenario - or set of scenarios - in which the missions are very USAF PJ oriented (CSAR, etc). 

In this specific issue I am trying to have a trigger routinely check the bleeding status of an AI - to simulate "stabilizing" an individual (fnc_HasStableVitals seemed too difficult for the player base I am targeting)

 

I am damaging the AI - "casualty" through this trigger

Spoiler

[casualty, 3.0, "body", "vehiclecrash"] call ace_medical_fnc_addDamageToUnit; [casualty, true,0] call ace_medical_fnc_setUnconscious; [casualty, 0.7] call ace_medical_fnc_adjustPainLevel;

 

This trigger is SUPPOSED to check the vitals of the AI in question every 5 or so seconds, then change the status of a task.

Spoiler

Condition:

                 alive player;

On Activation:

                 nul = execVM "functions\PatientAliveLoop1.sqf"; 

"PatientAliveLoop1.sqf"

                 while {true } do {sleep 5;  if (([casualty] call ace_medical_blood_fnc_isBleeding) isEqualTo false) then [{nil}, {["task2", "SUCCEEDED" ] call BIS_fnc_taskSetState }]; hint "ON"; }

 

For the most part, everything works! However when task2 - "Stabilize the Unit" - is created, it is immediately completed even though the AI is 100% bleeding.

 

I am not very good at scripting and am quite new. So any advice to clean, quicken, or fix this is greatly appreciated!

 

Thanks! 

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×