TransCompiler Usage

This is a moderated forum that collects tutorials, guides, and references for creating Transcendence extensions and scripts.
Post Reply
User avatar
AssumedPseudonym
Militia Captain
Militia Captain
Posts: 961
Joined: Thu Aug 29, 2013 5:18 am
Location: On the other side of the screen.

Fri Sep 22, 2017 3:43 pm

 Multiverse is now an option for uploading mods, but there’s a catch: They have to be in TDB format. Fortunately, there’s a utility provided by George to create TDB files, called TransCompiler, which is included with the TransData utility. The ZIP archive for TransData can be found here. Once you have that, you’ve got what you need to make a TDB version of your mod.

 TransCompiler can be a bit of a finicky beast, much like Transcendence itself. The setup is the hardest part, but fortunately it only needs done once.

 Obviously, you’ll need to unzip the TransData.zip archive, but my suggestion is to not unzip the archive into the Transcendence folder. I’ll get into why momentarily. Unzip it into Downloads, Documents, your home folder, or somewhere like that; I recommend just using your home folder, and it’s what I’ll be using for this tutorial. It should decompress into a folder named TransData containing TransData.exe, TransCompiler.exe, and a README file. The next thing you should do is copy the Transcendence.tdb file from the Transcendence folder into the TransData folder. (I’ve had weird results with having multiple copies of Transcendence.tdb in the Transcendence folder, even when tucked into subfolders, which is why I suggested keeping the TransData folder elsewhere.) With that done, you’ve got the basic setup done.

 When you’re ready to make your mod into a Multiverse-ready TDB file, copy it and any files it needs into the TransData folder. This includes graphics, sounds, XML files, and the like. If any of the files used by the mod are in a folder, copy the folder over. Basically, you want to put a copy of the mod into the TransData folder in the same configuration as it would be in the Extensions folder.

 Open a command prompt window and type the following:

Code: Select all

cd Transdata
 You should see something like this:

Code: Select all

C:\Users\YOURNAME\TransData>_
 To create the TDB file, type:

Code: Select all

TransCompiler.exe /input:ModFilename.xml /output:ModFilename.tdb
 Everything should compile and give you a TDB version of your mod.
Troubleshooting

Code: Select all

error: Unable to open 'Transcendence.tdb': Unable to open file: Transcendence.tdb..
 This means you either did not make a copy of Transcendence.tdb in the TransData folder or you did not cd to the TransData folder before trying to run TransCompiler.

Code: Select all

ModFile.xml
   Graphic1.jpg
   Graphic1Mask.bmp
error : Unable to open 'Graphic2.jpg'.
   Sound1.wav

C:\Users\YOURNAME\TransData\ModFile.tdb - 1 error
 This means that a file used by your mod did not get copied into the TransData folder with the rest of your mod, or that it was not where TransCompiler expected it to be (possibly because it was in a different folder inside the Extensions folder). The TDB file compiled without it, but it will cause an error trying to use the mod in the game.

Code: Select all

error : Line(56): Invalid entity: unidName
 This will happen if your mod uses UNIDs not defined either in Transcendence.tdb or your mod. It means there’s either a typo in the mod or the mod relies on a UNID defined elsewhere (which, to be fair, I didn’t cover earlier). Try adding a copy of the file that defines those UNIDs to the TransData folder and adding “/entities:OtherFileName.xml” or “/entities:OtherFileName.tdb” to the TransCompiler command.
Image

My mods on Xelerus: Click here!

Of all the things I’ve lost in life, I miss my mind the least. (I’m having a lot more fun without it!)

relanat
Militia Commander
Militia Commander
Posts: 438
Joined: Tue Nov 05, 2013 9:56 am

Wed Sep 27, 2017 1:23 am

Thank you.

relanat
Militia Commander
Militia Commander
Posts: 438
Joined: Tue Nov 05, 2013 9:56 am

Wed Oct 18, 2017 1:21 am

Does it matter which version of Transcompiler.exe you use?

I tried the 1.7 and the 1.8a2 Transdata version and both worked on a mod for Version 1.7. Does Transcompiler.exe change over time like Transdata.exe or is it the same for every version? The file size varies.

User avatar
AssumedPseudonym
Militia Captain
Militia Captain
Posts: 961
Joined: Thu Aug 29, 2013 5:18 am
Location: On the other side of the screen.

Wed Oct 18, 2017 1:37 am

 I’ve wondered about that, myself, but never tried testing it. Just to be safe, I’d advise using whichever version of TransCompiler comes with the most recent version of TransData.
Image

My mods on Xelerus: Click here!

Of all the things I’ve lost in life, I miss my mind the least. (I’m having a lot more fun without it!)

shanejfilomena
Fleet Officer
Fleet Officer
Posts: 1406
Joined: Tue Mar 22, 2011 8:43 pm
Location: Alaska

Fri Oct 20, 2017 9:02 pm

i have tried this, my computer will not co-operate.
&& for such things as Living Minutes, there are multiple .xml involved.

We have a .bat file code that decompiles .tdb

Is there a way to have one that can compile?
Flying Irresponsibly In Eridani......

I don't like to kill pirates in cold blood ..I do it.. but I don't like it..

Post Reply