From 813779679c40323d29aaa6cb334210e3944d5c99 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Sat, 6 Sep 2014 18:26:01 +0300 Subject: Use skillpopup in skills window. --- src/gui/widgets/skillinfo.cpp | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) (limited to 'src/gui/widgets/skillinfo.cpp') diff --git a/src/gui/widgets/skillinfo.cpp b/src/gui/widgets/skillinfo.cpp index 721c4c98e..01cb0cb16 100644 --- a/src/gui/widgets/skillinfo.cpp +++ b/src/gui/widgets/skillinfo.cpp @@ -38,7 +38,7 @@ SkillInfo::SkillInfo() : skillLevel(), skillExp(), - skillMana(), + skillEffect(), useButton(), progress(0.0F), color(), @@ -94,10 +94,18 @@ void SkillInfo::update() skillLevel = strprintf(_("Lvl: %d"), baseLevel); } + if (sp) - skillMana = strprintf(_("Mana: -%d"), sp); + skillEffect = strprintf(_("Mana: -%d"), sp); else - skillMana.clear(); + skillEffect.clear(); + + if (range > 0) + { + if (!skillEffect.empty()) + skillEffect.append(" / "); + skillEffect.append(strprintf(_("Range: %d"), range)); + } level = baseLevel; skillLevelWidth = -1; -- cgit v1.2.3-70-g09d2