Rename ActorMap *UnitsAt* occurences to *ActorsAt*
These enumerate actors in general, not just mobile actors (which the term 'unit' usually refers to).
This commit is contained in:
@@ -205,7 +205,7 @@ namespace OpenRA.Mods.Common.Traits
|
||||
void KillUnitsOnBridge()
|
||||
{
|
||||
foreach (var c in footprint.Keys)
|
||||
foreach (var a in self.World.ActorMap.GetUnitsAt(c))
|
||||
foreach (var a in self.World.ActorMap.GetActorsAt(c))
|
||||
if (a.Info.HasTraitInfo<IPositionableInfo>() && !a.Trait<IPositionable>().CanEnterCell(c))
|
||||
a.Kill(self);
|
||||
}
|
||||
|
||||
@@ -85,7 +85,7 @@ namespace OpenRA.Mods.Common.Traits
|
||||
|
||||
if (buildingAtPos == null)
|
||||
{
|
||||
var unitsAtPos = world.ActorMap.GetUnitsAt(pos).Where(a => a.IsInWorld
|
||||
var unitsAtPos = world.ActorMap.GetActorsAt(pos).Where(a => a.IsInWorld
|
||||
&& (a.Owner == p || (allyBuildRadius && a.Owner.Stances[p] == Stance.Ally))
|
||||
&& a.Info.HasTraitInfo<GivesBuildableAreaInfo>());
|
||||
|
||||
|
||||
@@ -24,7 +24,7 @@ namespace OpenRA.Mods.Common.Traits
|
||||
if (world.WorldActor.Trait<BuildingInfluence>().GetBuildingAt(cell) != null)
|
||||
return false;
|
||||
|
||||
if (!bi.AllowInvalidPlacement && world.ActorMap.GetUnitsAt(cell).Any(a => a != toIgnore))
|
||||
if (!bi.AllowInvalidPlacement && world.ActorMap.GetActorsAt(cell).Any(a => a != toIgnore))
|
||||
return false;
|
||||
|
||||
var tile = world.Map.MapTiles.Value[cell];
|
||||
|
||||
Reference in New Issue
Block a user