1
0
forked from 0ad/0ad

petra: fix number of defenders against champion elephant which can be used as siege unit

This was SVN commit r19852.
This commit is contained in:
mimo 2017-06-30 16:41:29 +00:00
parent f6ca98450b
commit dca572fbcd

View File

@ -43,7 +43,7 @@ m.DefenseArmy.prototype.assignUnit = function (gameState, entID)
// already enough units against it
if (this.assignedAgainst[id].length > 8 ||
(this.assignedAgainst[id].length > 5 && !eEnt.hasClass("Hero") && !eEnt.hasClass("Siege")))
this.assignedAgainst[id].length > 5 && !eEnt.hasClass("Hero") && !m.isSiegeUnit(eEnt))
continue;
let dist = API3.SquareVectorDistance(ent.position(), eEnt.position());