benilla-re systems structs docs

FriendList::SortFriends

function · net · orchestration

Address
0x5ae850 · 28 bytes, up to 0x5ae86b
Signature
void __thiscall (FriendList *this)
Meaning
Sorts the 50 friend slots with 0x5ae870 and signals FRIENDLIST_UPDATE
Confidence
verified, proof one
Finding
net/friends#friend-status-result

Finding: Friend status result in net: friends

SMSG_FRIEND_STATUS (0x68) is a result byte and a guid, read by 0x5add30 and passed to 0x5acab0 with the packet; the handler returns 1 even when there is no friend list. The result selects an action and a game error 0x496720 shows. Results 2, 3, 5, 6, 7 and 8 name a friend and 14, 15 and 16 an ignored player, so their message waits for a cache lookup, finished by 0x5ace70 for a friend and 0x5acf40 for an ignore (0x5acb7d, 0x5acd1e, 0x5acd42, 0x5acd64).

resultaction on the slotgame error
0, 4noneERR_FRIEND_NOT_FOUND
1noneERR_FRIEND_LIST_FULL
2read status byte, area, level, class into the guid's slot, mark it onlineERR_FRIEND_ONLINE_SS
3mark offlineERR_FRIEND_OFFLINE_S
5clear the slotERR_FRIEND_REMOVED_S
6, 7find or claim a slot; 6 reads the four fields as 2 does, then 6 marks online, 7 offlineERR_FRIEND_ADDED_S
8find or claim a slotERR_FRIEND_ALREADY_S
9, 10noneERR_FRIEND_SELF, ERR_FRIEND_WRONG_FACTION
11, 12, 13noneERR_IGNORE_FULL, ERR_IGNORE_SELF, ERR_IGNORE_NOT_FOUND
14, 15, 1615 adds the guid to the ignores, 16 removes itERR_IGNORE_ALREADY_S, ERR_IGNORE_ADDED_S, ERR_IGNORE_REMOVED_S
17, 18 and upnoneERR_IGNORE_AMBIGUOUS, ERR_FRIEND_ERROR

The derivation is in the doc.

Callers 3

Callees 2

Calls and jumps by a bare address, from tables/calls.tsv.