Repository navigation
lcmem Patches
Patches are JSON, so a fix can be shared as a file instead of an address that
stops working after a restart. They live in patches/community.json.
python -m lcmem patch list
python -m lcmem patch apply fov
python -m lcmem patch revert # restores every applied patchkind |
Target | Survives |
|---|---|---|
mono |
class + field name, resolved through metadata | restarts and most updates |
aob |
byte signature with ?? wildcards |
game updates, usually |
module |
offset inside a loaded module | restarts, not updates |
{
"name": "fov",
"description": "Override the camera field of view (CameraFXManager.CameraFOV)",
"kind": "mono",
"class": "CameraFXManager",
"namespace": "CameraFX",
"field": "CameraFOV",
"instance": 0,
"type": "f32",
"value": 75.0,
"enabled": false
}-
type:i8 u8 i16 u16 i32 u32 i64 u64 f32 f64, orbytes(hex string) -
enabled: patches withfalseare skipped bypatch apply -
kind=mono:class,field,instance(index), optionalnamespace -
kind=module:module,offset -
kind=aob:pattern,pattern_offset,executable_only
The shipped patches are templates and all disabled. Before enabling one,
check it: type <Class> for the predicted offset, then instances <Class>
and object <addr> to confirm the live values look right.
Applying records the exact bytes it overwrote in .lcmem/backups.json, keyed
by process ID. revert restores exactly those bytes, and a backup from an old
process is never replayed into a new one.
If a write does not stick, lcmem rolls it back and warns you. That usually
means the game rewrites the value every frame, and the fix belongs in the
code that writes it: a Harmony patch in Love Menu, not a memory patch.