Remove Resupply re-queueing hack from Aircraft
By preventing that other traits can remotely cancel Resupply or ReturnToBase.
This commit is contained in:
@@ -116,9 +116,16 @@ namespace OpenRA.Mods.Common.Traits
|
||||
if (currentTransform == null)
|
||||
self.QueueActivity(order.Queued, activity);
|
||||
}
|
||||
else if (order.OrderString == "Stop")
|
||||
{
|
||||
// We don't want Stop orders from traits other than Mobile or Aircraft to cancel Resupply activity.
|
||||
// Resupply is always either the main activity or a child of ReturnToBase.
|
||||
// TODO: This should generally only cancel activities queued by this trait.
|
||||
if (self.CurrentActivity == null || self.CurrentActivity is Resupply || self.CurrentActivity is ReturnToBase)
|
||||
return;
|
||||
|
||||
if (order.OrderString == "Stop")
|
||||
self.CancelActivity();
|
||||
}
|
||||
}
|
||||
|
||||
string IOrderVoice.VoicePhraseForOrder(Actor self, Order order)
|
||||
|
||||
Reference in New Issue
Block a user