warezflogga 0 Posted February 26, 2002 Hello All, Here's a toughy. In the Init line of a trigger you can say...... aP AddAction ["",".sqs"] to bring up a menu bar button named "" that will execute the .sqs file when activated. My question is, can you set an init line (activated by a trigger) that will remove this button from the menu bar and by that, the accessability of the script? Share this post Link to post Share on other sites
Spinor 0 Posted February 26, 2002 Hi, yes you can delete an action entry but you must know its ID number. When adding the action write something like this: actionID = unit AddAction["text", "script.sqs"] To remove this action do this: unit RemoveAction actionID Hope this helps, Spinor Share this post Link to post Share on other sites
Snake1999 0 Posted February 26, 2002 Yes. If you add an action ID it's easy to remove the added action: layBomb = player addAction["Lay Bomb","bomb.sqs"] The action ID here is "layBomb". To remove the action, simply add this line: player removeAction layBomb Share this post Link to post Share on other sites
Snake1999 0 Posted February 26, 2002 LOL,, once again I've been beaten by just a couple of mili seconds Share this post Link to post Share on other sites
warezflogga 0 Posted February 27, 2002 Thank you both. This will make all the difference to my mission. If you want to see who is quicker on the trigger, I offer these questions. On your marks....... Q1: Is it possible to set a trigger so that only the player can activate it? And if so, how? Q2: If i create a unit and set its condition as FALSE it will vanish from the game. Is there a dialog that can be typed somewhere that will set the unit as TRUE halfway through the mission? Thus making the unit appear when you wish. As always, any clues would be appreciated. Share this post Link to post Share on other sites
Stulios 0 Posted February 27, 2002 A1.Yes, just group the trigger to the player using f2. Then new options appear in the triggers properties, allowing just the player to activate the trigger. Share this post Link to post Share on other sites
warezflogga 0 Posted February 27, 2002 We'll i'll be stuffed. Never knew you could link them together. My hat off to you. Share this post Link to post Share on other sites
Snake1999 0 Posted February 28, 2002 </span><table border="0" align="center" width="95%" cellpadding="3" cellspacing="1"><tr><td>Quote (warezflogga @ Feb. 27 2002,07:02)</td></tr><tr><td id="QUOTE">Q2: If i create a unit and set its condition as FALSE it will vanish from the game. Is there a dialog that can be typed somewhere that will set the unit as TRUE halfway through the mission? Thus making the unit appear when you wish. As always, any clues would be appreciated.<span id='postcolor'> Well,, you have the create unit comand. Use that Share this post Link to post Share on other sites
warezflogga 0 Posted March 1, 2002 Could you possibly elaborate on the CREATE UNIT command? I'm clearly inept in this department. If you can explain it in lamen, I'd be very grateful. Thanks for your replay all the same. Warezflogga. Share this post Link to post Share on other sites
warezflogga 0 Posted March 1, 2002 Could you possibly elaborate on the CREATE UNIT command? I'm clearly inept in this department. If you can explain it in lamen, I'd be very grateful. Thanks for your replay all the same. Warezflogga. Share this post Link to post Share on other sites