don't just crash when map IDs are missing
spit out a warning
This commit is contained in:
@@ -485,6 +485,11 @@ namespace OpenRA
|
|||||||
for (var i = Bounds.Left; i < Bounds.Right; i++)
|
for (var i = Bounds.Left; i < Bounds.Right; i++)
|
||||||
{
|
{
|
||||||
var tr = MapTiles.Value[i, j];
|
var tr = MapTiles.Value[i, j];
|
||||||
|
if (!tileset.Templates.ContainsKey(tr.Type))
|
||||||
|
{
|
||||||
|
Console.WriteLine("Unknown Tile ID {0}".F(tr.Type));
|
||||||
|
continue;
|
||||||
|
}
|
||||||
var template = tileset.Templates[tr.Type];
|
var template = tileset.Templates[tr.Type];
|
||||||
if (!template.PickAny)
|
if (!template.PickAny)
|
||||||
continue;
|
continue;
|
||||||
|
|||||||
Reference in New Issue
Block a user