SplitScript reference / ManagedReadable
ManagedReadable
capability
capability ManagedReadable
Supports a managed value decoder rather than requiring a fixed byte layout.
Every MemoryReadable type satisfies this capability. String and nullable strings additionally decode managed object references and own their resulting text. String schema fields use their stored UTF-16 length and share a materialization budget. Class snapshots recursively read child classes and nullable child classes. Arrays recursively decode managed-readable elements, including arrays, optional strings, and owned class snapshots. List<T> storage projects to owned arrays; Map reads managed dictionaries with recursively decoded keys and values. Set reads managed hash sets with recursively decoded elements, rejecting collisions under local equality. Arrays, maps, and sets materialized by managed reads are deeply immutable, including inline fixed-array children. Mutating them through any alias traps. Ordinary local collections and arrays returned by Process.read remain mutable. ManagedReadable does not make a type usable with Process.read, which still requires MemoryReadable.
Examples
Decode text from a managed field
image "Assembly-CSharp" {
class Player { static String name; }
}
state Unity ["game.exe"] { name = Player.name?; }
whileAttached { print(current.name) }
Implemented by
| Member | Description | Available through |
|---|---|---|
| String | Stores ordinary immutable UTF-8 text in WebAssembly GC memory. | |
| address | Stores a process address. | |
| bool | Stores a boolean value. | |
| f32 | Stores a 32-bit floating-point number. | |
| f64 | Stores a 64-bit floating-point number. | |
| i16 | Stores a 16-bit signed integer. | |
| i32 | Stores a 32-bit signed integer. | |
| i64 | Stores a 64-bit signed integer. | |
| i8 | Stores an 8-bit signed integer. | |
| u16 | Stores a 16-bit unsigned integer. | |
| u32 | Stores a 32-bit unsigned integer. | |
| u64 | Stores a 64-bit unsigned integer. | |
| u8 | Stores an 8-bit unsigned integer. |