Check for dead destination helipad in HeliReturnToBase

This commit is contained in:
Oliver Brakmann
2017-04-17 19:31:53 +02:00
parent ff8f204cac
commit b50f15c645

View File

@@ -43,12 +43,12 @@ namespace OpenRA.Mods.Common.Activities
if (IsCanceled)
return NextActivity;
if (dest == null || Reservable.IsReserved(dest))
if (dest == null || dest.IsDead || Reservable.IsReserved(dest))
dest = ChooseHelipad(self);
var initialFacing = heli.Info.InitialFacing;
if (dest == null)
if (dest == null || dest.IsDead)
{
var rearmBuildings = heli.Info.RearmBuildings;
var nearestHpad = self.World.ActorsHavingTrait<Reservable>()