Add seed and version info to output
- Add seed - Normalize seed code to BCEX format - Add is_bcce - Bump version to 0.2
This commit is contained in:
parent
8697253ea6
commit
49d5e1260f
1 changed files with 10 additions and 1 deletions
11
main.py
11
main.py
|
@ -1,6 +1,6 @@
|
||||||
#!/usr/bin/env python3
|
#!/usr/bin/env python3
|
||||||
|
|
||||||
__version__ = "0.1"
|
__version__ = "0.2"
|
||||||
__author__ = "Trysdyn Black"
|
__author__ = "Trysdyn Black"
|
||||||
|
|
||||||
import json
|
import json
|
||||||
|
@ -123,6 +123,15 @@ def parse_COMMANDS(data):
|
||||||
return commands
|
return commands
|
||||||
|
|
||||||
|
|
||||||
|
def parse_SEED(data):
|
||||||
|
is_BCCE = True if data.startswith("CE") else False
|
||||||
|
|
||||||
|
# Normalize seed codes to BCEX format, removing spaces and replacing pipes with dots
|
||||||
|
seed = data.replace("|", ".").replace(" ", "")
|
||||||
|
|
||||||
|
return {"is_bcce": is_BCCE, "seed": seed}
|
||||||
|
|
||||||
|
|
||||||
def load(filename):
|
def load(filename):
|
||||||
# Load our file, tokenize by section header (starting with ====)
|
# Load our file, tokenize by section header (starting with ====)
|
||||||
with open(filename) as infile:
|
with open(filename) as infile:
|
||||||
|
|
Loading…
Add table
Reference in a new issue