OFPEC Forum

Editors Depot - Mission Editing and Scripting => Arma2 - Editing/Scripting Multiplayer => Topic started by: ual002 on 20 Jul 2010, 05:31:12

Title: If object destroyed then set height unit
Post by: ual002 on 20 Jul 2010, 05:31:12
Ok here's the issue.

I'm clueless.  Ive got 3 crew served weapons on the rooftop of a building.  If the building underneath crumbles the CSWs just float there.  Any solutions?  Ive got nothing.  Sepos triggered by getdammage?

-B

EDIT

I can setpos of the guns but I'm unsure how to trigger it when the building in question is destroyed.  The building has an Object ID # if that is any help.  Its usually flattened by either helo mounted FFAR or T90 main cannon.
Title: Re: If object destroyed then set height unit
Post by: Ironman on 25 Jul 2010, 04:35:19
name the guns. EX: gun1, csw2, blah3

have a trigger grouped with the building.... when building (vehicle) not present should be the condition. Then do the setpos on those guns and setDamage/setArmor if necessary.
Title: Re: If object destroyed then set height unit
Post by: ual002 on 01 Aug 2010, 00:59:53
It worked, thanks, I feel stupid, to delete the object entirely I used a funtion from the community base addons, or CBA.

Quote
[srchlt, m2a, box1, box2, box3, box4] call CBA_fnc_deleteEntity