Exemplo n.º 1
0
 def get_translator(
     self,
     max_world_version: Tuple[PlatformType, VersionNumberTuple],
     data: Any = None,
     translation_manager: "TranslationManager" = None,
 ) -> Tuple["Translator", VersionNumberAny]:
     platform, version_number = max_world_version
     if platform != "bedrock":
         raise ValueError("Platform must be bedrock")
     return Translators.get((platform, version_number)), version_number
Exemplo n.º 2
0
 def get_translator(
     self,
     max_world_version: Tuple[str, Tuple[int, int, int]],
     data: Any = None,
     translation_manager: "TranslationManager" = None,
 ) -> Tuple["Translator", Union[int, Tuple[int, int, int]]]:
     platform, version_number = max_world_version
     if platform == "java":
         version = translation_manager.get_version(platform, version_number)
         version_number = version.data_version
     return Translators.get((platform, version_number)), version_number
Exemplo n.º 3
0
 def get_translator(
     self,
     max_world_version: Tuple[PlatformType, VersionNumberTuple],
     data: Any = None,
     translation_manager: "TranslationManager" = None,
 ) -> Tuple["Translator", VersionNumberAny]:
     platform, version_number = max_world_version
     if platform == "java":
         version = translation_manager.get_version(platform, version_number)
         version_number = version.data_version
     return Translators.get((platform, version_number)), version_number
Exemplo n.º 4
0
 def get_translator(
     self,
     max_world_version: Tuple[str, int],
     data: Any = None,
     translation_manager: "TranslationManager" = None,
 ) -> Tuple["Translator", VersionNumberAny]:
     platform, version_number = max_world_version
     if platform != "java":
         raise ValueError("Platform must be java")
     version = translation_manager.get_version(platform, version_number)
     version_number = version.data_version
     return Translators.get((platform, version_number)), version_number