convert Map.SpawnPoints to int2[]; tidy

This commit is contained in:
Chris Forbes
2011-10-18 20:34:00 +13:00
parent 0f7a744ef7
commit 59fdceb4fd
7 changed files with 23 additions and 14 deletions

View File

@@ -381,7 +381,7 @@ namespace OpenRA.Mods.RA.Server
return true;
int spawnPoint;
if (!int.TryParse(parts[1], out spawnPoint) || spawnPoint < 0 || spawnPoint > server.Map.SpawnPoints.Count())
if (!int.TryParse(parts[1], out spawnPoint) || spawnPoint < 0 || spawnPoint > server.Map.GetSpawnPoints().Length)
{
Log.Write("server", "Invalid spawn point: {0}", parts[1]);
return true;