support for the interior tileSet. trees don't work. mounted all 3 of the tileSet mixen; this means there are name-clashes in some cases.

This commit is contained in:
Bob
2010-01-29 14:19:44 +13:00
parent 5bd6c32aff
commit 95b98a78bb
8 changed files with 838 additions and 13 deletions

View File

@@ -6,7 +6,7 @@ namespace OpenRa.FileFormats
{
public class TileTemplate
{
public int Index;
public int Index; // not valid for `interior` stuff. only used for bridges.
public string Name;
public int2 Size;
public string Bridge;
@@ -36,10 +36,11 @@ namespace OpenRa.FileFormats
p => int.Parse(p.Key.Substring(8)),
p => int.Parse(p.Value)),
Name = section.GetValue("Name", null).ToLowerInvariant(),
Index = int.Parse(section.Name.Substring(3)),
Bridge = section.GetValue("bridge", null),
HP = float.Parse(section.GetValue("hp", "0"))
};
tile.Index = -1;
int.TryParse(section.Name.Substring(3), out tile.Index);
walkability[tile.Name] = tile;
}