benilla-re systems structs docs

s_preferredRealmRp

global · glue

Address
0xb41fac · 4 bytes, up to 0xb41faf
Type
int32_t
Meaning
Holds SetPreferredInfo's rp argument; written by 0x46ea20 and never read
Confidence
verified, proof one
Finding
glue/realms#the-realm-suggestion

Finding: The realm suggestion in glue: the realm list

SetPreferredInfo(category, pvp, rp) maps the ordinal (0x46edf0), reads pvp and rp as integers, and calls 0x46ea20. That stores the index in 0x837e98 (above the count, 0), the category's id in 0x837e9c, and pvp and rp in 0xb41fa8 and 0xb41fac, unread. Skipping realms with flag 0x01, it suggests:

  1. the category's first realm whose type's first Cfg_Configs row has the asked pvp and rp (a type with no row counts as 0 and 0);
  2. else the category's first realm;
  3. else the first realm matching as in 1 in any category.

A suggestion signals SUGGEST_REALM (18) with "%d%d", the index plus 1 and the position plus 1; none signals OPEN_REALM_LIST (9). A pvp or rp of 2 matches nothing.

The derivation is in the doc.