azalea/codegen/genentities.py
mat d112856ff6
Entity metadata (#37)
* add example generated metadata.rs

* metadata.rs codegen

* add the files

* add comment to top of metadata.rs

* avoid clone

* metadata

* defaults

* defaults

* fix metadata readers and writers

* fix bad bitmasks and ignore some clippy warnings in generated code

* add set_index function to entity metadatas

* applying metadata
2022-11-06 14:05:01 -06:00

19 lines
464 B
Python

import lib.code.version
import lib.code.entity
import lib.code.utils
import lib.download
import lib.extract
import sys
version_id = lib.code.version.get_version_id()
mappings = lib.download.get_mappings_for_version(version_id)
burger_data = lib.extract.get_burger_data_for_version(version_id)
burger_entity_data = burger_data[0]['entities']['entity']
lib.code.entity.generate_entity_metadata(burger_entity_data, mappings)
lib.code.utils.fmt()
print('Done!')