We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 7ea1139 commit 8f539bbCopy full SHA for 8f539bb
1 file changed
src/main/java/bwapi/Unit.java
@@ -311,10 +311,11 @@ public int getBottom() {
311
* @see #getInitialHitPoints
312
*/
313
public int getHitPoints() {
314
+ int hitpoints = self().hitPoints.get();
315
if (game.isLatComEnabled() && self().hitPoints.valid(game.getFrameCount())) {
- return self().hitPoints.get();
316
+ return hitpoints + self().hitPoints.get();
317
}
- return unitData.getHitPoints();
318
+ return hitpoints;
319
320
321
/**
0 commit comments