Jump to content
Sign in to follow this  
Intruder_360

Setdammage on Objects?

Recommended Posts

Hi,

i cant set dammage on a object. I ofp it was possible with "(object(44567)) setdammage 1". In ArmA it doesnt work.

Any Idea?

Regards Intruder

Share this post


Link to post
Share on other sites

Hi raedor

thanks for your fast answer, i will try it later.

Edit: furthermore problems with objects. I did try it with "nearestobject444823 setdammage 1", but the bridge was not destroyed.

Regards Intruder

Share this post


Link to post
Share on other sites

nearestObject 444823 maybe?

I heard someone say you needed a space between Object and number.

Share this post


Link to post
Share on other sites
I heard someone say you needed a space between Object and number.

With a space between "nearestObject" and the ID you'll get an error (Type Number, expeced Array).

@Intruder_360

Just tried it in the editor and it doesn't work for me, too. No idea what to do, sorry sad_o.gif

MfG Medicus

Share this post


Link to post
Share on other sites

You need to do something like this...

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">position player nearestobject 1111

When it says it expected array it was looking for the position array.

see Biki - nearestObject

Share this post


Link to post
Share on other sites

Place a GameLogic on the object you want to destroy and give it a name, then add a line similar to this in the initialization, just edit the Game Logic name and object ID.

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">(position GLname nearestObject 606829) setDammage 1

Share this post


Link to post
Share on other sites

the command ive been using is

position player nearestobject 1111 setdammage 1

where 1111 is the id number, this works with normal buildings however when i tried this on a bridge my game crashed (havent tryed it on any other bridges so its worth trying)

Share this post


Link to post
Share on other sites
Place a GameLogic on the object you want to destroy and give it a name, then add a line similar to this in the initialization, just edit the Game Logic name and object ID.

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">(position GLname nearestObject 606829) setDammage 1

Works for me just tested it on a bridge yay.gif

Share this post


Link to post
Share on other sites

Great that works !! wink_o.gif

Now I need the system to repport that it is no more

Im using the radiomast in Sahrani GB-27

"Not alive ??"

hint "Booom"

(not name of the gamelogic apperently and not object219162 and not object 219162)

Any suggestions ?

Share this post


Link to post
Share on other sites

not alive (position player nearestobject 219162)

that should work, worked ok for me

oh and my other command "position player nearestobject 1111 setdammage 1" does work on bridges and all buildings ( had a chance to test it all)

Share this post


Link to post
Share on other sites

You can also try this:

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">

( damage (position player nearestObject 4971 )) >= 1

Share this post


Link to post
Share on other sites

Can we somehow get tanks to have a correct damage effect then and stop one shot one kill

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×