mirror of
https://github.com/minetest/minetest.git
synced 2024-11-27 01:53:45 +01:00
No longer auto-generate a 'guest####' player name when name is empty
You can't join most servers with a 'guest####' player name anyway so it's only logical to remove them.
This commit is contained in:
parent
607dab2b0d
commit
e2ad76f910
@ -403,11 +403,12 @@ bool ClientLauncher::launch_game(std::string &error_message,
|
||||
return false;
|
||||
}
|
||||
|
||||
if (menudata.name == "")
|
||||
menudata.name = std::string("Guest") + itos(myrand_range(1000, 9999));
|
||||
else
|
||||
playername = menudata.name;
|
||||
if (menudata.name == "" && !simple_singleplayer_mode) {
|
||||
error_message = gettext("Please choose a name!");
|
||||
return false;
|
||||
}
|
||||
|
||||
playername = menudata.name;
|
||||
password = menudata.password;
|
||||
|
||||
g_settings->set("name", playername);
|
||||
|
Loading…
Reference in New Issue
Block a user