Issue with Destroy command on Strafer/Bomber

Started by Grayzzur, October 05, 2014, 09:10:30 PM

Previous topic - Next topic

Grayzzur

The Destroy command doesn't seem to work the same on Strafers and Bombers as on other units. Destroy(<<unitID>> 1) gives the small soundless flash as expected, but all other Destroy options produce the full explosion with sound.

(Also, is there a way to remove an un-built unit without the "Strafer Lost!" type message popping up?)
"Fate. It protects fools, little children, and ships named 'Enterprise.'" -William T. Riker

knucracker

Looks like when the landing pad is destroyed the pad itself should obey the destroy options.  The pad in turn will then destroy the associated flying unit, and it does not pass along the destroy options (one of them it does... that's why "1" works).  So, the only way to work around this would be to manually destroy the flying unit yourself first, then destroy the pad (back to back calls from CRPL).  That might work... maybe :)

For the popup event message, it looks like the only hope there might be to use mode 1.... and to destroy the strafer manually before destroying the pad, like the above suggestion.  Again, not tested.  That's just my first assessment from looking at the code first thing in the morning on Monday :)

Grayzzur

I'll play around with it and see what comes up.

Does the flying unit exist in the game yet when the pad has not been completely built?
"Fate. It protects fools, little children, and ships named 'Enterprise.'" -William T. Riker

knucracker

I bet it doesn't... which makes things extra complicated for getting the UID of the flying unit...