Jump to content
Sign in to follow this  
tyrspawn

Only add action if item is present on the player

Recommended Posts

Why doesn't this work?

I am almost sure the addaction line is wrong... but i wasn't sure how to format it. I read the wiki, but still don't really understand it. It should add the action only when the player has a laser designator.

 
if (((isserver) && (local player)) || !(isserver)) then 
{
waitUntil {player==player};
player addAction ["Air Support console", "mando_bombs\mando_airsupportdlg.sqf",","player hasWeapon 'LASERDESIGNATOR'"];
};

This other script works off the same principle and works fine:

note: from advanced artillery module thread.

 
if (((isserver) && (local player)) || !(isserver)) then 
{
waitUntil {player==player};
player addAction ["Request Fire Mission","bon_artillery\dialog\openMenu.sqf",["Arti_dlg"],-1,false,true,"","player hasWeapon 'LASERDESIGNATOR'"];
};

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  

×