Ship Types Trying to add

The place to discuss scripting and game modifications for X4: Foundations.

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

Post Reply
SystemsEternal
Posts: 46
Joined: Sat, 13. Oct 18, 12:24
x4

Ship Types Trying to add

Post by SystemsEternal » Sun, 24. Apr 22, 12:01

So ive been looking into the files and for the life of me i cant find where the ship macros reference the ship types from the t files.

They have a ship type entry but that usually says scout or heavyfigher etc.

Ive tried adding my own ship type enhancedscout with an entry into the t file page 20221 titled Ship Types Enhanced Scout, but in game that leaves a blank behind the ship, as in no type. so thats not working.

Ive tried looking for another file that cross references scout with {"20221,2001"} which is Scout in the t file. Im not having any luck.

asgardschosen
Posts: 6
Joined: Mon, 2. Dec 13, 03:03
x4

Re: Ship Types Trying to add

Post by asgardschosen » Sun, 1. May 22, 07:48

I'm looking for the same thing, any luck?

DeadAirRT
Posts: 1022
Joined: Fri, 25. Jan 19, 03:26
x4

Re: Ship Types Trying to add

Post by DeadAirRT » Sun, 1. May 22, 14:01

Hard coded afaik.

Malchar
Posts: 395
Joined: Wed, 7. Apr 21, 00:56
x4

Re: Ship Types Trying to add

Post by Malchar » Sun, 1. May 22, 16:35

I had search and not find. Other modders, more skilled than me, released new ship that should had been tagged as cruiser, but they are destroyer in game. Probably if they had the possibility to change it they would had. Roughly if it has not be done it is probably because it is not possible.

SystemsEternal
Posts: 46
Joined: Sat, 13. Oct 18, 12:24
x4

Re: Ship Types Trying to add

Post by SystemsEternal » Mon, 2. May 22, 06:11

I dont know about hard coded seems a weird thing to be done that way considering there is a part of the t file that has ship types page id ="20221"

Ive tested it with bomber and destroyer both of which are in that 'ship types', id="3001" and "4001" respectively, but I gather anything that is in there should work.

Its just that adding anything into it doesn't seem to then allow it to be a ship type.
Edit: mostly because i cant find a way to tie in the macro files <ship type="enhancedscout"/> to the added <diff> <page id="20221" title="Ship Types" descr="0" voice="yes"> <t id="5071">Enhanced Scout</t> </page> </diff>
even though <ship type="destroyer" /> or <ship type="bomber" /> both work

Im not sure but Tug and Compactor werent in the file before the newest dlc so adding in new ship types seems possible

DeadAirRT
Posts: 1022
Joined: Fri, 25. Jan 19, 03:26
x4

Re: Ship Types Trying to add

Post by DeadAirRT » Mon, 2. May 22, 06:28

Yeah, it's possible if you have access to the hard coded section. A t file entry isn't the same as hard coded classes in script properties btw.

Hopefully you can prove me wrong.

SystemsEternal
Posts: 46
Joined: Sat, 13. Oct 18, 12:24
x4

Re: Ship Types Trying to add

Post by SystemsEternal » Mon, 2. May 22, 06:52

It is kinda frustrating tbh. Ive looked through as many files as i can in libaries, md, even the t files, I really cant find anything that connects <ship type="personalvehicle"/> to the entry in <page id=20221" title="Ship Types"> <t id="1001">Personal Vehicle</t>

As an interesting side note, you can have a ship type of Personal Vehicle, Distress Drone, or Laser Tower.


Ive even tried just having it look to the t file for the ship type by inputting <ship type="{20221, 1001}"/> into the macro and that comes up as a blank as well

User avatar
Lord Dakier
Posts: 3243
Joined: Fri, 8. Dec 06, 13:45
x4

Re: Ship Types Trying to add

Post by Lord Dakier » Mon, 2. May 22, 11:53

Drop a PM to one of the devs and ask the question. It was always hardcoded prior to X4 though.

siath70
Posts: 459
Joined: Sun, 11. Jan 04, 03:03
x4

Re: Ship Types Trying to add

Post by siath70 » Mon, 2. May 22, 14:32

Be nice if they allowed you to add ship types to the game, I do not understand locking something like that up.

I thought back in the X2 - X3 days people added new ship types. Like the M0 and bombers and such. I was pretty sure that there was a huge mod, X-tended, that did that. But they might have been working with EGO to do it.

Sturmer
Posts: 496
Joined: Thu, 9. Jun 11, 19:17

Re: Ship Types Trying to add

Post by Sturmer » Tue, 3. May 22, 14:44

siath70 wrote:
Mon, 2. May 22, 14:32
Like the M0 and bombers and such.
They were both vanilla classes, not added by modders. M0 was the Goner mothership and bombers were M8 class.

siath70
Posts: 459
Joined: Sun, 11. Jan 04, 03:03
x4

Re: Ship Types Trying to add

Post by siath70 » Tue, 3. May 22, 14:50

Sturmer wrote:
Tue, 3. May 22, 14:44
siath70 wrote:
Mon, 2. May 22, 14:32
Like the M0 and bombers and such.
They were both vanilla classes, not added by modders. M0 was the Goner mothership and bombers were M8 class.
Ahhh, Been a while for me. Though, locking something behind a code wall makes little sense to me, I am sure they have reasons. But allowing the community to add ship classes and such wouldn't be too horrible, I mean they could just do it in a subclass sort of way. Like a sub class of battleship called battle cruiser, where if something is missing it defaults back to the battleship classification to figure out how to handle something.

This way you could have different variations of ship classes or even drones/whatever you want, while not really messing with anything.

Sturmer
Posts: 496
Joined: Thu, 9. Jun 11, 19:17

Re: Ship Types Trying to add

Post by Sturmer » Tue, 3. May 22, 16:11

siath70 wrote:
Tue, 3. May 22, 14:50
Ahhh, Been a while for me. Though, locking something behind a code wall makes little sense to me, I am sure they have reasons. But allowing the community to add ship classes and such wouldn't be too horrible, I mean they could just do it in a subclass sort of way. Like a sub class of battleship called battle cruiser, where if something is missing it defaults back to the battleship classification to figure out how to handle something.

This way you could have different variations of ship classes or even drones/whatever you want, while not really messing with anything.
Agreed on making little sense to lock it down. Personally would love to see an overhaul bringing back the old X3 classes, I always hated the size thingy in X4, it's so bloody uninformative.

Then again, X4 doesn't have the sheer size of modding availability as X3 did like Fallout 4 was lame compared to FO3 and FNV, or Skyrim AE/SSE vs Oldrim, etc. So we'll never see as many or as massive overhauls like there were in x3.

siath70
Posts: 459
Joined: Sun, 11. Jan 04, 03:03
x4

Re: Ship Types Trying to add

Post by siath70 » Tue, 3. May 22, 17:13

Sturmer wrote:
Tue, 3. May 22, 16:11
siath70 wrote:
Tue, 3. May 22, 14:50
Ahhh, Been a while for me. Though, locking something behind a code wall makes little sense to me, I am sure they have reasons. But allowing the community to add ship classes and such wouldn't be too horrible, I mean they could just do it in a subclass sort of way. Like a sub class of battleship called battle cruiser, where if something is missing it defaults back to the battleship classification to figure out how to handle something.

This way you could have different variations of ship classes or even drones/whatever you want, while not really messing with anything.
Agreed on making little sense to lock it down. Personally would love to see an overhaul bringing back the old X3 classes, I always hated the size thingy in X4, it's so bloody uninformative.

Then again, X4 doesn't have the sheer size of modding availability as X3 did like Fallout 4 was lame compared to FO3 and FNV, or Skyrim AE/SSE vs Oldrim, etc. So we'll never see as many or as massive overhauls like there were in x3.
There is a mod, dunno if you use them, I assume yes. It's called Better target monitor

https://steamcommunity.com/sharedfiles/ ... 2042920500

It actually shows on the monitor the old naming system, like TS, M0, and such.

User avatar
Lord Dakier
Posts: 3243
Joined: Fri, 8. Dec 06, 13:45
x4

Re: Ship Types Trying to add

Post by Lord Dakier » Tue, 3. May 22, 19:27

Sturmer wrote:
Tue, 3. May 22, 16:11
siath70 wrote:
Tue, 3. May 22, 14:50
Ahhh, Been a while for me. Though, locking something behind a code wall makes little sense to me, I am sure they have reasons. But allowing the community to add ship classes and such wouldn't be too horrible, I mean they could just do it in a subclass sort of way. Like a sub class of battleship called battle cruiser, where if something is missing it defaults back to the battleship classification to figure out how to handle something.

This way you could have different variations of ship classes or even drones/whatever you want, while not really messing with anything.
Agreed on making little sense to lock it down. Personally would love to see an overhaul bringing back the old X3 classes, I always hated the size thingy in X4, it's so bloody uninformative.

Then again, X4 doesn't have the sheer size of modding availability as X3 did like Fallout 4 was lame compared to FO3 and FNV, or Skyrim AE/SSE vs Oldrim, etc. So we'll never see as many or as massive overhauls like there were in x3.
It wasn't possible to change the classes in the older games as far as I remember. The classes changed in X3TC, but that was down to Egosoft, pretty sure it's always been hardcoded.

I actually prefer the newer system, it just needs to be expanded so you have cruisers, missile frigates, etc...

asgardschosen
Posts: 6
Joined: Mon, 2. Dec 13, 03:03
x4

Re: Ship Types Trying to add

Post by asgardschosen » Wed, 4. May 22, 02:46

One area that may be worth a search is the UI files. If you take a look at defaults.xml where it defines ship_s:

Code: Select all

 <dataset class="ship_s"> 
You'll notice a property a few lines down called identification with an attribute "type":

Code: Select all

 <identification type="shiptypes_s" /> 
I had asked a question about this recently, and someone had told me that it was a UI attribute. I've recently created my own ship classes, and searched high and low for a reference to shiptypes_s, but never found one. I may have been looking in the wrong places though. I have absolutely no experience fiddling with the UI files whatsoever, and so I never searched them. It might be worth a try!

Post Reply

Return to “X4: Foundations - Scripts and Modding”