This commit is contained in:
Paul Chote
2010-08-15 15:34:27 +12:00
parent 58fb7178ad
commit 10ea035b42
2 changed files with 5 additions and 0 deletions

View File

@@ -48,6 +48,7 @@ namespace OpenRA.Mods.RA
.SkipWhile(p => resLayer.GetResource(p) == resourceType && resLayer.IsFull(p.X, p.Y))
.Cast<int2?>().FirstOrDefault();
// Todo: Valid terrain should be specified in the resource
if (cell != null &&
(resLayer.GetResource(cell.Value) == resourceType || resLayer.GetResource(cell.Value) == null) &&
self.World.IsCellBuildable(cell.Value, false))