-maxplayers or -players cl argument should override config
additions to /removespecial
This commit is contained in:
parent
3bbfa1b434
commit
d478810336
2 changed files with 38 additions and 28 deletions
59
TShockAPI/Commands.cs
Normal file → Executable file
59
TShockAPI/Commands.cs
Normal file → Executable file
|
|
@ -1542,33 +1542,38 @@ namespace TShockAPI
|
||||||
for (int x = 0; x < Main.maxTilesX; x++)
|
for (int x = 0; x < Main.maxTilesX; x++)
|
||||||
{
|
{
|
||||||
for (int y = 0; y < Main.maxTilesY; y++)
|
for (int y = 0; y < Main.maxTilesY; y++)
|
||||||
{
|
{
|
||||||
switch (Main.tile[x, y].type)
|
switch (Main.tile[x, y].type)
|
||||||
{
|
{
|
||||||
case 117:
|
case 117:
|
||||||
case 25:
|
case 25:
|
||||||
Main.tile[x, y].type = 1;
|
Main.tile[x, y].type = 1;
|
||||||
break;
|
break;
|
||||||
case 109:
|
case 109:
|
||||||
case 23:
|
case 23:
|
||||||
Main.tile[x, y].type = 2;
|
Main.tile[x, y].type = 2;
|
||||||
break;
|
break;
|
||||||
case 32:
|
case 32:
|
||||||
Main.tile[x, y].type = 0;
|
case 113:
|
||||||
Main.tile[x, y].active = false;
|
case 110:
|
||||||
break;
|
Main.tile[x, y].type = 0;
|
||||||
case 24:
|
Main.tile[x, y].active = false;
|
||||||
Main.tile[x, y].type = 3;
|
break;
|
||||||
break;
|
case 24:
|
||||||
case 112:
|
Main.tile[x, y].type = 3;
|
||||||
case 116:
|
break;
|
||||||
Main.tile[x, y].type = 53;
|
case 112:
|
||||||
break;
|
case 116:
|
||||||
case 113:
|
Main.tile[x, y].type = 53;
|
||||||
Main.tile[x, y].type = 38;
|
break;
|
||||||
break;
|
case 118:
|
||||||
default:
|
Main.tile[x, y].type = 38;
|
||||||
continue;
|
break;
|
||||||
|
case 115:
|
||||||
|
Main.tile[x, y].type = 52;
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
continue;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
7
TShockAPI/TShock.cs
Normal file → Executable file
7
TShockAPI/TShock.cs
Normal file → Executable file
|
|
@ -384,7 +384,12 @@ namespace TShockAPI
|
||||||
Config.RestApiPort = Convert.ToInt32(parms[++i]);
|
Config.RestApiPort = Convert.ToInt32(parms[++i]);
|
||||||
Console.WriteLine("Startup parameter overrode REST port.");
|
Console.WriteLine("Startup parameter overrode REST port.");
|
||||||
|
|
||||||
}
|
}
|
||||||
|
if ((parms[i].ToLower() == "-maxplayers")||(parms[i].ToLower() == "-players"))
|
||||||
|
{
|
||||||
|
Config.MaxSlots = Convert.ToInt32(parms[++i]);
|
||||||
|
Console.WriteLine("Startup parameter overrode maximum player slot configuration value.");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue