All strings in save files are null-terminated UTF-8.
Data Types
Array32
Variable-length array with 32-bit metadata:Number of elements in the array
Size of each element in bytes. A value of 0 indicates varying size (e.g., for strings)
Raw array data
String Table
Localized string container:Language code (e.g., “en-GB”, “de-DE”)
Translated string value
File Structure
Header
The file begins with a header containing metadata:Magic number identifying the file format
Target version of OpenRCT2 for this save file
Minimum OpenRCT2 version required to load this file
Number of data chunks in the file
Total size of uncompressed data
Compression algorithm used (0 = none, 1 = gzip, etc.)
SHA-1 hash of the uncompressed data for integrity verification
Chunk Index
Following the header is an index of all chunks:Chunk type identifier
Byte offset from start of file to chunk data
Length of chunk data in bytes
Chunk Types
Authoring
Metadata about who created the save file:Engine version string (e.g., “openrct2 v0.1.2 (Linux)”)
List of author names
Custom notes or description
When the park was first created
When the save was last modified
Objects
List of custom objects used in the park:Object type (ride, scenery, etc.)
Unique object identifier
Object version string
Scenario
Scenario information and objectives:Scenario category (beginner, challenging, expert, etc.)
Localized scenario name
Localized park name
Localized scenario description
Type of objective (guest count, park rating, etc.)
Year by which objective must be completed
Target number of guests (for guest count objective)
Target park rating
Minimum ride excitement rating required
Minimum ride length required
Target park value
Target profit from rides
Target profit from shops
Company value when objective was completed
Name recorded when objective was completed
General
General game state:Game ticks elapsed since park opened
Number of months elapsed in-game
Current day of the month (0-based)
Random number generator state (two 32-bit values)
Starting cash amount
Amount of cash guests spawn with
Initial hunger level for new guests (0-255)
Initial thirst level for new guests (0-255)
Guest spawn point coordinates and direction
Cost per tile to purchase land
Cost per tile to purchase construction rights
Interface
Interface state (viewport position, last selections):Viewport X coordinate
Viewport Y coordinate
Viewport zoom level (0 = closest, higher = further)
Viewport rotation (0-3)
Last selected entrance style
Climate
Weather and climate information:Climate type (cool & wet, warm, hot & dry, etc.)
Timer for next climate update
Current weather condition
Current temperature
Current weather effect
Current gloominess level
Current rain intensity
The
next weather state has the same structure as current and is used for smooth weather transitions.Park
Park management data:Park name (string ID reference)
Current cash balance
Current loan amount
Maximum loan available
Interest rate on loan (basis points)
Park flags (open/closed, forbid marketing, etc.)
Park entrance fee
Current park rating (0-999)
Penalty applied to rating from casualties
Expenditure in current period
Profit in current period
Total number of guests who have entered the park
Total revenue from entrance fees
Uniform color for handymen
Uniform color for mechanics
Uniform color for security guards
Weeks remaining for active marketing campaigns
Ride being marketed in campaign
Research funding level (0-3)
Bitfield of enabled research categories
Current research stage
Research progress toward next item
Last item researched
Next item to be researched
Days until park rating warning expires
Throttle timers for various peep warnings
History
Historical data for charts:Park rating history by period
Guest count history by period
Cash balance history by period
Weekly profit history
Park value history by period
Expenditure history by category and period
Tiles
Map tile data:Map dimensions (width and height in tiles)
Array of all tile elements (see Tile Elements)
Other Chunks
Additional chunk types include:- Inventions: Research/invention progress
- Things: Dynamic entities (guests, staff, vehicles)
- Rides: Ride data and statistics
- Banners: Banner text and configuration
- Animations: Active animations
- Staff: Staff member data
- Strings: Custom string table
- Editor: Editor state (if in scenario editor)
- Derived: Calculated values (park size, company value)
Tile Elements
Base Element
All tile elements share a common base structure:Element type (surface, path, track, scenery, wall, entrance, banner)
Element flags (ghost, last tile, etc.)
Base height of element (in units of 8)
Clearance height (highest point of element)
Surface Element
Terrain tile:Terrain slope/shape
Water surface height (0 if no water)
Land ownership flags
Grass length (for grass surfaces)
Surface terrain type object
Edge terrain type object
Footpath Element
Path/queue tile:Footpath object type
Bitfield of connected edges
Additional path flags (is queue, is sloped, etc.)
Path addition object (lamp, bin, etc.)
Addition state (broken, vandalised, etc.)
Station index (if queue path)
Ride index (if queue path)
Track Element
Ride track piece:Track piece type (flat, 25° up, brakes, etc.)
Sequence number within multi-tile track piece
Track style (wooden, steel, inverted, etc.)
Station index (if station piece)
Track color scheme
Track flags (is station, on-ride photo, etc.)
Track Element (Maze)
Maze ride has a different structure:Track type (always maze)
Bitfield of maze walls and entry points
Entrance Element
Ride or park entrance:Entrance object type
Associated footpath type
Ride index (0xFFFFFFFF for park entrance)
Station index
Entrance part (front, middle, back)
Scenery Element
Small scenery item:Scenery object ID
Scenery age (for aging/withering)
Primary and secondary colors
Large Scenery Element
Large scenery structure:Large scenery object ID
Three color values
Wall Element
Wall/fence piece:Wall object ID
Three color values
Animation frame (for animated walls)
Associated banner index (if wall has banner)
Banner Element
Banner (sign):Banner object type
Banner index (references banner text in Strings chunk)
Banner flags
Position on tile edge
Index Limits
Maximum values for various indices:Working with Save Files
Loading
- Read and validate header
- Verify SHA-1 hash
- Decompress data if compressed
- Read chunk index
- Load chunks in dependency order
- Validate cross-references
Saving
- Collect all game state
- Write chunks
- Build chunk index
- Compress data (optional)
- Calculate SHA-1 hash
- Write header
OpenRCT2 supports both uncompressed and compressed save files. Compression significantly reduces file size but increases save/load time.
See Also
Architecture
Learn about OpenRCT2’s codebase structure
Contributing
Contribute to OpenRCT2 development

