Add missing carryall checks

This commit is contained in:
Gustas
2023-05-21 15:02:27 +03:00
committed by Pavel Penev
parent a69417f0a6
commit c7e0bc4c08
3 changed files with 13 additions and 8 deletions

View File

@@ -160,7 +160,7 @@ namespace OpenRA.Mods.Common.Activities
protected override void OnFirstRun(Actor self)
{
// The cargo might have become invalid while we were moving towards it.
if (cargo == null || cargo.IsDead || carryable.IsTraitDisabled || !cargo.AppearsFriendlyTo(self))
if (cargo == null || cargo.IsDead || carryable.IsTraitDisabled || carryall.Carryable != cargo || !cargo.AppearsFriendlyTo(self))
return;
self.World.AddFrameEndTask(w =>