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:
parent
4fcd000e20
commit
67aa75d444
17 changed files with 388 additions and 528 deletions
|
@ -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) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue