How To Cog - Chapter 1.6 - Resources

Gob Files

Gob files are containers that hold JK's resources. Gob files contain a folder system just like Windows. You need a program to open gobs and display their folders and files. When JK is searching for resources, it will look in both the gob folders and in the equivalent Windows folders. For example, if JK is looking for example.cog in the Resource folder, it will look for it in both Resource\cog and Resource\res2.gob\cog. You can take files out of the gob file and put them in their respective folders and JK will find them just the same.

Resource Priorities

When JK is loading resources, it will look for them in several locations. When it finds a file with a matching name, it will stop there and load that file. So the order in which it searches folders is important to us.

There are four folders that JK will search for subfolders containing resources. In order of priority they are: the install folder of JK, the folder given with the path switch, the Episode folder, and then the Resource folder.

The instal folder of JK is the folder containing jk.exe. It does not normally contain resource subfolders (such as cog, mat, etc.), but if you add them, JK will look through them for every resource before going on to the path folder (if it's used). The path folder is only given to JK if the path switch is used. Just like with the install folder, JK will look for the resource subfolders in the path folder for every resource it loads before going to the Episode or Resource folders.

The Episode folder contains all of JK's level files inside of gobs. Episode is different in that the resources must be inside the gob file or JK will not see them. JK does not search Episode for all resources - only the ones loaded by the level's jkl. And if the level's jkl lists a resource that is not in the level's gob file, then JK will go to the Resource folder.

Resource is the fourth place JK checks for resources listed in the level's jkl (including the jkl if it's not in Episode), but the third place for resources listed in the items.dat and static.jkl - because JK doesn't check the level gob.

In the install folder, the path folder, and in Resource, you can use gob files as well as actual Windows folders. JK will search the Windows folders before searching the gob files. So if you have a cog\weap_bryar.cog and a test.gob\cog\weap_bryar.cog both in JK's install folder, JK will choose the one outside the gob.


The Jedi Knight CD has a file called which is in the gamedata\resource directory. By copying that file from the CD to your own Resource folder on the hard drive, you can run JK without using a CD. You must have a complete installation for this to work. And if you want the movies as well, you can copy the video folder to your hard drive and JK will play them.

JED (a .jkl editing program) will ask you for a CD to make sure you really have JK, but all it wants is the first two smacker cutscenes - 01-02A.smk and 03-04A.smk. To fix that, create a gamedata\resource\video\ directory on one of your drives, put those two movies in it, and tell JED that's your CD drive. You can also use a mapped drive if you want. Another thing about the movies is that the first one gets really aggravating after a while - it's the opening cutscene. To skip that, just delete 01-02A.smk or rename it.


The real Jedi Knight program is jk.exe, you should never use the launcher. Just to save time, you may want to hide everything inside your JK install dir except for jk.exe, resource, and episode - you'll rarely have to use any of the other files.

CMD Switches

JK.exe accepts special program commands called switches. Create a shortcut to JK.exe and view its properties. In the Shortcut tab, you'll see a box called "target". This is the command that Windows will run when you click the shortcut (picture a command prompt). After the original command that the shortcut has, you can add special commands for JK. The most important one for editing is the path command. To use it, write "-path folder" with no quotes after the shortcut command. This will make JK look for resources inside a folder named "folder" before it searches the other resource directories. This is how you can make JK load patches.

Previous: Inventory Up: How To Cog Next: Review
  • Create:
This page was last modified 19:02, 5 June 2006.   This page has been accessed 2,324 times.