Skip to content

XP

genjishimada_sdk.xp

PlayersPerSkillTierResponse

Bases: Struct

Number of players per skill tier.

Attributes:

Name Type Description
tier str

Name of the skill tier.

amount int

Count of players in the tier.

amount: int instance-attribute

tier: str instance-attribute

PlayersPerXPTierResponse

Bases: Struct

Number of players per XP tier.

Attributes:

Name Type Description
tier str

Name of the XP tier.

amount int

Count of players in the tier.

amount: int instance-attribute

tier: str instance-attribute

TierChangeResponse

Bases: Struct

Computed tier deltas between old and new XP.

Attributes:

Name Type Description
old_xp int

XP before the change.

new_xp int

XP after the change.

old_main_tier_name str

Main tier label before the change.

new_main_tier_name str

Main tier label after the change.

old_sub_tier_name str

Sub-tier label before the change.

new_sub_tier_name str

Sub-tier label after the change.

old_prestige_level int

Prestige level before the change.

new_prestige_level int

Prestige level after the change.

rank_change_type str | None

Description of the rank movement, if any.

prestige_change bool

Whether the prestige level changed.

new_main_tier_name: str instance-attribute

new_prestige_level: int instance-attribute

new_sub_tier_name: str instance-attribute

new_xp: int instance-attribute

old_main_tier_name: str instance-attribute

old_prestige_level: int instance-attribute

old_sub_tier_name: str instance-attribute

old_xp: int instance-attribute

prestige_change: bool instance-attribute

rank_change_type: str | None instance-attribute

XP_AMOUNTS: dict[XP_TYPES, int] = {'Map Submission': 30, 'Playtest': 35, 'Guide': 35, 'Completion': 5, 'Record': 15, 'World Record': 50} module-attribute

XP_TYPES = Literal['Map Submission', 'Playtest', 'Guide', 'Completion', 'Record', 'World Record', 'Other'] module-attribute

XpGrantEvent

Bases: Struct

Event emitted when XP is granted to a user.

Attributes:

Name Type Description
user_id int

Identifier of the user receiving XP.

amount int

Amount of XP granted.

type XP_TYPES

Category describing why XP is granted.

previous_amount int

XP total before the grant.

new_amount int

XP total after the grant.

amount: int instance-attribute

new_amount: int instance-attribute

previous_amount: int instance-attribute

type: XP_TYPES instance-attribute

user_id: int instance-attribute

XpGrantRequest

Bases: Struct

Request payload for granting XP.

Attributes:

Name Type Description
amount int

Amount of XP to grant.

type XP_TYPES

Category describing why XP is granted.

amount: int instance-attribute

type: XP_TYPES instance-attribute

XpGrantResponse

Bases: Struct

Return payload when XP is granted.

Attributes:

Name Type Description
previous_amount int

XP amount before the grant.

new_amount int

XP amount after the grant.

new_amount: int instance-attribute

previous_amount: int instance-attribute

__all__ = ('XP_AMOUNTS', 'XP_TYPES', 'PlayersPerSkillTierResponse', 'PlayersPerXPTierResponse', 'TierChangeResponse', 'XpGrantEvent', 'XpGrantRequest', 'XpGrantResponse') module-attribute