diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/being/being.cpp | 20 |
1 files changed, 7 insertions, 13 deletions
diff --git a/src/being/being.cpp b/src/being/being.cpp index ed124b472..2401e6cc3 100644 --- a/src/being/being.cpp +++ b/src/being/being.cpp @@ -4268,8 +4268,7 @@ void Being::drawPortalSpriteAt(Graphics *restrict const graphics, graphics->setColor(userPalette-> getColorWithAlpha(UserColorId::PORTAL_HIGHLIGHT)); - graphics->fillRectangle(Rect(x, y, - mapTileSize, mapTileSize)); + graphics->fillRectangle(Rect(x, y, mapTileSize, mapTileSize)); if (mDrawHotKeys && !mName.empty()) { @@ -4305,7 +4304,7 @@ void Being::drawHpBar(Graphics *restrict const graphics, else if (maxHP != damage) { p = static_cast<float>(maxHP) - / static_cast<float>(maxHP - damage); + / static_cast<float>(maxHP - damage); } else { @@ -4324,15 +4323,13 @@ void Being::drawHpBar(Graphics *restrict const graphics, || (hp == 0 && maxHP == damage)) { graphics->setColor(userPalette->getColorWithAlpha(color1)); - graphics->fillRectangle(Rect( - x, y, dx, height)); + graphics->fillRectangle(Rect(x, y, dx, height)); return; } else if (width - dx <= 0) { graphics->setColor(userPalette->getColorWithAlpha(color2)); - graphics->fillRectangle(Rect( - x, y, width, height)); + graphics->fillRectangle(Rect(x, y, width, height)); return; } } @@ -4342,22 +4339,19 @@ void Being::drawHpBar(Graphics *restrict const graphics, if (hp == maxHP) { graphics->setColor(userPalette->getColorWithAlpha(color1)); - graphics->fillRectangle(Rect( - x, y, dx, height)); + graphics->fillRectangle(Rect(x, y, dx, height)); return; } else if (width - dx <= 0) { graphics->setColor(userPalette->getColorWithAlpha(color2)); - graphics->fillRectangle(Rect( - x, y, width, height)); + graphics->fillRectangle(Rect(x, y, width, height)); return; } } graphics->setColor(userPalette->getColorWithAlpha(color1)); - graphics->fillRectangle(Rect( - x, y, dx, height)); + graphics->fillRectangle(Rect(x, y, dx, height)); graphics->setColor(userPalette->getColorWithAlpha(color2)); graphics->fillRectangle(Rect(x + dx, y, width - dx, height)); |