George: stations and their wrecks

Freeform discussion about anything related to modding Transcendence.
Post Reply
User avatar
alterecco
Fleet Officer
Fleet Officer
Posts: 1658
Joined: Wed Jan 14, 2009 3:08 am
Location: Previously enslaved by the Iocrym

Is it possible to have a station not leave a wreck?

If not, how can I go about removing the wreck? I noticed that aWreckObj and gSource are identical in OnDestroy for stations, and rightly enough, the game crashes if I objDestroy aWreckObj.

I realise I could probably start a timer, etc etc, or uninstall all devices and remove them (using destroyWhenEmpty), but I was hoping there was a simpler way.

In addition. Where is the graphics for the wreck defined. It is not an image as far as I can see. Is it procedural? Is it something we can change in xml or script?
george moromisato
Developer
Developer
Posts: 2998
Joined: Thu Jul 24, 2003 9:53 pm
Contact:

Lots of room for improvement in the station code.

1. You can try giving a station structuraHitPoints (but no hitPoints). When the station is destroyed, it will be shattered (and thus disappear).
2. There should be a way to specify a wreckUNID (just like there is for ships); when the station object is destroyed, we would delete it and generate the wreck object. Add it to Trac, if that's useful to you.
3. Right now the wrecked station image is procedurally generated; you can change the bitmaps used to generate the blast-marks, but that would change it for all stations. Perhaps there should be a way to define an effect for that.

If you can describe what you're trying to accomplish, I might be able to think of some other features to help.
User avatar
alterecco
Fleet Officer
Fleet Officer
Posts: 1658
Joined: Wed Jan 14, 2009 3:08 am
Location: Previously enslaved by the Iocrym

Hmmm, it seems that if I give a station structuralHitPoints, but no hitPoints, it is abandoned from the start (appears as a hollow square on LRS, but a normal station ingame)

I suppose having a leavesWreck attribute for stations would be great. It would certainly solve my problems

I am working on an adventure where it is part of the gameplay that the player can destroy all he meets. As it is now he will leave behind wrecks of the stations he has destroyed. I can work around it, but I was just wondering if I was missing something.

The workaround is adding a timed event in the OnDestroy to really remove the object

Code: Select all

      <OnDestroy>
        (sysAddObjTimerEvent 1 gSource "Remove")
      </OnDestroy>
      <Remove>
        (objDestroy gSource)
      </Remove>
shanejfilomena
Fleet Officer
Fleet Officer
Posts: 1533
Joined: Tue Mar 22, 2011 8:43 pm
Location: Alaska
Contact:

alterecco wrote:Hmmm, it seems that if I give a station structuralHitPoints, but no hitPoints, it is abandoned from the start (appears as a hollow square on LRS, but a normal station ingame)
I suppose having a leavesWreck attribute for stations would be great. It would certainly solve my problems
First of ALL: I WAS going to say that " LeavesWreck " ( I just realized yesterday it was NOT for attacking the target )
should do it but as I was reading your post again I realized :
DySy has your answer. RPC clears the stations from the map to respawn new ones.

And my mistaken adventure with stations resulted on a "0" hitpoints and a wrecked station where I wanted a live one : so I learned not to do that :) ( i was trying to copy a black market for the Auviq and copied the rescue station by mistake )
Flying Irresponsibly In Eridani......

I don't like to kill pirates in cold blood ..I do it.. but I don't like it..
Post Reply