Throw an exception at load when a map has more than 64 players
This commit is contained in:
committed by
Matthias Mailänder
parent
daa8c74c37
commit
3674583053
@@ -331,6 +331,9 @@ namespace OpenRA
|
||||
throw new InvalidDataException("Map format {0} is not supported.\n File: {1}".F(MapFormat, package.Name));
|
||||
|
||||
PlayerDefinitions = MiniYaml.NodesOrEmpty(yaml, "Players");
|
||||
if (PlayerDefinitions.Count > 64)
|
||||
throw new InvalidDataException("Maps must not define more than 64 players.\n File: {0}".F(package.Name));
|
||||
|
||||
ActorDefinitions = MiniYaml.NodesOrEmpty(yaml, "Actors");
|
||||
|
||||
Grid = modData.Manifest.Get<MapGrid>();
|
||||
|
||||
Reference in New Issue
Block a user