move default keyboard and joystick config into files

This commit is contained in:
Martin Michelsen
2024-08-06 22:36:01 -07:00
parent fbc5cd5967
commit 24be0d8195
5 changed files with 48 additions and 16 deletions
+7
View File
@@ -828,6 +828,13 @@ void Client::load_all_files() {
if (!this->system_data) {
this->system_data = make_shared<PSOBBBaseSystemFile>();
auto s = this->require_server_state();
if (s->bb_default_keyboard_config) {
this->system_data->key_config = *s->bb_default_keyboard_config;
}
if (s->bb_default_joystick_config) {
this->system_data->joystick_config = *s->bb_default_joystick_config;
}
files_manager->set_system(sys_filename, this->system_data);
player_data_log.info("Created new system data");
}