AI will now defend MCV as if it was a harvester or a building.
Adjusted comments.
This commit is contained in:
@@ -1257,8 +1257,8 @@ namespace OpenRA.Mods.Common.AI
|
|||||||
if (!e.Attacker.Info.HasTraitInfo<ITargetableInfo>())
|
if (!e.Attacker.Info.HasTraitInfo<ITargetableInfo>())
|
||||||
return;
|
return;
|
||||||
|
|
||||||
// Protected harvesters or building
|
// Protected priority assets, MCVs, harvesters and buildings
|
||||||
if ((self.Info.HasTraitInfo<HarvesterInfo>() || self.Info.HasTraitInfo<BuildingInfo>()) &&
|
if ((self.Info.HasTraitInfo<HarvesterInfo>() || self.Info.HasTraitInfo<BuildingInfo>() || self.Info.HasTraitInfo<BaseBuildingInfo>()) &&
|
||||||
Player.Stances[e.Attacker.Owner] == Stance.Enemy)
|
Player.Stances[e.Attacker.Owner] == Stance.Enemy)
|
||||||
{
|
{
|
||||||
defenseCenter = e.Attacker.Location;
|
defenseCenter = e.Attacker.Location;
|
||||||
|
|||||||
Reference in New Issue
Block a user