Planet Scripting

The place to discuss scripting and game modifications for X²: The Threat.

Moderators: Scripting / Modding Moderators, Moderators for English X Forum

Oldman
Posts: 1666
Joined: Thu, 5. Dec 02, 10:37
x3tc

Planet Scripting

Post by Oldman »

I've just been searching through this forum for any information about planet scripting, but I can't see anything that might answer my questions.
(Tylium's post...Adding Planets....Aegisy's post...Sectors).

I see though in Reven's tutorials that it might be possible to create new or 'doctor' current planets (and other bodies) in X2, though the tutorial isn't ready to view at this time I believe.

My question is, what are the limits specifically in the scripting or creation of new or exsisting planets, will it be possible to, for example, create a planet that you could land your ship on or build a factory?
Maybe even moving or creating a planet nearer to the central grid system and position mineable asteroids nearer to the planet itself.

I'm thinking that maybe you can only create a planet similar as is found in X2 at the moment, sphere textures and atmosphere sort of thing, but I would like to know in the first instance if these ideas are at all possible before getting my hopes set too high! :D

Any information appreciated. :)

Oldman :)
Deleted User

Post by Deleted User »

I think you will find that the planets in the game are anything from a few hundred to a few thousand kilometres distant from the sectors and also are a few thousand kilometres in diameter, so building one in the middle of a secror would destroy everything.
You can't land on planets anyway
bbq
Posts: 54
Joined: Sat, 7. Feb 04, 17:59
x2

Post by bbq »

I think if I could though I'd almost certainly name mine Button Moon. :)
BBQ
----------
Test Pilot
Argon Naval Research Division
User avatar
joebeard
Posts: 520
Joined: Mon, 9. Feb 04, 21:52
x3

Post by joebeard »

Is it possible to make them as big as you want? I would like to add a planet that is *slightly* more realisticly sized (about 10x normal size, though preferably I'd want 100x but I'm guessing that is impossible). Also, is it possible to make them move (other than rotate). In that way I could simulate the sector and its gates orbiting the planet, would be great fun!
Oldman
Posts: 1666
Joined: Thu, 5. Dec 02, 10:37
x3tc

Post by Oldman »

XenonBuster wrote:I think you will find that the planets in the game are anything from a few hundred to a few thousand kilometres distant from the sectors and also are a few thousand kilometres in diameter, so building one in the middle of a secror would destroy everything.
You can't land on planets anyway

:D ...yeah, would kind of defeat the purpose of a sector I'm sure!

Errrmm...no, I am saying to at least move the particular planet in question a 'bit' closer to the central grid (just one option).
Close enough to make building a station/ factory either in a stationary position somewhere near the planet or in a geosync. orbit around the planet (would make manual docking interesting :) ) a practical possibility for ship travelling distances.

In XT I positioned a few factory's (5) in Tharka's sun a few kilometers from the planets surface (I think it was 400? or so) and positioned them roughly around the planets circumference.
While this wasn't very practical in ship traveling time it seemed to give the planet a bit more 'asthetic' value....(It looked 8) ).

Oldman :)
Lorien
Posts: 947
Joined: Wed, 6. Nov 02, 20:31
x3

Post by Lorien »

I would guess it would be possible to move the planets around the sector if you could find out where their data is stored when the universe is created at the start of the game. Ain't got a clue where to start looking though, sorry. :(
Things I've procrastinated on...
1.
Oldman
Posts: 1666
Joined: Thu, 5. Dec 02, 10:37
x3tc

Post by Oldman »

Lorien wrote:I would guess it would be possible to move the planets around the sector if you could find out where their data is stored when the universe is created at the start of the game. Ain't got a clue where to start looking though, sorry. :(
:) ....cheers for the reply.

Data? :o ....let's just take one thing at a time here! :o :D j/k'g

I only want to know at the moment whether some of the things i've mentioned 'are' possible by scripting etc.

I am going to wait, for the 'official'? scripting tutorials, being's as i'll probably bring the whole game to a resounding universal implosion *read..totally K*****r the game up :wink: * if I attempt anything at the moment script wise. I'd imagine (and take heed of the advice given by Burnit!) that some in depth knowledge is needed before attempting anything in the script editor, so at the moment i'm not going to meddle with anything, plus the fact that I'd imagine the scripting etc. would take quite a bit of time and patience, something that I haven't got a lot of at the moment.
Thank's once again for the input though :)

Oldman :)
Nanook
Moderator (English)
Moderator (English)
Posts: 28250
Joined: Thu, 15. May 03, 20:57
x4

Post by Nanook »

Errrmm...no, I am saying to at least move the particular planet in question a 'bit' closer to the central grid (just one option).
Close enough to make building a station/ factory either in a stationary position somewhere near the planet or in a geosync. orbit around the planet (would make manual docking interesting Smile ) a practical possibility for ship travelling distances.
I think in X2, the stations, gates, etc. are considered to be in orbit around the local planet(s). At least, that's what my imagination tells me. :)
Have a great idea for the current or a future game? You can post it in the [L3+] Ideas forum.

X4 is a journey, not a destination. Have fun on your travels.
The_Rock
Posts: 4088
Joined: Wed, 6. Nov 02, 20:31
x2

Post by The_Rock »

Rock's hoping to position planets when he gets the galaxy editor as he will be creating one huge sector first with all the solar system planets in..:)
Oldman
Posts: 1666
Joined: Thu, 5. Dec 02, 10:37
x3tc

Post by Oldman »

The_Rock wrote:Rock's hoping to position planets when he gets the galaxy editor as he will be creating one huge sector first with all the solar system planets in..:)

Ohhh yesssss! :D

*nodd's head approvingly*.....if Brennan & Egosoft won't get the shuttle back to Earth then sure as hell, some of the fans will! :D

Oldman :)
The_Rock
Posts: 4088
Joined: Wed, 6. Nov 02, 20:31
x2

Post by The_Rock »

We will need to only have "earth" type ships in then..:)
"How very touching his meaningless death was. But this fight was never for mortals".
User avatar
Commander Jamieson
Posts: 1478
Joined: Wed, 6. Nov 02, 20:31
x2

Post by Commander Jamieson »

joebeard wrote:Is it possible to make them as big as you want? I would like to add a planet that is *slightly* more realisticly sized (about 10x normal size, though preferably I'd want 100x but I'm guessing that is impossible). Also, is it possible to make them move (other than rotate). In that way I could simulate the sector and its gates orbiting the planet, would be great fun!
It should be possible to make the planets any size you want to as they are just round 3D spheres with a texture coat. In their 3D files is a size figure where I can make my planets any size I want by just adjusting that. As pointed out here the one thing to watch out for is, they don't occupy the same space with any other object in it as collission detection will kick in and something will go boom.

One would be able to create a planet in 3DStudio Max and export this with the Export DLL which is supposed to be part of the modding kit.

In case one wants different textured planets or by changing the size and texture number in the planet's bod file (which is a text file when read and modified with NotePad) this would be relatively easy. If you can see bod files in your v directory (once you used StoneD's and OlisJ's tools on the 01.dat file) look for any large number just beneath the material lines. They should be in the 300 000 to 600 000 size range. The line should read something like:

xxx xxx; / Automatic Object Size

One can alter this with NotePad to any number within reasons.

Re moving the planet about an orbital path, perhaps in 3DS Max's animations section one can give the planet an orbital path which can be replicated in the sector. I am not the 3DS Max expert but I guess that should be possible. Once so designed, one would have to give the exported planet's bob file a unique number, substitude that number with the planet's number one wants changed in the sector file so as not to upset any other use of the same planet in the game if one would just exchange the planet/s bob/bod number. As some planets are used several times in different sectors.

I hope all the above makes sense, once one gets to know the relationship of the cut and v files and once one sees what they are, it will be easier to understand.

Now you will ask, how do I know what a particular bob/bod file is. Easy, if you can not get any clue by reading it as a text file just rename the file you want to know what it is to a particular ship's file's number, say a Goner ship (04171.bob) but back them up first. Use a ship creation script (on my web site's X2 Script page or the X2 Scripting Centre) to create the Goner ship and you will see what this object is, providing it is not a planet, galaxy or any too large object which will touch any of the planets, ships and stations nearby when the object is created.

I did this as above and catalogued over 1000 objects so far this way. I had many "Game Endings" but so what, one moves on to the next object, makes a note in your writings to that effect so you know next time.

I hope this will help :wink:

Cheers
Andypocalypse
Posts: 160
Joined: Thu, 5. Feb 04, 22:28
x4

Post by Andypocalypse »

bbq wrote:I think if I could though I'd almost certainly name mine Button Moon. :)
:lol: i remmember that :lol:
Andypocalypse
Firedancer
Posts: 632
Joined: Wed, 13. Aug 03, 15:45
x3

Post by Firedancer »

Oldman wrote:
XenonBuster wrote:I think you will find that the planets in the game are anything from a few hundred to a few thousand kilometres distant from the sectors and also are a few thousand kilometres in diameter, so building one in the middle of a secror would destroy everything.
You can't land on planets anyway

:D ...yeah, would kind of defeat the purpose of a sector I'm sure!

Errrmm...no, I am saying to at least move the particular planet in question a 'bit' closer to the central grid (just one option).
Close enough to make building a station/ factory either in a stationary position somewhere near the planet or in a geosync. orbit around the planet (would make manual docking interesting :) ) a practical possibility for ship travelling distances.

In XT I positioned a few factory's (5) in Tharka's sun a few kilometers from the planets surface (I think it was 400? or so) and positioned them roughly around the planets circumference.
While this wasn't very practical in ship traveling time it seemed to give the planet a bit more 'asthetic' value....(It looked 8) ).

Oldman :)

aye.. i did the same...but in antigone memorial.. was not even a 100km to the planets atmosphere (the distance at which your ship would explode for coming to close to the planet.)
so you could still see the stations when you entered the sector... looked pretty cool
User avatar
Storm_Front
Posts: 1021
Joined: Mon, 15. Dec 03, 05:27
x2

Post by Storm_Front »

Using the Galaxy Editor, you can move everything, including Planets, Suns, Nebula, Asteroids, Gates, and even Ships and Stations. :D

Return to “X²: The Threat - Scripts and Modding”