Page 1 of 1

Can someone help fix this gadget?

Posted: 16 Oct 2010, 22:09
by Forboding Angel
http://pastebin.ca/1964269

Basically, what it's supposed to do is add a customparam for weapons that will cause that weapon to not damage (or do -damage in this case) to enemy units.

Quantum already helped me some (This is a mutation of his no friendly fire gadget), and I've tried everything I could think of (Which, admittedly, isn't much).

Anyone see where I went wrong?

Re: Can someone help fix this gadget?

Posted: 16 Oct 2010, 22:31
by Niobium
In new spring don't you have to return two values for PreDamaged, being damage and impulse? Other than that it looks pretty solid.

Re: Can someone help fix this gadget?

Posted: 16 Oct 2010, 22:45
by Forboding Angel
Problem is, it doesn't work :-(

Also about the two damage values you mentioned... I don't understand :cry:

Re: Can someone help fix this gadget?

Posted: 16 Oct 2010, 23:23
by bobthedinosaur
well wouldnt you define them as 0, 0 for 0 damage and 0 impulse?

Re: Can someone help fix this gadget?

Posted: 16 Oct 2010, 23:55
by Niobium
bobthedinosaur wrote:well wouldnt you define them as 0, 0 for 0 damage and 0 impulse?
Yep, so you'd have:
return damage, 1
or
return 0, 0

At least this is what every damage gadget in BA was changed to with new spring.

Re: Can someone help fix this gadget?

Posted: 17 Oct 2010, 02:16
by FLOZi
You only have to return the first value, second is optional.

(Unless it was broken again in 82.6.1 but I haven't heard any complaints from S44 testers)