Added Gates
FIXUP: account for full gate footprint when updating neighbours. FIXUP: gate-wall connection adjacency yaml.
This commit is contained in:
@@ -220,12 +220,14 @@ namespace OpenRA.Mods.Common.Activities
|
||||
|
||||
var nextCell = path[path.Count - 1];
|
||||
|
||||
var containsTemporaryBlocker = WorldUtils.ContainsTemporaryBlocker(self.World, nextCell, self);
|
||||
|
||||
// Next cell in the move is blocked by another actor
|
||||
if (!mobile.CanMoveFreelyInto(nextCell, ignoredActor, true))
|
||||
if (containsTemporaryBlocker || !mobile.CanMoveFreelyInto(nextCell, ignoredActor, true))
|
||||
{
|
||||
// Are we close enough?
|
||||
var cellRange = nearEnough.Length / 1024;
|
||||
if ((mobile.ToCell - destination.Value).LengthSquared <= cellRange * cellRange)
|
||||
if (!containsTemporaryBlocker && (mobile.ToCell - destination.Value).LengthSquared <= cellRange * cellRange)
|
||||
{
|
||||
path.Clear();
|
||||
return null;
|
||||
|
||||
Reference in New Issue
Block a user