SL2 Analyzer
Read a FromSoftware .sl2 save and report what is in it
Loading...
Searching...
No Matches
jsonout.py File Reference

Go to the source code of this file.

Namespaces

namespace  sl2
 
namespace  sl2.jsonout
 

Functions

 sl2.jsonout.meta_key (key)
 Normalise a CLI metadata key: lowercase, spaces and dashes to underscores.
 
 sl2.jsonout.parse_meta (pairs, path=None)
 Build the environment block from repeated --meta key=value arguments and an optional JSON file.
 
 sl2.jsonout.jsonable (value)
 Make a parsed value safe for json.dump, without changing what it says.
 
 sl2.jsonout.character_json (slot_no, ch, report=None)
 One character as a JSON object: its slot number, then every field the parse actually set.
 
 sl2.jsonout.build_json (save, filename, meta=None, validate=False, data=None)
 Build the whole JSON document for a parsed save.
 

Variables

str sl2.jsonout.SCHEMA_URL = "https://sl2-analyzer.darthdemono.com/schema.json"
 Where the schema is published.
 
str sl2.jsonout.SCHEMA_VERSION = "1.3.0"
 Schema version, semver.
 
tuple sl2.jsonout.KNOWN_META
 Environment keys the schema names explicitly.