johnwilso007 0 Posted May 14, 2007 how can i get a trigger to detect that a building that is already on the map has been destroyed by my explosives. 3 satchels take out the warehouse on Rahmadi and its id is 486359. i had a go with GetDammage 486359 >= 1 but it didnt work any ideas? Share this post Link to post Share on other sites
fasad 1 Posted May 14, 2007 Use nearestObject to refer to map objects. The position should be near the object. eg. getDammage ([1232,2151,0] nearestObject 15235) Share this post Link to post Share on other sites
W0lle 1052 Posted May 14, 2007 It's a bit more complicated now with ArmA. Here's how I solved the problem: Place a gamelogic nearby or on the object you want to check. In the initline of the logic type <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">ID486359=position this nearestObject 486359 With the variable ID486359 you now can check the status of the object. Like this: <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">getDammage ID486359 > 1 Share this post Link to post Share on other sites
johnwilso007 0 Posted May 14, 2007 thanks w0lle that worked well. has the objective completed command changed also? as it doesnt seem to work? Share this post Link to post Share on other sites
W0lle 1052 Posted May 14, 2007 Nope, I still use "1" objstatus "done" to tick off the first objective. Nothing has changed here. Share this post Link to post Share on other sites
johnwilso007 0 Posted May 14, 2007 lol. sods law it now works. ha. thank you again. Share this post Link to post Share on other sites
Op4 BuhBye 0 Posted May 14, 2007 How about grouping a trigger to it, and setting "staticobject" not present? Share this post Link to post Share on other sites