Ignore self and actors not at ground level in Parachutable.OnLanded

This commit is contained in:
abcdefg30
2019-10-13 22:36:29 +02:00
committed by Paul Chote
parent dd26253905
commit a909a3e692

View File

@@ -102,11 +102,11 @@ namespace OpenRA.Mods.Common.Traits
if (positionable.CanEnterCell(cell, self))
return;
if (IgnoreActor != null && !self.World.ActorMap.GetActorsAt(cell).Any(a => a != IgnoreActor))
if (IgnoreActor != null && !self.World.ActorMap.GetActorsAt(cell)
.Any(a => a != IgnoreActor && a != self && self.World.Map.DistanceAboveTerrain(a.CenterPosition) == WDist.Zero))
return;
var onWater = info.WaterTerrainTypes.Contains(self.World.Map.GetTerrainInfo(cell).Type);
var sound = onWater ? info.WaterImpactSound : info.GroundImpactSound;
Game.Sound.Play(SoundType.World, sound, self.CenterPosition);