Creating Your Own WCSO EXE File

Jason_Ryock

Vice Admiral
(Just a note, this post isn't really for anyone, I'm just recording the steps I took to get somewhere in case anyone ever wants it.)

Okay, since there is a distinct lack of tutorials on the matter, I'm going to walk through the steps I've taken in the last few days to get a WCSO EXE file to load the high res patch, my own tre file, and my own series file stored within the TRE file.

For those who don't know:
TRE files - store all the files for the Secret Ops game
SRS Files - (Series File) contains the mission tree and mission variables for the game.

You're going to need two basic programs, which I can't provide you with download links for but you should be able to find fairly simply:
A Visual C++ Compiler (Microsoft usually has one version or another in free development that you can grab)
An EXE Hex Editor

You're also going to need two non-standard progams:
treman - downloadable here:
http://hcl.wcrevival.de/archive/treman1.zip
tremaker - downloadable here:
http://hcl.wcrevival.de/archive/tremake.zip

You'll also need to download these two packs:
http://hcl.wcrevival.de/2001/wcsohr_v3.zip
http://hcl.wcrevival.de/exe_dll/wcsohr_v3_source.zip

1) Start by installing all the programs we just downloaded, and the Secret Ops (It's best to start with a CLEAN install for this).

2) Install the Secret Ops high-res pack we downloaded in the last step above.

3) Extract both treman and tremake to the Secret Ops root directory.

4) Unpack the mission.tre file with the TREMAN program. (Steps for this process can be found here: http://www.crius.net/zone/showpost.php?p=340181&postcount=12)

5) When all that is ready to go, create a new folder with the contects of the wcsohr_V3.zip files inside it. Call this folder "CS MOD".

6) Copy the TREMAN and TREMAKE files into it.

7) Create a directory, we'll call ours "csmiss". Inside the csmiss directory, create a folder called "mission".

8) Copy the covert.srs file from the Secret Ops\Mission directory into this new mission directory we created, and rename it to "cssers".

9) Open a dos window, and create a tre file called "csmiss.tre" (Steps for this process can be found here:
http://www.crius.net/zone/showpost.php?p=346606&postcount=18)

10)Now comes the tricky part. You need to unpack the WCSOHR source files, and open up the project in your C++ Compiler.

11) Skip down to line 234 and add this line: LoadTre("csmiss.tre", 2);

12) Skip down to line 239 and add this line: bool menu = false;

(You may also need to remove line 281 that says something about a "MessageBox" if the file does not compile without errors.)

13) Build and compile the project. You WILL have warnings, as long as their are no errors, there will be no problems with the file.

14) Navigate to the source code directory, and open the Debug folder. There will be a file in there called wcsohr.dll, copy this file.

15) Navigate to the "CS MOD" folder and paste the DLL file here.

16) Locate and delete the highres.dll file in this directory.

17) Rename wcsohr.dll to highres.dll (bet you didn't see that coming).

18) Close everything you have open, and open the HEX Editing program you download above.

19) Open the "secretops.exe" file in your "CS MOD" directory in the HEX Editor.

20) Search for the line "covert" and change the line "covert" to say "cssers"

21) Save the file, and then copy the entire contents of the "CS MOD" directory into the root Secret Ops folder.

22) Execute, and hope it works!

Adding more TRE files is as simple as going back to step 11 and adding in any other TRE Files you might wish to add.

This will also ensure that your mod runs the High Res patch for WCSO.
 

Jason_Ryock

Vice Admiral
Just some more notes on EXE Editing (Most of which can already be found here: http://killerwave.solsector.net/EXE_Editing.html)

To change the folders and files so they do not conflict with WCSO/WCP or any other mod:

1) Open up the EXE you edited in the last tutorial with your preferred HEX Editor.

2) Run a quick search for "replay", this should reorient your position to the right place in the EXE File.

3) There are several things you want to edit here, but a warning first. Do not make anything shorter or longer then it already is in the file. Your filename and folders need to be of exactly the same number of characters as already exist in the EXE file.

So here's a guide:
history\ - 7 Characters
replay - 6 Characters
save\ - 4 characters
autosave\ - 8 characters

If you're following my above tutorial, this is what you want to change them to:

history -> csstory
replay -> csplay
save -> cssv
autosave -> cssavegm

4) Run the EXE in the "CS MOD" directory, and check to make sure that it created the proper files and folders.

5) Copy the new EXE from the "CS MOD" folder into the WCSO directory, and you're good to go!
 
Top