forked from Hay1tsme/artemis
add opt static tables
This commit is contained in:
@ -1,5 +1,6 @@
|
||||
from enum import Enum, IntEnum
|
||||
|
||||
from typing import Optional
|
||||
from core.utils import floor_to_nearest_005
|
||||
|
||||
class ChuniConstants:
|
||||
GAME_CODE = "SDBT"
|
||||
@ -78,10 +79,34 @@ class ChuniConstants:
|
||||
( 0, "D"),
|
||||
]
|
||||
|
||||
VERSION_LUT = {
|
||||
"100": VER_CHUNITHM,
|
||||
"105": VER_CHUNITHM_PLUS,
|
||||
"110": VER_CHUNITHM_AIR,
|
||||
"115": VER_CHUNITHM_AIR_PLUS,
|
||||
"120": VER_CHUNITHM_STAR,
|
||||
"125": VER_CHUNITHM_STAR_PLUS,
|
||||
"130": VER_CHUNITHM_AMAZON,
|
||||
"135": VER_CHUNITHM_AMAZON_PLUS,
|
||||
"140": VER_CHUNITHM_CRYSTAL,
|
||||
"145": VER_CHUNITHM_CRYSTAL_PLUS,
|
||||
"150": VER_CHUNITHM_PARADISE,
|
||||
"200": VER_CHUNITHM_NEW,
|
||||
"205": VER_CHUNITHM_NEW_PLUS,
|
||||
"210": VER_CHUNITHM_SUN,
|
||||
"215": VER_CHUNITHM_SUN_PLUS,
|
||||
"220": VER_CHUNITHM_LUMINOUS,
|
||||
"225": VER_CHUNITHM_LUMINOUS_PLUS,
|
||||
}
|
||||
|
||||
@classmethod
|
||||
def game_ver_to_string(cls, ver: int):
|
||||
return cls.VERSION_NAMES[ver]
|
||||
|
||||
@classmethod
|
||||
def int_ver_to_game_ver(cls, ver: int) -> Optional[int]:
|
||||
""" Takes an int ver (ex 100 for 1.00) and returns an internal game version """
|
||||
return cls.VERSION_LUT.get(str(floor_to_nearest_005(ver)), None)
|
||||
|
||||
class MapAreaConditionType(IntEnum):
|
||||
"""Condition types for the GetGameMapAreaConditionApi endpoint. Incomplete.
|
||||
|
Reference in New Issue
Block a user