Prevent a crash in AutoTarget.HasValidTargetPriority
This commit is contained in:
@@ -326,7 +326,7 @@ namespace OpenRA.Mods.Common.Traits
|
|||||||
|
|
||||||
public bool HasValidTargetPriority(Actor self, Player owner, BitSet<TargetableType> targetTypes)
|
public bool HasValidTargetPriority(Actor self, Player owner, BitSet<TargetableType> targetTypes)
|
||||||
{
|
{
|
||||||
if (Stance <= UnitStance.ReturnFire)
|
if (owner == null || Stance <= UnitStance.ReturnFire)
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
return activeTargetPriorities.Any(ati =>
|
return activeTargetPriorities.Any(ati =>
|
||||||
|
|||||||
Reference in New Issue
Block a user