plasma-prp
Read, write, inspect, and manipulate Plasma engine PRP files used by Myst Online: Uru Live.
A standalone Rust library (with Python bindings and CLI) for working with the binary .prp, .age, .sdl, and .fni file formats from the H-uru/Plasma engine. Zero engine dependencies — no GPU, audio, or physics required.
Features
- Parse all object types in PRP files (scenes, materials, textures, physics, audio, animations, responders, Python script mods, and more)
- Write PRP files back with byte-identical round-trip fidelity
- Inspect PRP/AGE/SDL files from the command line
- Diff two PRP files to see what changed
- Export textures as PNG (DXT1/DXT5 decompression included)
- Validate PRP files for common issues (missing refs, broken pointers)
- Python bindings via PyO3 —
pip install plasma-prp
Install
Rust
Python
CLI
Rust Usage
Load a PRP and list all objects
use ;
let page = from_file?;
println!;
for key in &page.keys
Extract textures as PNG
use ;
use ;
let page = from_file?;
for key in page.keys_of_type
Round-trip a PRP file
use PrpPage;
let page = from_file?;
page.save?;
// output.prp is byte-identical to input.prp
Diff two PRP files
use PrpPage;
let a = from_file?;
let b = from_file?;
for key in &b.keys
Read an Age file and its pages
use AgeDescription;
let age = from_file?;
println!;
for page in age.auto_load_pages
Access materials and layers
use ;
use PrpPage;
let page = from_file?;
for key in page.keys_of_type
Parse SDL descriptors
use SdlManager;
let mut mgr = new;
mgr.load_directory?;
if let Some = mgr.find
Python Usage
# Load a PRP file
=
# List objects by type
# Access specific object types
=
# Parse materials
=
# Parse an age file
=
# Load SDL descriptors
=
=
# Round-trip
# byte-identical to input
CLI Usage
# Inspect a PRP file — object inventory grouped by class
# Inspect an age file — page list with auto-load flags
# Inspect SDL descriptors
# Validate a PRP file — check for missing refs, broken pointers
# Diff two PRP files — added/removed/modified objects
# Export all textures as PNG
Supported Object Types
The parser handles all major Plasma object types, including:
| Category | Types |
|---|---|
| Scene | plSceneObject, plSceneNode, plCoordinateInterface, plDrawInterface |
| Materials | hsGMaterial, plLayer, plLayerAnimation, plLayerSDLAnimation |
| Textures | plMipmap, plCubicEnvironmap, plDynamicTextMap |
| Animation | plATCAnim, plAGMasterMod, plAGModifier, keyframe controllers |
| Physics | plPXPhysical (trimesh, convex hull, box, sphere) |
| Audio | plWin32StaticSound, plWin32StreamingSound, plSoundBuffer |
| Logic | plResponderModifier, plLogicModifier, plOneShotMod |
| Scripting | plPythonFileMod (parameters, receivers) |
| Volumes | plObjectInVolumeDetector, plSoftVolume (simple, union, intersect, invert) |
| Visibility | plVisRegion, plRelevanceRegion |
| Camera | plCameraBrain1, plCameraBrain1_Avatar, plCameraBrain1_Fixed |
| Lighting | plDirectionalLightInfo, plOmniLightInfo, plSpotLightInfo |
| GUI | pfGUIDialogMod, pfGUIButtonMod, pfGUITextBoxMod |
| Effects | plParticleSystem, plWaveSet7, plFogEnvironment |
| Decals | plDynaFootMgr, plDynaRippleMgr, plDynaWakeMgr |
| Reverb | plEAXListenerMod |
| Vegetation | plClusterGroup |
Related Projects
- H-uru/Plasma — The open-source Plasma engine (C++)
- Korman — Blender plugin for creating Plasma ages
- libhsplasma — C++ library for Plasma file formats
License
This project is licensed under the GNU General Public License v3.0, matching the license used by Korman and the H-uru Plasma community tools.