Catalog
Grouped accessors for bundled Dota metadata and static map data.
gem.constants remains available as a compatibility facade; new code can use gem.catalog or the more specific gem.catalog.* modules.
Generated API
Module gem.catalog.heroes
Hero catalog lookups backed by bundled dotaconstants data.
Source: src/gem/catalog/heroes.py
Top-level functions
hero_display
def hero_display(npc_name: str) -> strReturn the localized display name for an npc_dota_hero_* string.
Source: src/gem/catalog/heroes.py:16
hero_short
def hero_short(npc_name: str) -> strReturn display name from either a full npc_dota_hero_* or a bare suffix.
Source: src/gem/catalog/heroes.py:31
hero_npc_name
def hero_npc_name(name: str) -> str | NoneResolve a display name to its npc_dota_hero_* NPC name.
Source: src/gem/catalog/heroes.py:45
hero_meta
def hero_meta(npc_name: str) -> dict[str, Any]Return the full hero metadata dict, or an empty dict if not found.
Source: src/gem/catalog/heroes.py:76
hero_id
def hero_id(npc_name: str) -> intReturn the numeric Dota 2 hero ID for an npc_dota_hero_* name.
Source: src/gem/catalog/heroes.py:88
Module gem.catalog.items
Item and permanent-buff catalog lookups.
Source: src/gem/catalog/items.py
Top-level functions
item_display
def item_display(internal: str) -> strReturn display name for an item_* prefixed internal name.
Source: src/gem/catalog/items.py:24
item_key_by_id
def item_key_by_id(item_id: int) -> str | NoneReturn the internal item key for an item ability ID.
Source: src/gem/catalog/items.py:42
permanent_buff_name
def permanent_buff_name(buff_id: int) -> strReturn the item name for a permanent buff integer ID.
Source: src/gem/catalog/items.py:54
Module gem.catalog.abilities
Ability catalog lookups backed by bundled dotaconstants data.
Source: src/gem/catalog/abilities.py
Top-level functions
ability_display
def ability_display(internal: str) -> strReturn display name for an ability or item internal name.
Source: src/gem/catalog/abilities.py:44
Module gem.catalog.xp
Hero experience threshold catalog.
Source: src/gem/catalog/xp.py
Top-level functions
xp_to_next_level
def xp_to_next_level(level: int, current_xp: int) -> int | NoneReturn XP needed to reach the next level, or None at max level.
Source: src/gem/catalog/xp.py:14
Module gem.catalog.leagues
League catalog lookups.
Source: src/gem/catalog/leagues.py
Top-level functions
league_name
def league_name(leagueid: int) -> str | NoneReturn the league name for a given league ID, or None if unknown/not found.
Source: src/gem/catalog/leagues.py:14
Module gem.catalog.map
Map catalog lookups for static map and neutral-camp data.
Source: src/gem/catalog/map.py
Top-level functions
load_camp_zones
def load_camp_zones() -> dict[str, Any]Load calibrated neutral-camp zone geometry.
Source: src/gem/catalog/map.py:13
load_map_constants
def load_map_constants() -> dict[str, Any]Load static map calibration constants.
Source: src/gem/catalog/map.py:22
load_neutral_camps
def load_neutral_camps() -> list[dict[str, Any]]Load static neutral-camp center data.
Source: src/gem/catalog/map.py:31
load_neutral_camp_centers
def load_neutral_camp_centers() -> dict[int, tuple[float, float]]Load neutral camp IDs mapped to world-coordinate centers.
Source: src/gem/catalog/map.py:40
Module gem.catalog.resources
Bundled catalog resource loading.
Source: src/gem/catalog/resources.py
Top-level functions
load_data_text
def load_data_text(name: str) -> strLoad a bundled data file as text.
Source: src/gem/catalog/resources.py:16
load_data_json
def load_data_json(name: str) -> AnyLoad a bundled JSON data file.
Source: src/gem/catalog/resources.py:28