Jump to content
Sign in to follow this  
1para{god-father}

Delete Marker on trigger Deactivation ??

Recommended Posts

Must be missing something here , I get the trigger and it all works fine i get the Hint , but then deletevehicle does not seem to work as the marker will not go ?

Is that the correct way to delete a marker ?


/////Make Marker/////
_ambush1 = createmarker ["ambush1",getpos _vehicleambush];
_ambush1 setmarkershape "ELLIPSE";
_ambush1 setmarkersize [150,150];
_ambush1 setMarkerColor "ColorRed";

/////Make Trigger///////////////////////
_triggeram1 = createTrigger["EmptyDetector",[getPos _vehicleambush select 0,getPos _vehicleambush select 1,0]];
_triggeram1 setTriggerArea [150,150,27,false];
_triggeram1 setTriggerActivation ["EAST","NOT PRESENT",true];
_triggeram1 setTriggerTimeout [0,0,0,false];
_triggeram1 setTriggerStatements ["this", "hint 'Mission Finished';","sleep 5; deleteVehicle ambush1;"];

Share this post


Link to post
Share on other sites

Hmmm still cannot get it to delete the marker I get the Hint Finished but it does not delete the marker still ?

Anything eles i am doing wrong ?

_ambush1 = createmarker ["ambush1",getpos _vehicleambush];
_ambush1 setmarkershape "ELLIPSE";
_ambush1 setmarkersize [150,150];
_ambush1 setMarkerColor "ColorRed";

_triggeram1 = createTrigger["EmptyDetector",[getPos _vehicleambush select 0,getPos _vehicleambush select 1,0]];
_triggeram1 setTriggerArea [150,150,27,false];
_triggeram1 setTriggerActivation ["EAST","NOT PRESENT",true];
_triggeram1 setTriggerTimeout [0,0,0,false];
_triggeram1 setTriggerStatements ["this", "Hint 'Mission Finished';","deleteMarker 'ambush1'"];

Share this post


Link to post
Share on other sites
_triggeram1 setTriggerStatements ["this", "Hint 'Mission Finished'; deleteMarker 'ambush1';",""];

Share this post


Link to post
Share on other sites

Deactivate fires when the trigger conditions are no longer met.

Share this post


Link to post
Share on other sites

Assuming it was a "present" type trigger:

_triggeram1 setTriggerStatements ["this", "Hint 'You entered the trigger'; ","hint 'You left the trigger'"];

Share this post


Link to post
Share on other sites

Deactivation is generally only used when the mission starts with the conditions already met or when the trigger is made and the conditions are already met, then one any of the conditions are not met it Deactivates instead of Activates.

Share this post


Link to post
Share on other sites

Just so there is no confusion:

deactivate only activates after the trigger is activated and condition is no longer true.

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  

×