1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-06-27 16:36:03 +00:00

Use JSON for favorites, move server list code to Lua (#10085)

Co-authored-by: sfan5 <sfan5@live.de>
This commit is contained in:
rubenwardy 2021-01-22 15:08:57 +00:00 committed by GitHub
parent 4fcd000e20
commit 67aa75d444
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
17 changed files with 388 additions and 528 deletions

View file

@ -487,14 +487,6 @@ bool ClientLauncher::launch_game(std::string &error_message,
start_data.socket_port = myrand_range(49152, 65535);
} else {
g_settings->set("name", start_data.name);
if (!start_data.address.empty()) {
ServerListSpec server;
server["name"] = server_name;
server["address"] = start_data.address;
server["port"] = itos(start_data.socket_port);
server["description"] = server_description;
ServerList::insert(server);
}
}
if (start_data.name.length() > PLAYERNAME_SIZE - 1) {