Better power bar rendering of android

This commit is contained in:
DBotThePony 2021-08-19 11:31:54 +07:00
parent 6cc17216a3
commit e9401115d6
Signed by: DBot
GPG Key ID: DCC23B5715498507

View File

@ -108,8 +108,9 @@ public class AndroidGui {
// Stack, x, y, blitOffset?, (float) image_x, (float) image_y, rect_x, rect_y, total_image_width, total_image_height
// Stack, x, y, image_x, image_y, rect_x, rect_y
gui.blit(event.getMatrixStack(), left, top, 0, y_offset, 80, 9);
int shift_left = (int) Math.ceil(level * 79f - 0.5f);
gui.blit(event.getMatrixStack(), left + 79 - shift_left, top, 0, y_offset + 9, shift_left, 9);
gui.blit(event.getMatrixStack(), left + 79 - shift_left, top, 79 - shift_left, y_offset + 9, shift_left, 9);
}
}
}