Skip to content

Player V2

Michal Mikulec edited this page Mar 18, 2022 · 4 revisions

class siegeapi.Player()

Attributes

  • id str ⇒ Ubi user ID
  • profile_pic_url_146 str ⇒ 146px × 146px profile pic URL
  • profile_pic_url_256 str ⇒ 256px × 256px profile pic URL
  • profile_pic_url_500 str ⇒ 500px × 500px profile pic URL
  • profile_pic_url str ⇒ Alias for profile_pic_256
  • name str ⇒ Players' current Ubisoft username
  • level int ⇒ Current level
  • alpha_pack int ⇒ Current alpha pack %
  • xp int ⇒ XP Gained in the current level
  • total_xp int ⇒ Total XP gained
  • xp_to_level_up int ⇒ XP needed to level up
  • total_time_played int ⇒ In seconds
  • pvp_time_played int ⇒ In seconds
  • pve_time_played int ⇒ In seconds
  • ranks dict ⇒ Ranked seasons data is stored here
  • casuals dict ⇒ Casual seasons data is stored here
  • newcomers dict ⇒ Newcomer seasons data is stored here
  • events dict ⇒ Event seasons data is stored here
  • weapons WeaponsWeapons
  • trends TrendsTrends
  • operators OperatorsOperators
  • gamemodes GamemodesGamemodes
  • maps MapsMaps

Methods

  • load_playtime() -> None

    • Loads pvp_time_played, pve_time_played & total_time_played
  • load_progress() -> None

    • Loads alpha_pack, level, xp, total_xp & xp_to_level_up
  • load_ranked(season: int = -1, region: str = "emea") -> Rank

    • Loads and returns the ranked Rank object for the specified region and season (-1 = latest season)

    Valid region names are "emea", "ncsa" & "apac"

  • load_casual(season: int = -1, region: str = "emea") -> Rank

    • Loads and returns the casual Rank object for the specified region and season (-1 = latest season)

    Valid region names are "emea", "ncsa" & "apac"

  • load_newcomer(season: int = -1, region: str = "emea") -> Rank

    • Loads and returns the newcomer Rank object for the specified region and season (-1 = latest season)

    Valid region names are "emea", "ncsa" & "apac"

  • load_events(season: int = -1, region: str = "emea") -> Rank

    • Loads and returns the events Rank object for the specified region and season (-1 = latest season)

    Valid region names are "emea", "ncsa" & "apac"

  • load_trends(block_duration: TrendBlockDuration = TrendBlockDuration.WEEKLY) -> Trends

    • Loads and returns Trend data to Player.trends and returns said data
    • TrendBlockDuration can be one of the following .DAILY / .WEEKLY / .MONTHLY
  • load_weapons() -> Weapons

  • load_operators() -> Operators

  • load_gamemodes() -> Gamemodes

  • load_maps() -> Maps

    • Loads and returns Maps data