Quote:
|
Originally Posted by ImmoMan
- 2 buttons, one of them just creates an upgrade object (which provides radar and drains power) and then the other one destroys it. Creating the object is easy, but how do I destroy it with the other button?
|
You could make it so the upgrade object has an armour type only damageable by one damage type. The other button creates an object with a lifetime of 10 or something which fires a weapon with that damage type using FireWeaponWhenDead. You would also have to add the same FireWeaponWhenDead behaviour to the building to kill theobject when the building dies. Alternatively, if you use the drone code you could set it so it dies when the building dies anyway. You should use the ConflictsWith thing so that the 2nd upgrade can only be built when the first one is. Hope this helps. I thought of it a couple of days ago for something but i can't remmber what is was now........
