Cheats (PS2RD)
RiptOPL ships the full PS2RD cheat engine. Drop a .cht file in the CHT
folder, enable cheats in Game Settings, and choose whether OPL applies them automatically or
shows you a selection menu before the game boots.
The CHT folder and .cht file format
OPL looks for cheat files in the CHT/ folder on your storage device (USB, MMCE,
MX4SIO, iLink, SMB, or the internal HDD). The folder lives alongside DVD/,
CD/, CFG/, and the other standard OPL folders. On an APA/PFS HDD it lives in
the OPL data partition โ pfs0:CHT/, i.e. hdd0:+OPL by default โ and only
becomes pfs0:OPL/CHT/ (hdd0:<partition>/OPL/CHT/, e.g.
hdd0:__common/OPL/CHT/) when conf_hdd.cfg
points hdd_partition at a partition whose name does not start with +.
Each file covers exactly one game. The filename must match the game's startup name (its disc
ID, e.g. SLUS_123.45) with a .cht extension โ .CHT is accepted
too, because PFS and the BDM FAT drivers do not fold case and several published cheat packs ship the
uppercase spelling:
CHT/SLUS_123.45.cht
OPL also reads cheats out of CHT/cht.tar โ a flat ustar archive of
<startup>.cht members at a device root โ and looks there first, searched
across devices in the tar engine's own device order (the member name is retried with an uppercase
.CHT extension as well). The loose file above is the fallback: a tar miss, an empty
member, an oversize member, or a member that fails to parse all fall through to
CHT/<startup>.cht rather than failing the launch.
The format is plain text in PS2RD format: a cheat is a description line (the cheat name) followed by one or more hex code lines. A code line is exactly 16 hex digits โ two groups of 8 โ which OPL reads as an address (first 8) and a value (last 8):
Infinite Health 20123456 3F800000 Infinite Ammo 2034ABCD 00000063
- The 16 digits may be upper- or lower-case, split by any amount of spaces/tabs โ or run together with none. Anything that isn't 16 hex digits (plus whitespace) is read as a name line instead.
- A cheat starts with its name line; the code lines that follow belong to it. Code lines that appear before any name line are ignored, so always put the name first.
//or#begins a comment (a whole line, or a trailing note after a code). Keep whole-line comments at the start of the line โ an indented comment can leave stray whitespace that hijacks the next cheat's name.;is not a comment marker.- A name can be up to 128 characters; one cheat can carry many code lines. OPL stores up to 250 named cheats per file. Blank lines are ignored, and both LF and CRLF (Windows) line endings work.
9 (e.g. 90123ED8 โฆ). It is
the hook that lets the engine run; without it, none of the other codes do anything (they
load silently and simply never fire). Master Codes are game-specific โ copy the correct one from
a cheat database for your exact disc ID. In Select Game Cheats mode it always stays on and
can't be toggled off.
A complete example .cht file
Save this as CHT/SLUS_000.01.cht (using your game's boot ID). Every address
and value here is an illustrative placeholder โ get real codes for your title from a cheat
database:
"Example Game /ID SLUS_000.01" // optional title line โ decoration only Mastercode # REQUIRED hook. Address starts with 9. 90123ED8 0C048DB6 # Copy the real one from a cheat DB. Infinite Health 20365DB8 42C80000 20365DBC 42C80000 // a cheat can have many code lines Max Money 203C5F00 05F5E0FF Have All Items D0456788 0000FBFB # D-type: apply the next line only if a value matches 103C6210 0000270F
OPL displays each named block (Infinite Health, Max Money, โฆ) as one toggle in the launch-time cheat menu. If cheats don't take effect, the Master Code is almost always the culprit โ verify it matches your exact disc revision.
Which code types does the engine support?
The first digit of a code's address is its type, and it decides what the line does. The
type is the only part of the syntax OPL interprets โ everything else is just address and value.
RiptOPL runs the PS2RD code handler, which implements these types (verified against
ee_core/src/cheat_engine.S):
| Type | Name | What it does |
|---|---|---|
9 | Master Code (hook) | The activator hook โ required, one per file (only the first that matches is used). See the callout above. |
0 | 8-bit constant write | Continuously writes a byte to the address. |
1 | 16-bit constant write | Continuously writes a halfword. |
2 | 32-bit constant write | Continuously writes a full word. The most common cheat type. |
3 | Increment / Decrement | Adds to or subtracts from the value at an address (8/16/32-bit; 32-bit uses two lines). |
4 | Serial write | Two lines: writes a value to n addresses, stepping the address and value each time (fills tables/arrays). |
5 | Copy bytes | Two lines: copies a block of bytes from one address to another. |
6 | Pointer write | Two lines: reads a base pointer from an address, adds an offset, and writes to the result. |
7 | Boolean operation | Bitwise OR / AND / XOR of a value with what's at the address (8/16-bit). |
C | Conditional (equal) | Runs all following codes only if the 32-bit value at the address equals the given value. |
D | Conditional (multi-line) | Runs the next n code lines only if a test passes (equal, not-equal, <, >, NAND, AND, NOR, OR). |
E | Conditional (legacy) | Older encoding of the D test; handled the same way. |
Not implemented: types 8, A, and B are parsed but
silently skipped โ a cheat that relies on one of them simply won't do anything. (Type F
is a Master-Code variant, handled like type 9.) This matches upstream PS2RD; it is
not a RiptOPL limitation. If a known-good code doesn't work, check whether it uses one of these
unsupported types.
Where do I find .cht files?
PS2RD-format cheat files are the same format used by PCSX2 and many older cheat databases. Search for your game's disc ID plus "ps2rd" or "cht" to find community-maintained files, or build one by hand from Action Replay / CodeBreaker codes converted to the raw address/value form. The OPL compatibility list at OPL-CL sometimes lists known-working codes for specific titles.
Enabling cheats for a game
Open Game Settings
Highlight the game in any list and press Triangle to open the game menu, then choose Cheat Settings.
Set the settings source
The Settings Mode picker at the top of the Cheat Settings panel controls whether
OPL reads cheat options from the Global Settings (shared across all games) or
Per-game Settings (stored in a per-title file under CFG/). Choose
Per-game Settings if you want different cheat choices per title.
Enable the PS2RD Cheat Engine
Toggle PS2RD Cheat Engine on. The hint reads: "Lets PS2RD Cheat Engine patch your game." The cheat mode selector below it becomes active once cheats are enabled.
Choose a cheat mode
See the Cheat Modes section below. Select Auto Select Cheats or Select Game Cheats and save.
Cheat modes
The PS2RD Cheat Engine Mode setting has two options:
| Mode | Behaviour |
|---|---|
| Auto Select Cheats | All cheat entries in the .cht file are enabled and applied automatically
when the game launches. No selection screen is shown. |
| Select Game Cheats | A cheat selection menu appears at launch time. You can navigate the list and disable individual cheats for that session. Master Codes cannot be disabled โ they are required for any other codes to function and are always applied. |
PS2RD Cheat Image (.img)
In addition to text .cht codes, OPL supports a prebuilt PS2RD cheat image
โ a binary patch file (extension .img) that is applied directly to the game at boot,
in parallel with (and independently of) any text cheat codes. This is a separate, optional feature
controlled by its own per-game toggle.
The IMG folder
Image files live in an IMG/ folder on the same device, alongside CHT/.
The filename convention mirrors the cheat file: the game's startup name with an .img
extension:
IMG/SLUS_123.45.img
Enabling the image
In Cheat Settings for the game, find the PS2RD Cheat Image toggle (config key
$EnableImage). The hint reads: "Apply a
prebuilt PS2RD .img patch to your game." This toggle is off by default. Turn it on to
have OPL load and apply the .img file when the game next launches.
- The
$EnableImagetoggle is independent of PS2RD Cheat Engine โ you can use the image patch with or without text cheats enabled. - If the
.imgfile is absent or fails to load, OPL logs the error and continues; the game still boots. - The image is limited to 4 KB (1 024 32-bit words). Larger files are truncated to that limit.
- Like text cheats, the image patch does not apply when the game's Loader Core is set to Neutrino.
What is a PS2RD .img file?
A PS2RD cheat image is a flat binary array of 32-bit address/value word pairs in the same
format as the in-memory cheat list the engine compiles from text codes. It can be produced by
tools that export cheat engine state or by hand-crafting the binary. Unlike a .cht
file there is no human-readable text โ it is a raw patch list loaded directly into the EE core
at boot. It was popularised by wOPL and the wider OPL community as a way to distribute patches
that bypass the text-parsing step entirely.
Config keys reference
Cheat settings are written to the per-game CFG/ file (or to the global settings
if the source is set to Global). The relevant config keys are:
| Key | Values | Meaning |
|---|---|---|
$CheatsSource |
0 = Global, 1 = Per-game | Which config layer cheat settings are read from. |
$EnableCheat |
0 = Off, 1 = On | Enables the PS2RD Cheat Engine for this game. |
$CheatMode |
0 = Auto Select, 1 = Select Game Cheats | Whether all cheats run automatically or a selection menu appears at launch. |
$EnableImage |
0 = Off, 1 = On | Loads and applies the prebuilt .img binary patch alongside (or instead of) text codes. |