Check win and loss states

This commit is contained in:
henriquenakashima 2020-09-20 16:45:50 -04:00
parent adc84f9aba
commit 8c641f5524
8 changed files with 69 additions and 7 deletions

View file

@ -17,6 +17,7 @@ public class AIUtils {
nearestDistance = distance;
}
}
if (nearestHeroIndex == -1) return null;
return monsterViewpoint.Heroes[nearestHeroIndex];
}
@ -38,6 +39,7 @@ public class AIUtils {
highestHP = heroHP;
}
}
if (highestHPHeroIndex == -1) return null;
return monsterViewpoint.Heroes[highestHPHeroIndex];
}
}