Here I will show you how to set up the project folder for your new package. I will be extending the Mutator class in this example, as if we was creating a new mutator.
We need to create a new folder in the UT2004 base directory, this is your new project folder. The name of this folder will be the name of the package (.u file). So in this example I will simply call it “MyMutator”.
Within that folder create a new folder called “Classes”. This is where we need to put all of our custom classes (.uc files) that we want to compile. And within this folder lets add our first .uc file. Create a new .uc file by right clicking>New>Text Document.
Rename the extension to .uc. Lets name the file “MyFirstMutator”. You new file should look like this when created.
Next lets just add a little code to the .uc file to make it compile for the next step. Open the MyFirstMutator.uc file in your faveourite text editing program such as TextPad and at the top declare your new class. We are making a new mutator so extends the Mutator class. Add the following code to the top of the file.
Class MyFirstMutator extends Mutator;
The package will now compile but first we need to tell unreal to include our package in the list of things to edit when it compiles. We do this by opening the UT2004.ini file which is located in your UT2004\System folder. With this file open, scroll down to the heading [Editor.EditorEngine] and add EditPackages=MyMutator to the bottom of the list.
To run the compiler you can open a new command window and navigate to your UT2004\System folder and then type “ucc make” without the quotations. To go down a directory type “cd..” without the quotations. To go up a directory type “cd NameofFolder” without the quotations. To change directories type “DriveLetter:” without the quotations. For example to change to your C: drive simply type “C:” without the quotations. If you have done this correctly you should see something like this.
Or you can download this one-click program that will do all that for you from here. UCC Compiler. To set up the Ucc Compiler open the program and set the directory to your UT2004\System folder. Compile by hitting the Compile File/Run Default Ucc Make button. For a more in depth explanation follow this short guide Simple Ucc Compiling Guide.
Remember that in order to compile new versions of your package, the old version must first be deleted from the UT2004/System folder.
TIP – Class names should never start with a number.
Recent Comments