- bugfix for new AI repair logic to properly detect damaged castle type units

This commit is contained in:
Mark Vejvoda 2011-05-01 03:23:15 +00:00
parent 700e768b0f
commit ae9d20a6cf
1 changed files with 1 additions and 1 deletions

View File

@ -113,7 +113,7 @@ bool AiRuleRepair::test(){
if(pt != NULL) {
const UnitType *ut = dynamic_cast<const UnitType *>(pt);
if( ut != NULL && ut->hasCommandClass(ccHarvest) == true &&
ut->getStoredResourceCount() > 0) {
u->getType()->getStoredResourceCount() > 0) {
unitCanProduceWorker = true;
}
}