diff --git a/logic/Server/GameServer.cs b/logic/Server/GameServer.cs index 2221dc98..7d7a7a06 100755 --- a/logic/Server/GameServer.cs +++ b/logic/Server/GameServer.cs @@ -210,7 +210,7 @@ private uint GetBirthPointIdx(long playerID) // 获取出生点位置 private bool ValidPlayerID(long playerID) { - if (playerID==0 || (1 <= playerID && playerID <= options.ShipCount)) + if (playerID == 0 || (1 <= playerID && playerID <= options.MaxShipCount)) return true; return false; } @@ -307,7 +307,7 @@ public GameServer(ArgumentOptions options) //创建server时先设定待加入对象都是invalid for (int team = 0; team < TeamCount; team++) { - communicationToGameID[team][0]= GameObj.invalidID; // team + communicationToGameID[team][0] = GameObj.invalidID; // team for (int i = 1; i <= options.MaxShipCount; i++) { communicationToGameID[team][i] = GameObj.invalidID; //sweeper diff --git a/logic/Server/Properties/launchSettings.json b/logic/Server/Properties/launchSettings.json index 3259ad2e..ad57284f 100755 --- a/logic/Server/Properties/launchSettings.json +++ b/logic/Server/Properties/launchSettings.json @@ -2,7 +2,7 @@ "profiles": { "Server": { "commandName": "Project", - "commandLineArgs": "--port 8888 --teamCount 1 --homeNum 0 --MaxShipNum 1" + "commandLineArgs": "--port 8888 --teamCount 1 --homeNum 1 --MaxShipNum 1" } } } \ No newline at end of file