UnrealScript Source
The most convenient way to browse and search the source files is by using a dedicated class browser such as UnCodeX.
These sources are for reference only. Never attempt to compile default packages – that's not the way modding works with the Unreal engine. Instead, derive your own custom classes from the game's default classes and use an INT file to hook them into the game.
Unreal Tournament 2004
Original UnrealScript sources and .u files compiled for debugging support (obtained directly from Epic Games). From build 3323 onwards, the scripts download includes the Onslaught Bonuspack (OnslaughtBP) sources.
The UnrealScript sources also include the Onslaught C++ source code and excerpts from engine C++ code for:
- Chain of events at level startup
- Chain of events when spawning actors
- ticking Weapons and WeaponFire (UT2003)
- Pawn animations
- team beacons for players and vehicles
- Build 3369
- [UT2004 Patch 3369 Sources] (3.09 MB, download from BeyondUnreal)
- [UT2004 Patch 3369 Debug Packages] (15.77 MB, download from BeyondUnreal)
- Build 3355
- No official source files or debug packages available.
- Build 3339
- [UT2004 Patch 3339 Sources] (3.04 MB, download from BeyondUnreal)
- [UT2004 Patch 3339 Debug Packages] (15.52 MB, download from BeyondUnreal)
- Build 3323
- [UT2004 Patch 3323 Sources and Native Header Files] (3.03 MB, download from BeyondUnreal)
- [UT2004 Patch 3323 Debug Packages] (15.61 MB, download from BeyondUnreal)
- Build 3270
- [UT2004 Patch 3270 Sources] (2.9 MB, download from BeyondUnreal)
- [UT2004 Patch 3270 Debug Packages] (15.5 MB, download from BeyondUnreal)
- Build 3236
- [UT2004 Patch 3236 Sources] (2.9 MB, download from BeyondUnreal)
- [UT2004 Patch 3236 Debug Packages] (15.5 MB, download from BeyondUnreal)
- Build 3204
- [UT2004 Patch 3204 Sources] (2.91 MB, download from BeyondUnreal)
- [UT2004 Patch 3204 Debug Packages] (15.52 MB, download from BeyondUnreal)
- Build 3186
- [UT2004 Patch 3186 Sources] (2.96 MB, download from Epic Games)
- more...
- [All UT2004 Editing Downloads] (from BeyondUnreal)
Note: The debug .u files can only be used for exactly that: debugging your code. They will not allow you to connect to internet servers. Backup your original .u files before installing the debug packages to test your code and restore your original files if you want to play online games.
Unreal Tournament 2003
Original UnrealScript sources and .u files compiled for debugging support (obtained directly from Epic Games).
- Build 2225
- [UT2003 Patch 2225 Sources] (1.4 MB, download from Epic Games)
- [UT2003 Patch 2225 Debug Packages] (14.8 MB, download from Epic Games)
- Build 2199
- [UT2003 Patch 2199 Sources] (1.37 MB, download from Epic Games)
- Build 2186
- [UT2003 Patch 2186 Sources] (2.41 MB, download from Epic Games)
- [UT2003 Patch 2186 Debug Packages] (7.96 MB, download from Epic Games)
- Build 2166
- [UT2003 Patch 2166 Sources and Debug Packages] (9.6 MB, download from Epic Games)
- [UT2003 Patch 2166 Sources and Debug Packages] (9.6 MB, download from BeyondUnreal)
- Build 2136
- [UT2003 Patch 2136 Sources] (1.7 MB, download from BeyondUnreal)
- [UT2003 Patch 2136 Sources and Debug Packages] (9.6 MB, download from BeyondUnreal) – contains UDebugger update
Note: The debug .u files can only be used for exactly that: debugging your code. They will not allow you to connect to internet servers. Backup your original .u files before installing the debug packages to test your code and restore your original files if you want to play online games.
Postal 2
Original UnrealScript source code (from [Running With Scissors' web site])
- Version 1407
- WinZip Self-Extractor: [Postal 2 Version 1407 Sources] (2.8 MB, download from Running With Scissors)
Other Unreal Engine Games
The source files can be exported with UnrealEd's Actor Classes Browser (File → Export All Scripts) but they might be incomplete in the newer builds due to missing subobjects in the default properties. This is one reason for Epic to make the UT2003 sources available for download.
Note that exported sources do not contain subobjects, but this isn't a problem for older engine builds like v436, because at that time subobject definitions in default properties were not supported.
Some compiler directives (those specifically pertaining to native code) are also often lost when decompiling the built-in packages instead of downloading the sources.
Also, some Unreal Engine based games have the source code removed from the shipped packages. America's Army and XIII are two such examples. When this is the case the Unreal Script code cannot be exported.
Related Topics
- Setting Up UnrealScript – simple tutorial showing how to get started. One of a series of UnrealScript Lessons.
- Class Wikifier
- Class Tree – the full hierarchy of classes
- UnrealScript
Discussion
Also, some Unreal Engine based games have the source code removed from the shipped packages. America's Army and XIII are two such examples. When this is the case the Unreal Script code cannot be exported.
pgibbs: surely you can use UTPT to grab the source from the packages?
Foxpaw: Not only would that be extremely illegal (acually, I'm making the assumption that that is expressly forbidden in the EULA) but also I think that they tweaked the package format slightly to prevent that. If you try to load a map from America's Army into UEd, for instance, it doesn't seem to work.
pgibbs: by "source" I meant Unrealscript, not a level. I wouldn't expect taking a level from one game into another to work (unless you've got and satisifed all actor, texture, sound refereneces, etc).
Foxpaw: Ahem, well, that was just an example. Texture packages, etc. can't be loaded either - they crash with an assertion error in some file interface header - which to me strongly implies they've made a simple modification to the package format to foil any attempt to access things in the packages.
MythOpus: I remember reading something on the atari forums about someone wanting the source for the UT2k4 demo. the only reply was something like, " Well, even if we did have the source, you can't modify it yet." Whats up with that?
Foxpaw: Just speculation, but maybe the package format has changed slightly and you'll need the new version of UCC/UEd to compile scripts for UT2004.
MythOpus: Regarding the America's Army and XIII's source being stripped... why in the world would they do something like that? That's just low Trade Secrets? Response to Foxpaw, that could be, seing as now UT2k4 (for some CRAZEE reason) is not backwards compatible with UT2k3
AlphaOne: UCC is the same. All you really need is proper packages. Some mods already work with the demo. Some mod shave been written and compiled in UT2003 with the onslaught.u package in the system folder.
MythOpus: That makes sense. But wouldn't you need like all the game specific texture packages, static meshes and the like also?
Foxpaw: I can't speak for XIII, but I believe the reason they made it hard/impossible to mod for America's Army is twofold:
- There's no single player mode except the training, and you can't run your own servers, so.. yeah.
- They're paranoid about people trying to cheat. Since the US Army made it as an advertising and recruiting tool, they don't want it to get a bad image.
MythOpus: Can we not make available all the sources of the engines starting with Unreal 1?
Mychaeel: Sure we can. Does anybody have those sources?
El Muerte: I have Unreal Gold exported at my workstation
MythOpus: El Muerte can you host the Unreal Gold source or put it on Fileplanet?
El Muerte: http://unreal.elmuerte.com/Unreal-Gold-ScriptSource.zip and http://unreal.elmuerte.com/UT-436-ScriptSource.zip
Tarquin: When will sources for 3355 be available?
Wormbo: Probably never.
El Muerte: never say never. Actually, Epic hasn't even release 3355 to it's licensees yet, they are stuck at 3339
EricBlade: Anyone interested in source sets for other games? and would there be legal issues involved with that?
El Muerte: yes, there would be legal issues involved with that. You need explicit permission first.