diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/gui/skilldialog.cpp | 8 | ||||
-rw-r--r-- | src/localplayer.cpp | 16 | ||||
-rw-r--r-- | src/resources/colordb.cpp | 4 | ||||
-rw-r--r-- | src/resources/emotedb.cpp | 4 | ||||
-rw-r--r-- | src/resources/itemdb.cpp | 6 | ||||
-rw-r--r-- | src/resources/monsterdb.cpp | 2 |
6 files changed, 24 insertions, 16 deletions
diff --git a/src/gui/skilldialog.cpp b/src/gui/skilldialog.cpp index 4ee674325..430705b1d 100644 --- a/src/gui/skilldialog.cpp +++ b/src/gui/skilldialog.cpp @@ -382,8 +382,8 @@ void SkillDialog::loadSkills(const std::string &file) SkillInfo *skill = new SkillInfo; skill->id = 1; - skill->name = "basic"; - skill->dispName = "Skill: basic, Id: 1"; + skill->name = _("basic"); + skill->dispName = _("Skill: basic, Id: 1"); skill->setIcon(""); skill->modifiable = true; skill->visible = true; @@ -428,14 +428,14 @@ void SkillDialog::loadSkills(const std::string &file) if (xmlNameEqual(node, "skill")) { int id = atoi(XML::getProperty(node, "id", "-1").c_str()); - std::string name = XML::getProperty(node, "name", + std::string name = XML::langProperty(node, "name", strprintf(_("Skill %d"), id)); std::string icon = XML::getProperty(node, "icon", ""); SkillInfo *skill = new SkillInfo; skill->id = static_cast<short unsigned>(id); skill->name = name; - skill->dispName = strprintf("Skill: %s, Id: %d", + skill->dispName = strprintf(_("Skill: %s, Id: %d"), name.c_str(), skill->id); skill->setIcon(icon); skill->modifiable = false; diff --git a/src/localplayer.cpp b/src/localplayer.cpp index 9fa755e54..81c988d53 100644 --- a/src/localplayer.cpp +++ b/src/localplayer.cpp @@ -1714,20 +1714,28 @@ void LocalPlayer::processEvent(Mana::Channels channel, if (!mMessages.empty()) { MessagePair pair = mMessages.back(); - if (pair.first.find(" xp") == pair.first.size() - 3) + // TRANSLATORS: this is normal experience + if (pair.first.find(strprintf(" %s", + _("xp"))) == pair.first.size() - 3) { mMessages.pop_back(); - pair.first += ", " + toString(change) + " job"; + // TRANSLATORS: this is job experience + pair.first += strprintf (", %d %s", + change, _("job")); mMessages.push_back(pair); } else { - addMessageToQueue(toString(change) + " job"); + // TRANSLATORS: this is job experience + addMessageToQueue(strprintf("%d %s", + change, _("job"))); } } else { - addMessageToQueue(toString(change) + " job"); + // TRANSLATORS: this is job experience + addMessageToQueue(strprintf( + "%d %s", change, _("job"))); } } } diff --git a/src/resources/colordb.cpp b/src/resources/colordb.cpp index 2ddf27ac3..66c8de0a2 100644 --- a/src/resources/colordb.cpp +++ b/src/resources/colordb.cpp @@ -95,7 +95,7 @@ void ColorDB::loadHair() if (colors.find(id) != colors.end()) logger->log("ColorDB: Redefinition of dye ID %d", id); - colors[id] = ItemColor(id, XML::getProperty(node, "name", ""), + colors[id] = ItemColor(id, XML::langProperty(node, "name", ""), XML::getProperty(node, hairXml ? "value" : "dye", "#FFFFFF")); } } @@ -135,7 +135,7 @@ void ColorDB::loadColorLists() if (xmlNameEqual(colorNode, "color")) { ItemColor c(XML::getProperty(colorNode, "id", -1), - XML::getProperty(colorNode, "name", ""), + XML::langProperty(colorNode, "name", ""), XML::getProperty(colorNode, "value", "")); if (c.id > -1) colors[c.id] = c; diff --git a/src/resources/emotedb.cpp b/src/resources/emotedb.cpp index 07e192cd4..aba020261 100644 --- a/src/resources/emotedb.cpp +++ b/src/resources/emotedb.cpp @@ -93,7 +93,7 @@ void EmoteDB::load() spriteNode->xmlChildrenNode->content); currentSprite->sprite = AnimatedSprite::load(file, XML::getProperty(spriteNode, "variant", 0)); - currentSprite->name = XML::getProperty(spriteNode, "name", ""); + currentSprite->name = XML::langProperty(spriteNode, "name", ""); currentInfo->sprites.push_back(currentSprite); } else if (xmlNameEqual(spriteNode, "particlefx")) @@ -147,7 +147,7 @@ void EmoteDB::load() spriteNode->xmlChildrenNode->content); currentSprite->sprite = AnimatedSprite::load(file, XML::getProperty(spriteNode, "variant", 0)); - currentSprite->name = XML::getProperty(spriteNode, "name", ""); + currentSprite->name = XML::langProperty(spriteNode, "name", ""); currentInfo->sprites.push_back(currentSprite); } else if (xmlNameEqual(spriteNode, "particlefx")) diff --git a/src/resources/itemdb.cpp b/src/resources/itemdb.cpp index 5fa68a88f..e81700ecc 100644 --- a/src/resources/itemdb.cpp +++ b/src/resources/itemdb.cpp @@ -202,10 +202,10 @@ void ItemDB::load() int weight = XML::getProperty(node, "weight", 0); int view = XML::getProperty(node, "view", 0); - std::string name = XML::getProperty(node, "name", ""); + std::string name = XML::langProperty(node, "name", ""); std::string image = XML::getProperty(node, "image", ""); std::string floor = XML::getProperty(node, "floor", ""); - std::string description = XML::getProperty(node, "description", ""); + std::string description = XML::langProperty(node, "description", ""); std::string attackAction = XML::getProperty(node, "attack-action", ""); std::string drawBefore = XML::getProperty(node, "drawBefore", ""); std::string drawAfter = XML::getProperty(node, "drawAfter", ""); @@ -316,7 +316,7 @@ void ItemDB::load() effect += " / "; effect += strprintf(it->format.c_str(), value); } - std::string temp = XML::getProperty(node, "effect", ""); + std::string temp = XML::langProperty(node, "effect", ""); if (!effect.empty() && !temp.empty()) effect += " / "; effect += temp; diff --git a/src/resources/monsterdb.cpp b/src/resources/monsterdb.cpp index 9d295db35..2c9448fc3 100644 --- a/src/resources/monsterdb.cpp +++ b/src/resources/monsterdb.cpp @@ -80,7 +80,7 @@ void MonsterDB::load() | Map::BLOCKMASK_CHARACTER | Map::BLOCKMASK_MONSTER); currentInfo->setBlockType(Map::BLOCKTYPE_MONSTER); - currentInfo->setName(XML::getProperty( + currentInfo->setName(XML::langProperty( monsterNode, "name", _("unnamed"))); currentInfo->setTargetCursorSize(XML::getProperty(monsterNode, |