Jump to content
ALPHIVE

How make addaction script with some "consequences" ?

Recommended Posts

Hi everybody,

 

Im actually using this script to delete a trigger when addaction done :

 

this addAction["Deactive TRIGGER1", "deleteVehicle TRIGGER1"];

 

Its working, but i would make hint with "TRIGGER1 is deactivated" in same time i deactive the trigger, how can i do for this ?

 

By advance, thank you guys 😉

Share this post


Link to post
Share on other sites

this addAction["Deactive TRIGGER1", {deleteVehicle TRIGGER1;hint "TRIGGER1 is deactivated"}];

Share this post


Link to post
Share on other sites

@ALPHIVE

Here's a callable function for all your trigger deleting needs,
 

Spoiler



you_fnc_deleteTRIG= 
{	params ["_caller", "_actionNAME", "_message"]; 
 
	actOBJ=_caller; 
	actMESS=_message; 
AddActThis=[ player, _actionNAME, 
"\a3\ui_f\data\IGUI\Cfg\holdactions\holdAction_connect_ca.paa", 
"\a3\ui_f\data\IGUI\Cfg\holdactions\holdAction_connect_ca.paa", 
 "alive actOBJ", "alive player",{},{},  
{deleteVehicle actOBJ; systemChat format ["%1", actMESS]; player removeAction addActThis;},{},[],1,0,false,true] call BIS_fnc_holdActionAdd; 
};

// call with
[trigger1, "Delete Trigger", "Trigger Deleted"] call you_fnc_deleteTRIG;


 

Have fun!

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

×