New Frontiers (Shipyard and Sector Question)

The place to discuss scripting and game modifications for X³: Terran Conflict and X³: Albion Prelude.

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

Post Reply
Razgriz9
Posts: 31
Joined: Thu, 3. Aug 06, 02:14
x3

New Frontiers (Shipyard and Sector Question)

Post by Razgriz9 » Tue, 18. Aug 09, 16:09

Greetings!

I'm relatively new to the scripting in X3TC, however I have a fair bit of real world experience, so I'm learning quickly. I had a couple of questions for anyone able to shed some light on them.

First, I'd like to try to add some sectors to the game, such as up around the area of the Terran Sectors, out by the Oort Cloud. Is there anyway to do this? To create brand new sectors? I feel as though there must be with Mods such as Transcend II in development. I didn't see anything in the Script Editor Really, and when I looked to the Galaxy Editor, it started me off with a completely empty Universe... I never used it much in X3R but I thought I remember the Galaxy Editor allowing you to modify the actual game world...?

Secondly, I wanted to add the Terran Factories to their shipyards. I wrote a simple script to add the ones them, however, it added them with no quantity. Was there a command I should be using? I believe (I'm at work and am not 100% sure) that the command I used is: "<RefObj> add product to factory or dock: <Var/Ware>". Is there a better command? Or perhaps a second command that I need to use to stock the stations?

One of my goals also is to create a shipyard which will be able to buy ATF ships from. Would this same command be used? Also in this case would I need any other lines to stock the shipyard properly?

Thank you very much.

Raz

Razgriz9
Posts: 31
Joined: Thu, 3. Aug 06, 02:14
x3

Post by Razgriz9 » Tue, 18. Aug 09, 17:23

I believe I may have found an answer to my question regarding the shipyard not selling the factories. There is indeed a second command I need, along the lines of "add <number> product to <station>". Will test for sure tonight...

Still trying to figure out about adding new sectors though....

ThisIsHarsh
Posts: 1135
Joined: Sun, 19. Oct 08, 18:46
x3tc

Post by ThisIsHarsh » Tue, 18. Aug 09, 19:34

You are right in the adding new factories, you need to add at least one product, then it's infinite.

As for galaxy editting, I've not got any experience, but I know you should be able to load up the current galaxy and edit it. You will need to start a brand new game for it to come into effect, though.
There are 10 types of people in the S&M forums - those who understand binary, and those who don't.

Black holes are where God divided by zero.

User avatar
apricotslice
Posts: 14129
Joined: Sun, 16. May 04, 13:01
x4

Post by apricotslice » Wed, 19. Aug 09, 02:01

Egosoft manage to add sectors by script, but I've never been able to figure out how.

The only way I know of that works is to get the X3_universe.xml out of the maps directory in cat 08, and modify that using the galaxy editor that comes with the X3 editor.

Doing it that way though, means a game restart to get them in, as sectors are stored in the save files.

Razgriz9
Posts: 31
Joined: Thu, 3. Aug 06, 02:14
x3

Post by Razgriz9 » Wed, 19. Aug 09, 15:41

How exactly do you load the maps in the galaxy editor? I didn't seem to be able to find any type of "load" button when I was in the editor.

Luckily this save is not too old, so I don't necessarily mind a restart.

Also, if anyone knows how to add sectors by a script....?

Thanks!

User avatar
spacefueladdict
Posts: 508
Joined: Thu, 12. Jun 08, 15:42
x3tc

Post by spacefueladdict » Wed, 19. Aug 09, 16:03

Razgriz9 wrote:How exactly do you load the maps in the galaxy editor? I didn't seem to be able to find any type of "load" button when I was in the editor.

Luckily this save is not too old, so I don't necessarily mind a restart.

Also, if anyone knows how to add sectors by a script....?

Thanks!
Extract the 'X3-universe.xml' from the 08 cat/dat, then create a folder in the x3 dir, and call it maps, copy/paste the map file into this folder, rename it if you wish.

Then you need to start the game and enable the galaxy editor, to do this start the game, select change pilot name and type in the following,

Makeanapplepiefromscratch

Make sure you get the capital 'M' and the double 'l' in correctly press return

quit to the startup menu and the galaxy editor option should be available.
click on this option, there should be 2 options

1)new universe
2)your file

click on your file, the game will load, and you will find yourself in argon prime in a 'disco'. then you can start to edit the galaxy.

Razgriz9
Posts: 31
Joined: Thu, 3. Aug 06, 02:14
x3

Post by Razgriz9 » Wed, 19. Aug 09, 16:44

Ah, very good then. I assume that you have to use the X3 Mod Manager to extract the cat files? I was having a problem with that program initially... I'll see what I can do to get that working.

A couple other scripting/modding thoughts I came up with. I know that it is handled in other scripts but I was interested in how to enable Jumping to Terran sectors? (I'd like to enable this without creating a new ware if possible, as most <all?> scripts do).

Maybe best asked elsewhere, but is there any way (I figure its in the X3 Editor 2 SOMEWHERE, though hopefully there is a scripting option as well) to change what goods are considered "illegal"? For example a new ware, or an old ware that I want to legalize. :roll:

Last thing (for now :P ) is it at all possible to view/change the rate at which missions are offered in stations? I have noticed that the Terran Sectors tend to have very low numbers of missions, and I wanted to adjust this up.

Thanks in advance!

User avatar
Observe
Posts: 5079
Joined: Fri, 30. Dec 05, 17:47
xr

Post by Observe » Wed, 19. Aug 09, 16:52

apricotslice wrote:Egosoft manage to add sectors by script, but I've never been able to figure out how.
One way is using md: <add_map> Add sectors to map

Razgriz9
Posts: 31
Joined: Thu, 3. Aug 06, 02:14
x3

Post by Razgriz9 » Wed, 19. Aug 09, 17:18

Observe wrote:
apricotslice wrote:Egosoft manage to add sectors by script, but I've never been able to figure out how.
One way is using md: <add_map> Add sectors to map
Do you happen to know where this command is located in the MSCI? I can't seem to find it... Or is this something else that you are referring to? :P

Also, is there a limited size that that X Universe can be? Or can the size be expanded? ( As it seems like you have done for the Transcend Project )

EDIT: Ok, MD = Mission Director ( ignore my idiocy :P ) Figured out that much, now just trying to find where to open it from...?

User avatar
Observe
Posts: 5079
Joined: Fri, 30. Dec 05, 17:47
xr

Post by Observe » Wed, 19. Aug 09, 19:01

Razgriz9 wrote:Do you happen to know where this command is located in the MSCI? I can't seem to find it... Or is this something else that you are referring to? :P
The <add_map> command resides within Mission Director.

[EDIT] I see you discovered that. :wink:

Mission Director is an excellent alternative to scripts in many cases. It continues to amaze me how few modders have boarded the MD bandwagon. :roll:
Razgriz9 wrote:Also, is there a limited size that that X Universe can be? Or can the size be expanded? ( As it seems like you have done for the Transcend Project )
The X-Universe map consists of a 24x20 grid with potential for 480 sectors. Transcend map is a "total conversion", so we suffer no interferance or constraints from vanilla map.

Razgriz9
Posts: 31
Joined: Thu, 3. Aug 06, 02:14
x3

Post by Razgriz9 » Wed, 19. Aug 09, 19:16

Observe. I'm very interested in the MD. :D Out of curiosity is this how you et all went/are going about creating the Transcend Universe? Or what particular tools do you happen to be using to achieve that?

I don't think I'm quite up to a total conversion, but something like adding another system (5-6 ATF Sectors comes to mind), Creating a Player home system, etc..

Are there any limitations for the Mission Director? In terms of things it just can't do? Or is it essentially a mixture of the features in the SE and GE?

User avatar
Observe
Posts: 5079
Joined: Fri, 30. Dec 05, 17:47
xr

Post by Observe » Wed, 19. Aug 09, 19:28

Razgriz9 wrote:Observe. I'm very interested in the MD. :D Out of curiosity is this how you et all went/are going about creating the Transcend Universe? Or what particular tools do you happen to be using to achieve that?
The main tools we used for creating Transcend galaxy were patience, persistence, and unbelievably hard work over an insane period of many many months. [ external image ]

Actually, our map was created using combination of Doubleshadow's Galaxy Editor, the in-game Editor, 3DS Max (for the 00749 file), and an xml editor for various manual adjustments.
Razgriz9 wrote:Are there any limitations for the Mission Director? In terms of things it just can't do? Or is it essentially a mixture of the features in the SE and GE?
The two (script engine and MD) have both differences and similarities in functionality and capabilities. One nice thing about MD is you can "call" scripts in cases where they may be required. There are some very interesting things that can be done better/easier imo with MD than scripting. Really the only way for you to know, is to dig into MD and see what it may offer your interests. [ external image ]

Razgriz9
Posts: 31
Joined: Thu, 3. Aug 06, 02:14
x3

Post by Razgriz9 » Wed, 19. Aug 09, 20:53

Do you happen to know how to setup a mission duration in the MD? For example if I wanted a mission that needed to be completed in 30 minutes, what code would I need for that in the *.xml file?

Post Reply

Return to “X³: Terran Conflict / Albion Prelude - Scripts and Modding”