refactor player/account data handling

This commit is contained in:
Martin Michelsen
2022-05-06 13:40:38 -07:00
parent 839cbb2ee4
commit 4079400784
13 changed files with 873 additions and 821 deletions
+8
View File
@@ -58,6 +58,14 @@ Client::Client(
memset(&this->next_connection_addr, 0, sizeof(this->next_connection_addr));
}
void Client::set_license(shared_ptr<const License> l) {
this->license = l;
this->game_data.serial_number = this->license->serial_number;
if (this->version == GameVersion::BB) {
this->game_data.bb_username = this->license->username;
}
}
ClientConfig Client::export_config() const {
ClientConfig cc;
cc.magic = CLIENT_CONFIG_MAGIC;