mirror of
https://github.com/whoahq/whoa.git
synced 2026-11-16 03:01:23 +03:00
feat(glue): implement CCharacterSelection::UpdateCharacterList
This commit is contained in:
4 files changed
+103
No files matched your search
@@ -170,6 +170,14 @@ int32_t ClientConnection::Disconnect() {
|
||||
return 1;
|
||||
}
|
||||
|
||||
void ClientConnection::EnumerateCharacters(ENUMERATE_CHARACTERS_CALLBACK callback, void* param) {
|
||||
// TODO Assertion-like thing
|
||||
|
||||
for (uint32_t i = 0; i < this->m_characterList.Count(); i++) {
|
||||
callback(this->m_characterList[i], param);
|
||||
}
|
||||
}
|
||||
|
||||
void ClientConnection::GetCharacterList() {
|
||||
this->Initiate(COP_GET_CHARACTERS, 43, nullptr);
|
||||
|
||||
|
||||
@@ -7,6 +7,8 @@
|
||||
|
||||
class RealmResponse;
|
||||
|
||||
typedef void (*ENUMERATE_CHARACTERS_CALLBACK)(const CHARACTER_INFO&, void*);
|
||||
|
||||
class ClientConnection : public RealmConnection {
|
||||
public:
|
||||
// Member variables
|
||||
@@ -32,6 +34,7 @@ class ClientConnection : public RealmConnection {
|
||||
void Complete(int32_t result, int32_t errorCode);
|
||||
void Connect();
|
||||
int32_t Disconnect();
|
||||
void EnumerateCharacters(ENUMERATE_CHARACTERS_CALLBACK callback, void* param);
|
||||
void GetCharacterList();
|
||||
void Initiate(WOWCS_OPS op, int32_t errorCode, void (*cleanup)());
|
||||
int32_t IsConnected();
|
||||
|
||||
Reference in new issue
Block a user