Try using "ARTY_Sh_105_HE" as the weapon spawned. That usually works for artillery - might explode well enough on contact with heli?
Try using "ARTY_Sh_105_HE" as the weapon spawned. That usually works for artillery - might explode well enough on contact with heli?
Maybe spawning it then attachto? So it detonates ON the heli's position? Not too sure, mate. If you find out, please tell.
This was something I struggled with when I wrote a comprehensive bomb script. To detonate a bomb within a moving air target, I found this works:
Hopefully my var names are self explanatory. To get the bomb (and the holder) to occupy the same space as the aircraft model, you must use "CAN_COLLIDE". You can skip the weaponholder, but the bomb is far less effective. However, you may prefer it that way if you want it to look good, but not cause catastrophic damage.Code:_warhead = createVehicle [_explosive, _bombLoc, [], 0, "CAN_COLLIDE"]; _holder = createVehicle ["weaponHolder", _bombLoc, [], 0, "CAN_COLLIDE"]; _warhead setPosATL (getPosATL _holder);
Last edited by AZCoder; Oct 21 2010 at 05:40.
Not sure if I am doing this right. Tried via trigger and script, but didn't work properly and showed no script errors. Could you explain how to use this?
Yeah. In the editor I placed a little bird and named it bomb just to be simple. Created a trigger which I grouped to the player (for ease of testing) and have it calling "bomb.sqf":
When I walk into the trigger, the 125mm shell goes off which gives the nice poof effect. Then the setHit command does the real damage, and it spun around in circles for quite a while. One key thing I have noticed is to get vertical position correct, you need either getPosATL if over land, or getPosASL if over water. Otherwise the bomb may explode high or low, and look silly.Code:_bombLoc = getPosATL bomb; _warhead = createVehicle ["Sh_125_HE", _bombLoc, [], 0, "CAN_COLLIDE"]; _holder = createVehicle ["weaponHolder", _bombLoc, [], 0, "CAN_COLLIDE"]; _warhead setPosATL (getPosATL _holder); bomb setHit ["mala vrtule", 0.95];