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

Server configuration is now written when "/#setting whatever = whatever" is issued.

This commit is contained in:
Perttu Ahola 2011-07-30 19:49:42 +03:00
parent 9b294ffa7a
commit cdadbdbd17
7 changed files with 36 additions and 14 deletions

View file

@ -142,10 +142,16 @@ void cmd_setting(std::wostringstream &os,
return;
}
std::string confline = wide_to_narrow(
ctx->parms[1] + L" = " + ctx->paramstring);
/*std::string confline = wide_to_narrow(
ctx->parms[1] + L" = " + ctx->params[2]);*/
std::string confline = wide_to_narrow(ctx->paramstring);
g_settings.parseConfigLine(confline);
os<< L"-!- Setting changed.";
ctx->server->saveConfig();
os<< L"-!- Setting changed and configuration saved.";
}
void cmd_teleport(std::wostringstream &os,