OFPEC Forum
Editors Depot - Mission Editing and Scripting => ArmA - Editing/Scripting General => Topic started by: Python1 on 11 May 2009, 18:09:18
-
Hi everyone, I'm very excited to be back making missions again with ArmA. However, I've found that I have forgotten some very simple things and need your help with them.
One- I would like to spawn a green smoke grenade at the drop zone but can't quite remember how. Pretty sure I need to createVehicle, but for that I need the location of, and I'm not sure how to find the location of the invisible H, can I use the H as location? Can someone post the syntax for me?
Two-Once the radar towers are destroyed I would like to remove the ammo of the AAA defenses, but can't remember that syntax either (note: I need the trigger to read both towers are dead). So I'm thinking "not alive Radar1 && not alive Rader2" activation "whatever syntax removes ammo from gun1 gun2 etc".
I've been searching the forums, and will continue to do so because I know my answers are hidden in there, but if anyone has the time to post a quick reply I'd really appreciate it.
-
Hi there, and welcome (back) to ArmA editing!
Answer one: createvehicle is indeed the command you need, together with the 'vehicle' you want to create + getpos to decide the position of the created object. You can use the "ammo classname" from this list: CfgWeapons (http://www.ofpec.com/COMREF/index.php?action=read&id=68) for the smokeshell to create it. Then you use getpos get the location of the invisible h So, e.g.:
bomb1= "SmokeShellGreen" createvehicle getpos InvisH1
(the bomb1= is necessary, yes)
Answer two: What are the AA defenses? Shilkas, Strela-carrying soldiers, machinegun nests? Whatever the case, I think removeAllWeapons (http://www.ofpec.com/COMREF/index.php?action=details&id=264) should do the trick, but if not you might have to start experimenting with removeMagazines (http://www.ofpec.com/COMREF/index.php?action=details&id=267) and the above mentioned CfgWeapons list (e.g., remove all the "2000Rnd_23mm_AZP85" magazines from the Shilka etc.) So:
On Activation: {removeallweapons _x} foreach [gun1, gun2, gun3...]
Might do it :)
Good luck!
Wolfrug out.
-
Smoke works great, I had been trying camcreate after finding this post HERE http://www.ofpec.com/forum/index.php?topic=17892.0. But I knew it was creatVehicle I needed. As for the removeMagazines, I'll have to check on that, but your post has given me enough reference to solve the rest I'm sure. Thanks for your help.