Movable Planets?

More
18 years 1 month ago #18734 by mdvalley
Movable Planets? was created by mdvalley
I added some new features to my megatrucking package that will make the Traffic writers happy. In the old package, you had to Initialize, then tweak some properties before calling LoadShip or UnloadShip. Now those functions will call Initialize on their own if needed and will tweak the values themselves. All that needs to be done to load a ship is to dock it, call UnloadShip and/or LoadShip, and wait for the ship int property “md_epic_podstogo� to hit zero. (And wait a little over a second for the unlock to trigger). Then detach and be on your merry way.

In addition, tMegaTrucking now has a new function, SetUpFreighter(hship freighter, int megapods, set pods), which will add and configure megapods to a ship, then fill the megapods with the pods from the set. Handy for generating traffic ships. Finally, the player feedback messages are not shown when an AI ship uses the spewer.

I haven’t uploaded the new package yet because I’ve been behind on testing it and want to give it at least a little time on my machine before unleashing it on yours.

Barring any unforeseen problems (or worse, feature requests), this package will be the final version, which brings me to the point of the topic. What I am wondering, is it possible to relocate a planet, moon, L-Point, or station in POG alone? As the days pass, these objects should orbit each other, right? I think it would be cool if every time the day updated (i.e., every capsule jump), POG calculated the exact positions of every body on the map and moved them all. It should be possible to compute the x, y, and z location of any map object simply by its initial position (read from the map file) and the day count (from a global variable). I’d also need the masses of each planet, but that’s easy enough to figure from the radius and a guessed density. While I'm at it, I can even calculate out the spacing on the L-Points.

I think it would make a fun project, and add one more notch on the cool factor in Torn Stars.

Can it be done in POG without breaking anything?

Please Log in or Create an account to join the conversation.

More
18 years 1 month ago #14814 by GrandpaTrout
Replied by GrandpaTrout on topic Movable Planets?
Your welcome to try. I have never tried moving a planet sim. Since PS never did it, I am guessing it is not possible. And it will most likely cause crashes. But your welcome to try. The functions are there to place everything as an offset of system center.

I would just code something that moves a planet very far away. Then hop into space, run the function and see if the planet moves.

Please Log in or Create an account to join the conversation.

More
18 years 1 month ago #14816 by cambragol
Replied by cambragol on topic Movable Planets?
Good to hear that you are still polishing up the megatrucking package. Granpatrout and I were discussing something last night that is a little similar to the realism you have added to the unloading/loading of pods. We were discussing how pods were going to be generated at player owned Mines. I believe GT was opting for the instantaneous delivery, ala standard Torn Stars. I was wondering whether we couldn't have the pods slowly build/line up in an orderly fashion beside the mine/asteroid. This might be an area you would find interesting to tackle once US ships.

As for making ships, moons and other objects actually orbit...Well that is just insanely cool. I know little about the pog involved, but like the sound of the goal.

We have discussed reintroducing the 'Uber' planets (with full spectral reflections etc) that I created at some point, and if we ever managed to, that would open the possibility of using non-PS planets for all planets in the cluster. Which may or may not make the task of giving them all orbits easier.

Please Log in or Create an account to join the conversation.

More
18 years 1 month ago #14818 by mdvalley
Replied by mdvalley on topic Movable Planets?
A quick test of the new package was acceptable, but the site won’t let me upload it. Tells me I have to be authorized.

I wrote up a quick package that will randomly relocate a specific moon around its parent at the push of a button. I compiled it, put it in game, flew over, crossed my fingers, and gave it a push.

The moon moved. I pushed the button from various places. It moved in the game world and it moved on the map. It moved when I was near it, and when I was outside the culling distance. It moved when I wasn’t even in the same system!

Leaving the system and coming back had no effect on its position.

Please Log in or Create an account to join the conversation.

More
18 years 1 month ago #14820 by GrandpaTrout
Replied by GrandpaTrout on topic Movable Planets?
Wow! Even the map moved. I thought that screen would crash if any of them would.

I wonder if you can use the angular velocity commands to slow down the rotation rate. Or even stop it.

The only trick now is how to handle the motion of the stations to track with the planet. There will need to be a link established somehow. Visit each station, find the nearest body, and attach that as a property.

The planets should only be moved while the player is between systems. So use EnterSpace as the event. I would only mess around the system where the player is going, to keep the calculations to a minimum and avoid crashing planets into player wingmen etc.

You still might have to check for collisions and move player wingmen out of the way.

I am looking forward to seeing what you do with this.

Please Log in or Create an account to join the conversation.

More
18 years 1 month ago #14821 by Shane
Replied by Shane on topic Movable Planets?
Wow! That's amazing... I wouldn't have thought that was possible. :)

Does the Starmap update correctly? If a movement is initiated while the Starmap is open, does it update immediately or remain the same until reopened?

Please Log in or Create an account to join the conversation.