summaryrefslogtreecommitdiff
path: root/src/net/eathena
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2015-02-13 19:38:00 +0300
committerAndrei Karas <akaras@inbox.ru>2015-02-13 19:38:32 +0300
commit24751878f50765a94319e55c7017be36e91756c6 (patch)
treef5035b28b1d30ae2b9d7f06ac6eb0327a4fe756f /src/net/eathena
parent71a596747c6f31c0cd010b6cc4522f8ed717d38b (diff)
downloadplus-24751878f50765a94319e55c7017be36e91756c6.tar.gz
plus-24751878f50765a94319e55c7017be36e91756c6.tar.bz2
plus-24751878f50765a94319e55c7017be36e91756c6.tar.xz
plus-24751878f50765a94319e55c7017be36e91756c6.zip
Improve skill error messages.
Diffstat (limited to 'src/net/eathena')
-rw-r--r--src/net/eathena/skillhandler.cpp104
1 files changed, 50 insertions, 54 deletions
diff --git a/src/net/eathena/skillhandler.cpp b/src/net/eathena/skillhandler.cpp
index 03dce353b..64841c585 100644
--- a/src/net/eathena/skillhandler.cpp
+++ b/src/net/eathena/skillhandler.cpp
@@ -302,66 +302,62 @@ void SkillHandler::processSkillFailed(Net::MessageIn &msg)
txt = info->errorText;
else
txt = strprintf(_("Unknown skill error: %d"), bskill);
- txt.append(" ");
-
- switch (reason)
- {
- case RFAIL_SKILLDEP:
- // TRANSLATORS: error message
- txt.append(_("You have not yet reached a high enough lvl!"));
- break;
- case RFAIL_INSUFHP:
- // TRANSLATORS: error message
- txt.append(_("Insufficient HP!"));
- break;
- case RFAIL_INSUFSP:
- // TRANSLATORS: error message
- txt.append(_("Insufficient SP!"));
- break;
- case RFAIL_NOMEMO:
- // TRANSLATORS: error message
- txt.append(_("You have no memos!"));
- break;
- case RFAIL_SKILLDELAY:
- // TRANSLATORS: error message
- txt.append(_("You cannot do that right now!"));
- break;
- case RFAIL_ZENY:
- // TRANSLATORS: error message
- txt.append(_("Seems you need more money... ;-)"));
- break;
- case RFAIL_WEAPON:
- // TRANSLATORS: error message
- txt.append(_("You cannot use this skill with that "
- "kind of weapon!"));
- break;
- case RFAIL_REDGEM:
- // TRANSLATORS: error message
- txt.append(_("You need another red gem!"));
- break;
- case RFAIL_BLUEGEM:
- // TRANSLATORS: error message
- txt.append(_("You need another blue gem!"));
- break;
- case RFAIL_OVERWEIGHT:
- // TRANSLATORS: error message
- txt.append(_("You're carrying to much to do this!"));
- break;
- default:
- // TRANSLATORS: error message
- txt.append(_("Huh? What's that?"));
- logger->log("QQQ SMSG_SKILL_FAILED: reason "
- + toString(reason));
- break;
- }
}
else
{
SkillInfo *const info = skillDialog->getSkill(skillId);
if (info)
- txt = info->errorText;
+ txt = info->errorText + ".";
else
- txt = strprintf(_("Unknown skill error: %d"), skillId);
+ txt = strprintf(_("Unknown skill error: %d."), skillId);
+ }
+
+ txt.append(" ");
+ switch (reason)
+ {
+ case RFAIL_SKILLDEP:
+ // TRANSLATORS: error message
+ txt.append(_("You have not yet reached a high enough lvl!"));
+ break;
+ case RFAIL_INSUFHP:
+ // TRANSLATORS: error message
+ txt.append(_("Insufficient HP!"));
+ break;
+ case RFAIL_INSUFSP:
+ // TRANSLATORS: error message
+ txt.append(_("Insufficient SP!"));
+ break;
+ case RFAIL_NOMEMO:
+ // TRANSLATORS: error message
+ txt.append(_("You have no memos!"));
+ break;
+ case RFAIL_SKILLDELAY:
+ // TRANSLATORS: error message
+ txt.append(_("You cannot do that right now!"));
+ break;
+ case RFAIL_ZENY:
+ // TRANSLATORS: error message
+ txt.append(_("Seems you need more money... ;-)"));
+ break;
+ case RFAIL_WEAPON:
+ // TRANSLATORS: error message
+ txt.append(_("You cannot use this skill with that "
+ "kind of weapon!"));
+ break;
+ case RFAIL_REDGEM:
+ // TRANSLATORS: error message
+ txt.append(_("You need another red gem!"));
+ break;
+ case RFAIL_BLUEGEM:
+ // TRANSLATORS: error message
+ txt.append(_("You need another blue gem!"));
+ break;
+ case RFAIL_OVERWEIGHT:
+ // TRANSLATORS: error message
+ txt.append(_("You're carrying to much to do this!"));
+ break;
+ default:
+ break;
}
NotifyManager::notify(NotifyTypes::SKILL_FAIL_MESSAGE, txt);