CharacterIO
character_io
load_character(path)
Load a Character from a JSON file.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
path
|
str | Path
|
Path to JSON file. |
required |
Returns:
| Type | Description |
|---|---|
Character
|
Character instance. |
Source code in src/rpgleveler/io/character_io.py
19 20 21 22 23 24 25 26 27 28 29 30 | |
save_character(character, path)
Save a Character to a JSON file.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
character
|
Character
|
Character to serialize. |
required |
path
|
str | Path
|
Output file path. |
required |
Source code in src/rpgleveler/io/character_io.py
7 8 9 10 11 12 13 14 15 16 | |