Alts

Contributor2 min readUpdated

In short

The Characters page

addon/Polestar/Alts/ (Alts\Alts.xml, loaded after Talents\Talents.xml): Snapshot.lua (Polestar.Alts: the saved snapshots, the events that write them, the alts command), Options.lua (Discovery → Characters), View.lua (the hub section, order 60).

text
Polestar.Alts.Key() -> "Name-Realm"                         -- as Maps/Instances.lua files its entries
Polestar.Alts.List(sortBy) -> entries                       -- the playing character first, then "seen" (default) | "rested" | "level"
Polestar.Alts.Forget(key) -> boolean                        -- never the playing character
Polestar.Alts.Write(silent, touch) -> boolean               -- the playing character's entry (touch: only `seen`); false with alts.enabled off
Polestar.Alts.ProjectRested(entry, now) -> xp | nil         -- no saved state; nil at the level cap (now defaults to the server time)
Polestar.Alts.Rested(entry, now) -> xp | nil                -- live for the playing character, else projected
Polestar.Alts.IsCurrent(entry), Polestar.Alts.MaxLevel(), Polestar.Alts.Enabled()

Store

PolestarDB.alts.chars["Name-Realm"], one small entry per character: name, realm, class, race, faction, level, xp, xpMax, rested, resting, zone, bind, money, profs (skill line to rank), tabs (up to six { id, title, step, count, complete } from Engine.GetTabs) with active, seen (server time), key. Values that equal nothing are left out. An alt's entry is as of its last write, normally its logout.

Writes

All in the world: at login (after five seconds, once the tabs exist), on resting changes at once, on level-ups, XP, zone, money, skill and tab changes coalesced into one write every ten seconds (a single pending timer) while not resting, and at once while IsResting() reads true, and at once when the player asks to leave (PLAYER_CAMPING / PLAYER_QUITING where the client has them). Logout and Quit are protected functions and are not hooked; writing at once while resting (an inn or city, where an instant logout is possible) is what leaves the saved entry current when they are used. Also when the Characters page is drawn (so the playing character is current there) and when alts.enabled is turned on. A write merges into the entry: a field that does not read keeps its saved value; the zone is the zone-type map above the player's map, not an indoor area's name. PLAYER_LEAVING_WORLD and PLAYER_LOGOUT read nothing and only move seen: the client answers wrongly while the world goes (resting false, no gold, no map, the indoor area for the zone), plausibly enough that nothing could tell, so those reads would overwrite good values. ALTS_UPDATED follows a write. alts.enabled (default on) off: no events registered, no writes; saved entries are still listed, and can be forgotten.

Rested XP

ProjectRested uses Classic's rules as named constants (REST_PER_8H, AWAY_FACTOR, REST_CAP); Forever's rates are unverified, so an alt's figure is an estimate.

Section

One Button row per character (so the gamepad can focus it), sorted by alts.sort (the hub tabs: Last played, Most rested, Level); the sidebar has an entry per character, which selects and scrolls to its row; the instance count, in the subtitle, is Maps.GetInstanceStatus(). Forget uses W.Confirm. SHOW_ALTS opens it (/pole alts).
Was this page helpful?

Start with, or act

  • PlayersInstall and first run
  • PlayersCommunity guides
  • PlayersFAQ
  • Guide authorsWriting a community guide
  • Guide authorsGuide format cheatsheet
  • ContributorsContributing
  • ActionCopy the AddOns folder (Windows)C:\Program Files (x86)\World of Warcraft\_classic_beta_\Interface\AddOns
  • ActionCopy the AddOns folder (macOS)/Applications/World of Warcraft/_classic_beta_/Interface/AddOns
  • ActionFind an optionEvery setting with its default; type its name here to jump to it.
  • ActionEvery slash command