A Python library for encoding and decoding Build logic save data.
Project description
Functions BLSSLIB.DecodeBlockItem(raw:str) -> dict - raw : is the raw string of a block item that is not in a save of any kind or is in relation to another block (ie it is not wired)
OUTPUT:
a python dict that contains the basic data of the block
id : its name in the game like block or EEPROM
position : the x y and z of the block if it is a multiblock then its made location ie form were it was placed from will be shown
colour : the rgb colour (can some times not exist for components but this is for block only)
rotation : a chr showing the 1 ofr 24 rotation values
BLSSLIB.DecodeBlockSave(save : str) -> list[dict[str:str]] basicly splits by the ; and does the DecodeBlockItem on each block
BLSSLIB.EncodeBlockItem(block:dict) -> str does the opposit of the BLSSLIB.DecodeBlockItem()
BLSSLIB.EncodeBlockSave(blocks:list[dict[str:str]]) -> str taskes each dict of block data convets to save steign and adds a ; to it and repeat
BLSSLIB.addEeprom8(data:list[int|str], world: list[dict[str:str]], position: tuple[int, int, int], rotation: str) -> dict so takes in data that is converted into a eeprom at 0 0 0 with a function then it extracts the data part of the eeprom save and puts it in a new empty eeprom at position and rotation it also raises a error if the positon .. +1 to z .. ... .. +8 to z is any of those positon are alredy in the world (defined later)
world is a list of the dict of your decoded save you are likely to have this as when you decode a save you get a list of dict that you edit and use to sore the save to be further Encoded
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file blsslib-0.1.15.tar.gz.
File metadata
- Download URL: blsslib-0.1.15.tar.gz
- Upload date:
- Size: 5.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f17a32202a0ae81c5f481dd8c6666d187abe41387cb4968eddf7b81a77782723
|
|
| MD5 |
f47259cfc5e60aa3ae6e101e3dc8f6f7
|
|
| BLAKE2b-256 |
1d499a67f5cb591ecb8503865ceed4e92141628c979a034081883b8a9950a0bc
|
File details
Details for the file BLSSLIB-0.1.15-py3-none-any.whl.
File metadata
- Download URL: BLSSLIB-0.1.15-py3-none-any.whl
- Upload date:
- Size: 7.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3169e0c415a1b67be97677ccd49609877996d60c79ec36b7910c0255d7535881
|
|
| MD5 |
7f531f01163120515bd97f50b5e0ccdf
|
|
| BLAKE2b-256 |
e3bf49385b7f843a61f4062c47002365894b2dfdd10e902eda5f25fdc65b39c7
|