UnrealScript
UnrealScript is the Java-style programming language used by the Unreal Engine. This is the starting point for the Unreal Wiki's reference pages.
Starting points
- For an overview of how the engine uses UnrealScript, see Unreal Engine Core. * For introductory tutorials, see UnrealScript Lessons. Features a set of simple tutorials to get you set up, and coding your first mutators.
- Stuck? See Compiler Errors, Unreal Coding FAQ and the rest of Category Troubleshooting
Core
Syntax
- Class Syntax
- Variable Syntax
- Function Syntax
- Operators
- Flow Syntax
- Special UnrealScript Keywords
- Exec Directive
- Compiler Errors
- UnrealScript Keywords – All keywords in a single list
We're also working on an EBNF UnrealScript Grammar, but bear in mind it's fairly technical.
Geometry
Objects
- Creating Actors and Objects
- Object Pool
- Destroying Objects
- Default Properties
- State
- Extending States
- Linked List
- Mutator Topics
Extending Core Functions
- Scripting Operators
- Useful Maths functions
- Useful Mutator Functions for UT
- Scripting Custom Brushbuilders
- Official UnMath Page
See also Open Source.
Engine
Classes
- Package – Very basic introduction to UT package files, and how they're assembled (.u, .utx, .umx, .uax, .unr)
- Class Tree (navigate also from Object or Actor. To jump directly, use the search function at the foot of this page)
- UnrealScript Source
How stuff works
- Taking Damage – The effects of the TakeDamage function in the Pawn class.
- Armor Damage Absorption – How a player's inventory reduces damage.
- Communication Between Objects
- PlayerController – An engine eyes view of the player.
- How UT Weapons Work
- How UT2003 Weapons Work
- Chain of Events at Level Startup
- Chain of Events when Spawning Actors
Graphics
Other Things
- Localization
- Replication – Everyone's "favorite". How to make actors work in network play.
- Obfuscation
- Config Vars And .Ini Files
- Input Key Map
- Code References
- Compiling With UCC – Compiling outside of UnrealEd. (UEd isn't the best tool for modding, anyway. )
Techniques
- Coding Guidelines – Ideas about coding style in general
- Maintaining Compatibility – What's good and what's bad when writing a certain type of mod
- Debugging Techniques – What to do to find out, what's wrong
- Optimization Techniques – How to make your UnrealScript code run fast
UnrealScript for Mappers
Pages that cover basics, aimed at mappers.
Official Reference Docs
- UnrealScript Language Reference (Tim Sweeney)
- Mod Authoring (Brandon Reinhart) (Mainly for UT only)
- [UDN's UnrealScript Reference] (Unreal Developer Network – some features don't work on builds before 600)
Scripting Utilities
- CVS (Concurrent Versions System)
- UnCodeX
- See Application for a full list
Miscellaneous
- Garbage Collection
- UnrealScript Operators and Keywords – this is marked for either deletion or rewriting as a starter tutorial
External Links
- A good read: [How To Write Unmaintainable Code]
- The [UnrealScript Yahoo Group] has over 10,000 archived messages on UnrealScript topics.
- UDN's [Unreal Tournament 2003 Coding Links] has some miscellaneous references to tutorials and fourms.
Related Topics
- Category Tutorial – automatic list of all tutorials on this site
- Testing Lab
Discussion
Wormbo: Something makes me feel this page needs to be refactored since it's the portal to all UnrealScript-related topics.
Tarquin: yes! Any ideas?
Suggestions for new pages
- overview of "begin play functions": post- and pre-. What do they do? What is the diff between the two? When to use them?
- something in the "How stuff works" section on the "chain of command": Events, Trigger, the concept of the Instigator variable that gets passed along a chain of objects.
Ideas for a page name for these two? Could "How stuff works" be called "unrealscript systems" instead?