Page 1 of 2

[Release] Station Validator 1.0

Posted: Sun May 12, 2013 1:04 pm
by spara
A mechanism to simulate the construction of a destroyed station.

For details and download check the [EliteWiki] wiki.

_ORIGINAL POST_
Hello.

In response to discussion here and here I have a proposition to make. :D.

This oxp tracks the deaths of all stationary stations. Meaning stations that have max speed of 0. Roles, systemIds and deathtimes are noted. Then other oxps can ask for permission for spawning with a command
worldScripts.station_validator.$allowSpawning("your_station_role", rebuildTime)
RebuildTime parameter is optional and defaults to 30 days and can't be over that. The function then returns true or false depending if there has been a death of a station of that particular type and if rebuildTime has not been reached. Multiple stations with the same role are handled with a simple stack. So spawning for example three stations with the same role and two have been marked for destruction, only the third one get's the permission.

Feel free to comment.

Re: Station Validator 0.1 (WIP)

Posted: Sun May 12, 2013 1:38 pm
by JensAyton
I suggest that it should be possible to get a time back instead of a boolean. This way, an enterprising OXPer could add models of a station in various stages of reconstruction. (Destroying a partially-rebuild station should count as destroying the fully-built version for time tracking purposes.)

Re: Station Validator 0.1 (WIP)

Posted: Sun May 12, 2013 2:27 pm
by spara
JensAyton wrote:
I suggest that it should be possible to get a time back instead of a boolean. This way, an enterprising OXPer could add models of a station in various stages of reconstruction. (Destroying a partially-rebuild station should count as destroying the fully-built version for time tracking purposes.)
This is a very cool idea. I think the only thing needed is a function to return the death time (or times in case of multiple stations with the same role) of the original station. Various stages of building could be spawned with different roles and without asking for permission. Their deaths would be noted, but would not affect anything. I'll patch something up later.

Re: Station Validator 0.1 (WIP)

Posted: Sun May 12, 2013 3:48 pm
by Rorschachhamster
In fact, I dabbled a little in Wings with that idea in mind. It's not so easy to envision a construction that could be every station there is... :wink: Until now I just have a untextured skeleton for the central core of a station as it could look totally different than the finished product... :D
And then it would have to look nice enough to at least look like there could be one of Griff's stations in construction... :P

Re: Station Validator 0.1 (WIP)

Posted: Sun May 12, 2013 4:22 pm
by Smivs
Something like this?

Re: Station Validator 0.1 (WIP)

Posted: Sun May 12, 2013 4:46 pm
by Rorschachhamster
Exactly! You can totally see what it looks like if it's finished, so it's not quite as easy if you want the same model work for all stations :? I was even thinking about the space equivalent of hoarding... :P
Oh, and thanks, now I'm hearing that catchy tune again... "bam bam bam baadadam baadadam" :lol:

Re: Station Validator 0.1 (WIP)

Posted: Sun May 12, 2013 5:21 pm
by Svengali
Nice, spara .-)
spara wrote:
JensAyton wrote:
I suggest that it should be possible to get a time back instead of a boolean. This way, an enterprising OXPer could add models of a station in various stages of reconstruction. (Destroying a partially-rebuild station should count as destroying the fully-built version for time tracking purposes.)
This is a very cool idea. I think the only thing needed is a function to return the death time (or times in case of multiple stations with the same role) of the original station. Various stages of building could be spawned with different roles and without asking for permission. Their deaths would be noted, but would not affect anything. I'll patch something up later.
Aye. Spot on.

Re: Station Validator 0.1 (WIP)

Posted: Sun May 12, 2013 5:23 pm
by JensAyton
spara wrote:
Various stages of building could be spawned with different roles and without asking for permission. Their deaths would be noted, but would not affect anything. I'll patch something up later.
But then if you destroy the Bleath Spar at 50 % construction, go away and come back, it will once again be at 50 %. It should have to start over.

Re: Station Validator 0.1 (WIP)

Posted: Sun May 12, 2013 5:30 pm
by spara
JensAyton wrote:
spara wrote:
Various stages of building could be spawned with different roles and without asking for permission. Their deaths would be noted, but would not affect anything. I'll patch something up later.
But then if you destroy the Bleath Spar at 50 % construction, go away and come back, it will once again be at 50 %. It should have to start over.
Ah, quite right. Got to think this feat over again.

Re: Station Validator 0.1.1 (WIP)

Posted: Sun May 12, 2013 6:21 pm
by spara
Version 0.1.1 is up. Fixed a couple of bugs (thanks Svengali) and added some commentary to the code.

Have to ponder the construct idea a bit more. It needs some sort of oxp to station_validator mechanism for an oxp to notify that it built the thing despite the permit. Maybe something like worldScripts.station_validator.$removeDeath("your_station_role") would do? Have to think it thoroughly. But not tonight :D.

Re: Station Validator 0.1.1 (WIP)

Posted: Mon May 13, 2013 3:35 pm
by spara
After pondering a bit, i got an idea :D. What if, the rebuilding of a destroyed station would be done somewhere else and when it's finished, it would be transported through a massive gate. And here's the catch. The rebuilding process seen by the player would actually be the construction of the gate. And when rebuild time has been reached, the gate would be switched to the station. The gate itself could be something like intersecting rings a'la Sothis Station's buoy that would be constructed ring at a time.

The gate could be a part of this oxp and oxps that ask for permit would pass the coordinates they would like the station to spawn to this oxp so that the ring construct could be spawned to the right place. Those rings could be class_rock and they could be indestructible to avoid problems. No need to reset rebuild timer :mrgreen:.

Those rings would be like "under construction, come back later."

How does that sound and is someone interested in modelling such a thing? It would require something like three massive rings that could be put one inside another. All rings would be different entities that would rotate nicely inside another.

Re: Station Validator 0.1.1 (WIP)

Posted: Mon May 13, 2013 8:18 pm
by Svengali
Another option would be to use a shader for it (the original model can be used, just switch the shader).
A example can be found in [EliteWiki] Vector.oxp. Just use -> worldScripts.vector_news.sceneA();
And - as always with tests - don't save the game...

Re: Station Validator 0.1.1 (WIP)

Posted: Tue May 14, 2013 2:30 am
by Diziet Sma
spara wrote:
After pondering a bit, i got an idea :D. What if, the rebuilding of a destroyed station would be done somewhere else and when it's finished, it would be transported through a massive gate.
...

How does that sound...?
Very interesting idea, but seems to me rather beyond the present technological capabilities of GalCop. If they could use gates to move such massive objects, the use of large gates to move bulk commodities about the Ooniverse would probably be common practice. It would be much cheaper (in terms of ships and lives) than shunting everything around in cargo-transport ships.

It seems more likely to me at least that such massive objects as space stations would be built in-situ, as is done both on and above Earth currently.

Re: Station Validator 0.1.1 (WIP)

Posted: Tue May 14, 2013 5:22 am
by spara
Svengali wrote:
Another option would be to use a shader for it (the original model can be used, just switch the shader).
A example can be found in [EliteWiki] Vector.oxp. Just use -> worldScripts.vector_news.sceneA();
And - as always with tests - don't save the game...
A funny thought: The station Would be wrapped in yellow a tape saying "Under Construction" in black.
Diziet Sma wrote:
Very interesting idea, but seems to me rather beyond the present technological capabilities of GalCop.
Yes, the handwavium is always the hardest part. :lol:

Better keep this simple I suppose, if it's ever going to go anywhere.

Re: Station Validator 0.1.1 (WIP)

Posted: Tue May 14, 2013 6:21 am
by cim
spara wrote:
Have to ponder the construct idea a bit more. It needs some sort of oxp to station_validator mechanism for an oxp to notify that it built the thing despite the permit.
Well, in the case of partial construction, it only built something - not the original station.

Rather than having the results stack depend on how many times the function was called, why not instead return an array of destruction times, and let the station OXP determine how to handle them? That should make things simpler for you since you don't have to anticipate all the ways the API might be used in advance.

For multiple stations of the same role, it gets harder: perhaps rather than returning a time, return an object (e.g.):

Code: Select all

{
  role: "coriolis",
  destroyed: "2085179 13:22:06", 
  position: new Vector3D([35000,1000,-3000])
}