Corregido: Bug al cargar un config.txt sin valor en el puerto del server
This commit is contained in:
@@ -331,6 +331,7 @@ void Director::initOptions()
|
||||
// Online
|
||||
options->online.enabled = false;
|
||||
options->online.server = "";
|
||||
options->online.port = 0;
|
||||
options->online.gameID = "coffee_crisis";
|
||||
options->online.jailerID = "";
|
||||
options->online.score = 0;
|
||||
@@ -686,6 +687,10 @@ bool Director::setOptions(options_t *options, std::string var, std::string value
|
||||
|
||||
else if (var == "port")
|
||||
{
|
||||
if (value == "")
|
||||
{
|
||||
value = "0";
|
||||
}
|
||||
options->online.port = std::stoi(value);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user