Minor dialogue and UI bug fixing
This commit is contained in:
1 parent
fff5a9d4aa
commit
db456bde09
11 files changed
+2350
-21
No files matched your search
@@ -1059,6 +1059,7 @@ namespace ZL {
|
||||
|
||||
void MenuManager::setDarklandsMode(bool enabled)
|
||||
{
|
||||
std::cout << "MenuManager::setDarklandsMode called" << std::endl;
|
||||
currentIsDarklands_ = enabled;
|
||||
|
||||
if (currentLocationName_ == "uni_interior") {
|
||||
@@ -1149,8 +1150,14 @@ namespace ZL {
|
||||
}
|
||||
|
||||
void MenuManager::applyCurrentHealthBar() {
|
||||
std::cout << "MenuManager::applyCurrentHealthBar called step 1" << std::endl;
|
||||
std::cout << "currentPlayerMaxHp_ is " << currentPlayerMaxHp_ << std::endl;
|
||||
if (currentPlayerMaxHp_ <= 0.f) return;
|
||||
std::cout << "MenuManager::applyCurrentHealthBar called step 2" << std::endl;
|
||||
std::cout << "currentPlayerHp_ is " << currentPlayerHp_ << std::endl;
|
||||
|
||||
const float fraction = std::clamp(currentPlayerHp_ / currentPlayerMaxHp_, 0.f, 1.f);
|
||||
|
||||
uiManager.setSliderValue("healthBarFill", fraction);
|
||||
std::string hpText = std::to_string(static_cast<int>(currentPlayerHp_)) + "/" +
|
||||
std::to_string(static_cast<int>(currentPlayerMaxHp_));
|
||||
|
||||
Reference in new issue
Block a user