EntityTranslator class¶
- class PyMCTranslate.py3.api.version.translators.entity.EntityTranslator(translation_manager, parent_version, database, *_)[source]¶
Bases:
BaseTranslator
- base_names(namespace, force_blockstate=False)¶
A list of all the valid base names present in a given namespace for this object type.
- from_universal(entity, force_blockstate=False)[source]¶
A method to translate a given Entity object from the Universal format to the format of this class instance.
- get_mapping_from_universal(namespace, base_name, force_blockstate=False)¶
Get the mapping file for the requested object from the universal format to this version format.
- Parameters
- Return type
- Returns
A list of mapping functions to apply to the object
- get_mapping_to_universal(namespace, base_name, force_blockstate=False)¶
Get the mapping file for the requested object from this version format to the universal format.
- Parameters
- Return type
- Returns
A list of mapping functions to apply to the object
- get_specification(namespace, base_name, force_blockstate=False)[source]¶
Get the specification file for the requested object.
- Parameters
- Return type
EntitySpecification
- Returns
A custom dictionary with a better documented API.
- namespaces(force_blockstate=False)¶
A list of all the valid namespaces for this object type.