diff --git a/.env b/.env index 09d6a5a..4ffaf34 100644 --- a/.env +++ b/.env @@ -10,7 +10,10 @@ MINECRAFT_VERSION=1.16 DESCRIPTION=My Custom Resource Pack # supported versions +VERSION_TYPE=specific #or range SUPPORTED_VERSIONS=1.17,1.18,1.19-1.19.4,1.20, 1.21 +min_version=1.16 +max_version=1.21.1 # Включение языков INCLUDE_LANGUAGE=False diff --git a/Compilator for RP.py b/Compilator for RP.py index 8b60ef9..8c3302f 100644 --- a/Compilator for RP.py +++ b/Compilator for RP.py @@ -58,6 +58,8 @@ def get_supported_formats(versions): minecraft_version = os.getenv("MINECRAFT_VERSION") description = os.getenv("DESCRIPTION") supported_versions = parse_list(os.getenv("SUPPORTED_VERSIONS")) +min_versions = parse_list(os.getenv("min_version")) +max_versions = parse_list(os.getenv("max_version")) include_language = os.getenv("INCLUDE_LANGUAGE") == 'True' include_credits = os.getenv("INCLUDE_CREDITS") == 'True' include_animation = os.getenv("INCLUDE_ANIMATION") == 'True' @@ -101,7 +103,7 @@ def get_supported_formats(versions): "pack": { "pack_format": pack_format, "description": description, - "supported_formats": get_supported_formats(supported_versions) + "supported_formats": { "min_inclusive": get_pack_format(min_versions), "max_inclusive": get_pack_format(max_versions)}, #get_supported_formats(supported_versions) # } }