Modding Star Wars Clone Wars

Modding Star Wars Clone Wars

As I am writing, this is just a work in progress. The aim is to change the game, so that the multiplayer mode becomes the coolest Star Wars multiplayer game on Earth. If you played this game as much as I did, you probably dragged your friends playing the “conquest mode”, which happens to be OK. Now, how cool this mode would be if the unit produced were droids, clones, or six feet walkers ?

I am just trying to keep my notes clean, as I explore the files of the game. It actually seems that a lot of files do are not supposed to be on the game disc. But it is a good thing that they are here, they will probably save us a lot of time.

The files on the disc

Extension Number of files Purpose
.AIM (30) UNKOWN
.BAT (2) Windows command file
.BMF (1) UNKOWN
.CIN (32) Readable text / (?) in game movie
.PTH (33) UNKOWN (?) … contains some strings …
.SKY (1) UNKOWN
.WAV (3) Sound file (VLC)
.act (1) UNKOWN
.adp (42) Music (?)
.ani (6) UNKOWN
.bat (4) Windows command file
.bik (45) Bink video file
.bin (35) UNKOWN
.bmf (6) UNKOWN
.bnr (1) GC Banner, common to GC Games
.cfg (74) Readable text / Game parameters.
.col (447) UNKOWN
.ddf (1) Readable text / Disc Info
.def (2) Readable text / particle engine related (?)
.dlf (1) Readable text / list of the files of the disc (and adresses)
.dol (1) GC SYS file
.dsf (1) UNKOWN
.elf (1) UNKOWN
.fff (4) UNKOWN (most of them seem to be loaded at boot)
.gcm (1159) UNKOWN
.gct (1249) Texture and / or video
.gxw (33) UNKOWN (?) … contains some strings and refers to tga files …
.img (1) GC SYS file
.inc (1) Readable text / automatically generated, sound related
.ini (2) Readable text / Engine parameters
.odf (1034) Readable text / Character parameters.
.prp (13) Readable text / Planet parameters
.pse (188) Readable text / explosion, laser, particle parameters.
.sky (39) Readable text / Sky parameters (3*13 = 39 …)
.spd (1) UNKOWN
.spt (1) UNKOWN
.ssc (4) Readable text / various roles (sound, script…)
.stb (1) UNKOWN
.tpl (2) Common GC file. banner.tpl can be opened with TPLEditor, icon.tpl won’t open.
.wav (957) Sound file (VLC)
.wld (34) Readable text / world parameters
e.pl (1) UNKOWN

This is more or less everything I gathered so far. I used various tools to navigate through the files and their purposes. As I could not decompress the ISO and recompress it (well, I could perform these two steps, but the game would not go beyond the title screens). I started using the following script.

import sys

host_filepath = sys.argv[1]
payload_filepath = sys.argv[2]

input_filepath = sys.argv[3]
output_filepath = sys.argv[4]

print("Trying to replace [" + host_filepath + "] with [" + payload_filepath + " in [" + input_filepath + "]")

host = open(host_filepath, 'rb').read()
payload = open(payload_filepath, 'rb').read()

if(host==payload):
    print("WARNING : the host and the payload are identical!")

input_file  = open(input_filepath, 'rb')
output_file = open(output_filepath, 'wb')

piece = input_file.read()  
if host in piece:
    piece = piece.replace(host, payload)
    print("Success!")

output_file.write(piece)
        
output_file.close()
input_file.close()

It just looks for a sequence of bytes and replaces it with another. Therefore, with an extracted version of the ISO, I can look for two files and overwrite one with the other. I could per example notice that the .gct files are images or sequence of images (I just replaced the icon of the tank assault with other 22k files). If you know the game, the icon on the bottom left should puzzle you. It is probably the foot of a six leg walker :)

Needed

For the other files, well, it depends. It turns out that a lot of files are just text files! But it seems that they are not used by the games (trying to change the values and injecting them in the ISO did not produce any result). Some people think that they shipped a debug version of game (accidentaly). It makes sense, some folders are actually called UnitTest!

My first guess is that, while most of these files are not called by the game (Dolphin File IO showed that some of these files are actually opened), they are compiled somewhere in the same disc, under another format. The fact that they let us know float / integer values may be useful later on.<p>

Multiplayer maps.

While I was trying to load some elements of a level to another level, I noted that the order of the maps in the game is not the order of the maps on the disc. Per example, the first map (Kashyyk Duel) actually refers to multi4. The following table summarizes the mapping.

Planet Type Number
Kashyyyk Duel 4
Rhen Var Duel 3
Geonosis Duel 1
Thule Duel 15
Raxus Duel 2
Thule Control zone 14
Raxus Control zone 13
Thule Moon Control zone 9
Geonosis Conquest 8
Kashyyk Conquest 12
Thule Moon Conquest 10
Rhen Var Conquest 6
Thule Moon Academy 5
Geonosis Academy 17

Yes, 7 and 11 are not present. There are no movies corresponding or maps where they should be.

GamecubeKid

GamecubeKid
Passionate about Gamecube, coding, statistics, beta games...

Modding Star Wars Clone Wars

A work in progress about the files on the disc, part 2 Continue reading

The lost Dekoboko track

Published on January 05, 2018

Compiling tgctogcm.c on Linux

Published on December 28, 2017