monster package#

Submodules#

monster.server module#

parse_value(v: list[int], *, little_endian=True) → int[source]#

Parse and unpack the various structs used for gold and other values.

class MonsterSave(file: str, sfile: str)[source]#

Bases: object

update_data(data: dict)[source]#
store_starter_cards()[source]#

Keep track of the cards we start with.

clear_starter_cards()[source]#
property deck#
deck_as_html()[source]#
get_fight_names() → list[str][source]#

Get the list of run snapshots for “over time” stats.

property rings#
property gold: int#

The current count of gold. Ignores in-fight gains.

property gold_graph: list[int]#

The gold count at specific snapshots during the run.

property dragons_hoard: int#

The current count of Dragon’s Hoard.

property dragons_hoard_cap: int#

The current limit of Dragon’s Hoard we can hold.

property use_dragons_hoard: bool#
property forge_points: int#

The current count of Forge Points being held.

property use_forge_points: bool#
property pyre_hp: int#

The current Pyre HP.

property pyre_hp_graph: list[int]#

The Pyre HP at specific snapshots during the run.

property pyre_max_hp: int#

The Pyre Max HP.

property pyre_max_hp_graph: list[int]#

The Pyre Max HP at specific snapshots during the run.

property in_game: bool#
property champion#
get_clan_image(*, is_main: bool) → str[source]#

Generate an SVG with the clan with or without exiled symbol.

Parameters:

is_main (bool) – Whether this is the main clan we want.

Returns:

A full SVG matching the clan.

Return type:

str

property main_class: str#
property main_exiled: bool#
property main_clan: str#
property main_clan_icon: str#
property sub_class: str#
property sub_exiled: bool#
property sub_clan: str#
property sub_clan_icon: str#
property artifacts: Generator[Artifact, None, None]#
property challenge: Challenge | None#
property covenant_level: int#
property pyre: Character#
property mutators: list[Mutator | Mutator2]#
property souls: list[Soul]#
class Ring(ring: int, farthest: int, in_fight: bool, data: dict, battle: dict | None)[source]#

Bases: object

Store information for one ring.

property boss#

Get the ring’s boss. Does not display major (flying) bosses.

property align: bool#
get_nodes()[source]#

Get the nodes on left, center, and right respectively.

get_names()[source]#

Return names for the before and after.

property trial: Trial | None#

Get the ring’s trial, if it was taken.

property is_titan_trial: bool#
class CardData(data: dict)[source]#

Bases: object

property card: Card2#
property upgrades: list[CardUpgrade]#
class CardUpgrade(data: dict)[source]#

Bases: object

property upgrade: Upgrade#
class Metasave(filename: str)[source]#

Bases: object

update_data(data: dict)[source]#
property max_covenant: int#
async get_savefile(ctx: Context | Context | None = None) → MonsterSave[source]#
async current_mt2(req: Request)[source]#
async receive_save_data(req: Request)[source]#
async receive_meta_data(req: Request)[source]#
async get_data(req: Request)[source]#
async mt_current(req: Request)[source]#
async mt_state(req: Request)[source]#

monster.static module#

query(name: str)[source]#
get(name: str) → Base[source]#

Get the class for the given data. Matches either internal name or ID.

get_safe(name: str) → str[source]#

Get the name matching the ID or internal name, or the input back if none found.

get_champion(clan: str | Clan, exiled: bool)[source]#

Get the matching Champion for the clan and exiled.

load_mt1()[source]#
load_mt2(base: Path = PosixPath('.'))[source]#

Module contents#

async initial_load()[source]#