Welcome to the guide to Jedi Knight II editing. This guide is a work in progress by anyone who has the relevant knowledge, so if you know something that is not here email me at email@example.com.
The guide currently has the following sections:
I. Guide to starting your editing journey, base structure.
II. Console Commands
Section 1: Guide to starting editing and base structure.
Welcome to the world of Jedi Knight II editing. The first two steps towards your journey into editing are:
Step 1: Unpacking your game files.
On your Jedi Knight II CD there should be the following files and folders:
Folders: Bin; DirectX; Gamedata; install.
Files: autorun.exe; autorun.inf; autorun.ini ; detect.exe.
Don’t worry about ANY of these folders or files except for “Gamedata”. This folder has the two essential game files hidden in it, assets0.pk3 and assets1.pk3. If your CD drive is called D:/, then your path to these files will be D:\GameData\GameData\base.
These two files are pk3 files – basically, a Winzip file. I suggest you change your settings on your computer to run this filetype with Winzip – shift-right-click on assets0.pk3 and select “Open with”. The select winzip from the list.
The pk3 files are very large – several thousand files in each, giving a total of 593MB when zipped up – an incredible 1.6GB when unzipped. Make sure you have enough hard disk space before proceeding. OK – you are ready to unzip your pk3 files!
You need to unzip your pk3 files to (assuming your hard-disk is C:/ and you installed JKII in the default directory) C:\Program Files\Lucasarts\Star Wars JK II Jedi Outcast\GameData\base. This will take a long time, so go and make a cup of tea and come back.
OK, they’re all unzipped. Now we go and take a look at the file types. Here I have looked at the various file types, what they mean, and how you should open each one. The files are listed in order of the folder that they are in inside the base directory:
C:\Program Files\Lucasarts\Star Wars JK II Jedi Outcast\GameData\base\botfiles:
Bots.txt – open with notepad. This file lists all the bots that can be added in multiplayer. To add another bot of your own, add the following lines (the red text below) somewhere in the middle of the file, eg.
// Dark Side bots
// Currently, all DS bots carry red lightsabers
// Desann is attached to Tavion
name “Your bot’s name”
model the model you want (can be a custom skin)
color1 saber color – 0 = red, 4 = blue, I haven’t played with these but I think the numbers in between are green, yellow and purple
personality /botfiles/your choice of personality.jkb
//Tavion is attached to Desann
These are bot personality files and should be opened with notepad or any other text editor. Basically, this file can determine reaction speeds, accuracy, force use and basically any other attributes you can think of for a bot personality – the instructions are all in the existing files themselves so if you’re creating new ones take a look at the existing ones first. You can also add any number of custom sayings to the bottom of this list – again, look at the existing ones for ideas. HOWEVER – there is a limit to file size but I think its fairly large.
C:\Program Files\Lucasarts\Star Wars JK II Jedi Outcast\GameData\base\botroutes:
.wnt Bot route files:
These files (.wnt) are basically co-ordinates for the route that a bot takes. At this time I have no information as to how these files work, but if they are opened in notepad they can be read as a series of co-ordinate points.
C:\Program Files\Lucasarts\Star Wars JK II Jedi Outcast\GameData\base\cfg:
This folder has all the executable config files in it. These files contain a list of console commands – when the file is executed, all the commands in the file are executed. This can be very useful if more than one person is using the game – you can bind your controls instead of theirs just by executing one config file. My favourite single-player config for a bit of fun is:
To execute a config file, just type exec your-file-name (without the config extension) in the console.
C:\Program Files\Lucasarts\Star Wars JK II Jedi Outcast\GameData\base\demos:
The folder where demo videos recorded ingame are kept by JK2. More about demos later, for now, just leave this folder alone.
C:\Program Files\Lucasarts\Star Wars JK II Jedi Outcast\GameData\base\eagle:
These appear to be scripts for the maps. I do not know how to make sense of these files.
C:\Program Files\Lucasarts\Star Wars JK II Jedi Outcast\GameData\base\effects:
This folder has all the commands for the effects in JK2 in it. It is split into folders associated with effects for each weapon, force power effects and map effects, with other random effects just loose in the main folder. I don’t know how to write this script, as the language seems to be very specific for the game. However, if you want to view the script and maybe play around with some values, you can open the files legibly in Notepad.
NOTE: I would highly recommend that you backup any successful changes – it would be very easy to mess up effects and ruin the game.
C:\Program Files\Lucasarts\Star Wars JK II Jedi Outcast\GameData\base\ext_data:
Dms.dat – Dynamic Music System file, to be opened in Notepad. This file basically lists all the music that goes with the maps – for each map there is an “Explore” set of music and an “Action” set.
All maps have a series of music files, mp3s, that are played when the player is either in “action” or “explore” mode. The example given is the first music series in the list, the “explore” for one of the first levels, kejim_base.
This music configuration is known as kejimbase_explore. Existing music configurations are:
These are the different configurations that Raven have made to work together well. It is relatively easy to add any of these configurations to your single player level: The levelmusic section at the end of the dms.dat file tells the game what music to play with what level:
Basically, the “explore” string tells the game what configuration to use for exploring music, and the “action” string tells it what configuration to use for action music. (Well, obviously.) I’m not entirely sure how the game uses boss music – presumably, whenever there are certain NPCs to face, this music plays. There is also a shorthand for you to use if you ever make dozens of singleplayer levels (!) – instead of using the “explore”, “action” and “boss” strings you can just use a simple “uses” string, followed by the map name that you want to use the configurations from.
***There is also a way of adding in new music of your own – however, it will take AGES. Take another look at the sample of a music configuration:
I’m going to explain how the mp3 filing system works now: all dynamic music is found in the C:\Program Files\Lucasarts\Star Wars JK II Jedi Outcast\GameData\base\music directory. There is a folder for each map (eg. Kejim_post), as well as several “loose” mp3s that are used throughout the game, eg. Death_music.mp3. If you take a look inside one of these folders, you will find that each one has the same number of files in it:
These files (with **** replaced by the configuration name) are basically the short and long action and explore music for each configuration. ****_action.mp3 and ****_explore are the long action and explore tracks, ****_atr0*.mp3 is the short action track and ****_etr0* is the short explore track.
OK. Back to that dms.dat.
I am going to explain what bit does what in the sample given, and you can base your experiments from that.
kejimbase_explore - title for this configuration. In the game it is always name_explore and name_action.
marker0 0.000 - marker (in seconds) for where it is valid to start playing the explore track. To clarify this, here is an example. You’re in the middle of a firefight with stormtroopers. They all get killed. Basically, the game will start the explore track at 0.000 seconds or 22.070 seconds, or 53.723 seconds, or 90.926 seconds.
nextfile kejimbase_etr00 - this is the transition between the long explore track and the shorter ones – this particular one is between kejimbase_explore.mp3 and kejimbase_etr00.mp3. The times mentioned are the times in seconds through kejimbase_explore.mp3 the game will choose to change tracks to kejimbase_etr00.mp3. I believe this is also the time when the action tracks would kick in if you saw some stormies.
As you can see, making new configurations is challenging. After the explore one is made, you would have to make an action one too… Having said all that, it seems the Raven developers have got round the tedious process of doing all this by the use of “markers” – I’m not quite sure how these work.
Items.dat – this file, unsurprisingly, deals with the items in the game. If you open it in Notepad, it gives instructions as to what changes what. This file basically has all the pick-ups you can get, as well as a few interesting bits such as TIE fighter…. (?)
Npcs.cfg – open in notepad. This file deals with the npcs including Alex Munro from Star Trek Elite Force…. The instructions are all given in the file once again. However, I haven’t been able to make any new NPCs work correctly, so have a play, even if you just change some stats of the existing NPCs.
Weapons.dat – open in notepad. This is probably the most edited file there is – it is basically a listing of all the weapons and their characteristics. Instructions are given in the file as to what means what, but here you can edit most things about the weapons and ammo counts.
C:\Program Files\Lucasarts\Star Wars JK II Jedi Outcast\GameData\base\fonts:
Basically, the fonts used in the game. I haven’t been able to view these never mind edit them … yet.
C:\Program Files\Lucasarts\Star Wars JK II Jedi Outcast\GameData\base\forcecfg:
These are the multiplayer force powers presets – both dark and light – in files with extensions .fcf. If you open them in notepad, you will see a line that looks something like this:
These refer to force powers. Here is a translation of what those numbers actually mean (this works for bot configs too):
Rank – not sure what this really is, but every single one is 7. Can’t explain it but I suggest you follow it.
Side – 1 or 2.
All others – the force powers you can select in multiplayer.
C:\Program Files\Lucasarts\Star Wars JK II Jedi Outcast\GameData\base\gfx:
These are the graphical effects seen in the game, ie. the pictures and animated pictures.
There are many different folders, with dozens of files in – I am not going into great depth but I will write something about each folder:
2D: The 2D art you get for example, when you are in droid view, or another example would be the HUD.
Chunks: The pieces of grate after you’ve sobered it.
Colors: contains black.jpg, for some reason.
Damage: assorted burn marks.
Effects: basically every weapon’s “bullet” explosions, forcefields, saber effects.
Exp: well, explosions. The remainder of the explosions caused by weapons eg the rocket.
Hud: the bits you get in your HUD, for example all the weapons and force power icons. Also, the health and ammo readout bars are here.
Interface: don’t really know.
Menus: all the graphics from the menus (both the multiplayer and singleplayer ones).
Misc: random things including force lightning (in case you want it the right color), chunks of glass etc and more explosions.
Mp: anything they added to the HUD as an afterthought for multiplayer, also a few bits and bobs.
Sfx: the disrupter death graphic – warning, it does not look the same as in game.
Sprites: the ferns on Yavin and the crystal rocks from the tunnels in the mine.
World: fog and rain.
C:\Program Files\Lucasarts\Star Wars JK II Jedi Outcast\GameData\base\levelshots:
The pictures you see as each level loads sorta behind the loading texts. Just call your picture the same as you map, ie. ffa_mymap.jpg and it will show up when the map is loading.
C:\Program Files\Lucasarts\Star Wars JK II Jedi Outcast\GameData\base\maps:
The maps (levels) used in the game. This is not a mapping tutorial, so enough said.
C:\Program Files\Lucasarts\Star Wars JK II Jedi Outcast\GameData\base\menu:
Three folders: “art”, “new” and “video”. “Art” holds the lightsaber coloured pictures for multiplayer, the other two folders appear to hold nothing new that isn’t already in the gfx folder.
C:\Program Files\Lucasarts\Star Wars JK II Jedi Outcast\GameData\base\models:
Big, big folder – 160MB. This has folder structure:
Chunks: holds the models for the pieces you see come off such surfaces as metal, as well as pieces of eg crate that remain after you break them up.
Flags: the flags in multiplayer – including the ysalamari.
Items: time for a brief skins tutorial.
I am not going to go into how to skin models, merely how they work. Basically, the humanoid models are in the ghoul format, which means that the model is made up of lots of meshes each with an individual name. Then, a .skin file is made that can determine which texture goes on which mesh, for example:
This enables people to skin a model merely by changing the textures and not having to alter the model at all.
Items are done in a similar way; however with items an .md3 files rather than a.glm file is used as a model. .md3 files are easier to make, and even easier to skin – each .md3 model has a .jpg file with the same name that is its skin. Therefore, to change the look of any item you can just change the jpg file.
It is also possible to change the model file if you have an editor that can open md3 models, eg. Milkshape 3D.
Map objects: Basically the same as items – a model and a skin for each object. In this folder can be found all the objects find in maps but NOT the textures or moving enemies.
Players: This folder is split into several folders, one for each model. Each one of these folders contains a file called model.glm - these are NOT all the same! Then there are numerous .jpg files for the textures, and three files called model_default.skin, model_blue.skin and model_red.skin. These files can be opened in Notepad.
If you look at model_default.skin in notepad it will look similar to this:
This basically tells the game to look at the model.glm file and find the mesh called hips. It will then put onto this mesh the texture models/players/bespin_cop/legs.tga. For some reason, all the .skin files talk about tga files – whereas all the texture files are .jpgs. It seems to work with both file types (however, jpgs must NOT be very compressed else the game will crash).
To make a skin:
Weaphits: the explosion model for the weapons hitting things.
Weapons: the models and textures for the weapons – similar to items and map objects.
C:\Program Files\Lucasarts\Star Wars JK II Jedi Outcast\GameData\base\saves:
Fairly obvious, I think….
C:\Program Files\Lucasarts\Star Wars JK II Jedi Outcast\GameData\base\scripts:
This is the directory where most of the scripts for the maps are placed. If you ever used JED, these are basically your cogs.
Each folder is named after the map it refers to. I believe that BehavEd (the Elite Force scripting tool) can be used to some extent to make scripts for your maps, but I couldn’t download it anywhere and I don’t know how to use, so I can’t help you there.
C:\Program Files\Lucasarts\Star Wars JK II Jedi Outcast\GameData\base\shaders; C:\Program Files\Lucasarts\Star Wars JK II Jedi Outcast\GameData\base\textures:
The two directories with the shaders and textures in for use with the mapping tools. A shader is basically the properties of a surface – whether it is water, metal, breakable, whatever. A texture is the actual picture that appears on a surface. Shaders ARE editable, however I have not tried this yet. Textures are a simple matter of creating a .jpg picture with the texture you want, however these must be have a size in multiples of 128 ie 256 x 256, 1024 x 1024, 512 x 1024.
C:\Program Files\Lucasarts\Star Wars JK II Jedi Outcast\GameData\base\sound:
Again, a multitude of folders:
Ambience: All the ambient sounds used in the game, in WAV format.
Chars: the sounds for all the characters, in mp3 format.
Explanation of filenames:
The chars folder is divided into more folders by character name, eg. shadowtrooper etc. Basically, any .mp3s loose in the character folder is a sentence said in a cutscene, such as “Please, noble Jedis! Not in the faces!”
As well as this, there is also a misc folder that contains all the sounds required in multiplayer and for enemies in SP:
pain100.mp3 - the “pain” noise when a character is between 0% and 25% health.
Pain75.mp3 - the “pain” noise when a character is between 25% and 50% health.
Pain50.mp3 - the “pain” noise when a character is between 50% and 75% health.
Pain25.mp3 - the “pain” noise when a character is between 75% and 100% health.
Death1,2,3.mp3 - the death sound.
Falling.mp3 - the falling sound (like Kyle going down a huge pit)
Gasp.mp3 - the sound coming out of being force gripped
Choke1,2,3.mp3 - the sound while being choked
Drown.mp3 - the sound when drowning
Pushed1,2,3.mp3 - the sound made when force-pushed successfully
Pushfail.mp3 - (jedi only) forcepush fails (“you dare to push me?”)
Taunt.mp3/taunt1,2,3.mp3 - taunting
Victory1,2,3.mp3 - victory taunt
Confuse1,2,3.mp3 - when an enemy is confused
Deflcted1,2,3.mp3 - (jedi only) when they deflect stuff (esp. blaster bolts)
Gloat1,2,3.mp3 - when they are doing well
Jchase1,2,3.mp3 – (jedi only) when you are running away
Jdetected1,2,3.mp3 – (jedi only) when you are detected
There are dozens more possible sounds, but these are the basics, especially for adding new Jedi characters. Basically, if you want to add a complete set of new sounds then check the Stormtrooper and reborn folders (st1, st2, st3, reborn 1, reborn2, reborn3) and play the sounds you think may be relevant. (Important note – some player will not play the mp3s that come in the game. I can recommend WinAmp since this does).
Char_d/Char_f – the same as char, but in German and French... Listen to these, its pretty cool.
Effects – all those, well, effects that you get during the game.
Interface – the sounds you get when eg, you enter a secret area or pick up a battery or charge up your shields.
Items – sound for multiplayer respawn and bacta use.
Movers – sounds of doors and effects.
Player – all the footsteps, health pickups, etc.
Weapons – all the force powers and weapons sounds.
C:\Program Files\Lucasarts\Star Wars JK II Jedi Outcast\GameData\base\strip:
The files that make up the subtitles for the cutscenes in English, French and German. Not essential for a level, but pretty stylish to have all the same.
C:\Program Files\Lucasarts\Star Wars JK II Jedi Outcast\GameData\base\ui:
This folder contains all the menu systems in JK2. The .menu files (open in notepad) are similar to many other files in JK2 and seem to be similar to a C script in their structure and syntax. The .txt files decide what menus to load in game.
By looking at the various commands that existing menu systems do and the attributes that they have, it should be possible to look into how the system works. So far I have not had the time or inclination to look at these but you never know, someone might.
C:\Program Files\Lucasarts\Star Wars JK II Jedi Outcast\GameData\base\video:
This folder contains all the .roq files which are basically JK2’s FMV cutscenes and any ingame and in-menu animations, I believe. There is a file with the JK2 editing tools that tells you how to do roq files – however, it implies that there are tools yet to be released that will deal with these.
Basically, the best way of preparing your video files for .roq format is to make a .smk format video with dimensions in multiples of 128 x 128. (128 x 256, 515 x 512 etc.) These can then be converted into the required format for .roq files on release of the .roq tools.
If you want to get Rad Tools, in order to make your .smk format file, you can find it as a free download at www.radgametools.net.
C:\Program Files\Lucasarts\Star Wars JK II Jedi Outcast\GameData\base\vm:
Frankly, your guess is as good as mine with this folder.
If you have ANY additions, tutorials or confirmed corrections that you wish to make to this document please email me at firstname.lastname@example.org and I will add your writings ASAP.