Skip to content

Commit

Permalink
Allowing translations of more hard-coded strings - #49
Browse files Browse the repository at this point in the history
  • Loading branch information
grannypron committed Feb 15, 2021
1 parent 916b964 commit 02044ed
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
16 changes: 8 additions & 8 deletions src/UAFWin/CharStatsForm.cpp
Expand Up @@ -315,7 +315,7 @@ void showCharStats(TEXT_FORM *pForm, CHARACTER& dude)
// char age
int charTrueAge = dude.GetAge();
int charCurrAge = dude.GetAdjAge();
temp.Format("%i YEARS", charCurrAge);
temp.Format("%i " + CString(getGameText("YEARS")), charCurrAge);
if (charTrueAge!=charCurrAge)
// prs 20191221 pForm->SetText(STF_age, temp, AdjColor);
pForm->SetText(STF_age, temp, adjColorNum);
Expand All @@ -325,7 +325,7 @@ void showCharStats(TEXT_FORM *pForm, CHARACTER& dude)

// char hitpoints/maxhitpoints
int charTrueHp = dude.GetHitPoints();
pForm->SetText(STF_HITS, "HIT POINTS");
pForm->SetText(STF_HITS, CString(getGameText("HIT POINTS")));
if (charCurrHp!=charTrueHp)
{
temp.Format("%i", charCurrHp);
Expand Down Expand Up @@ -602,7 +602,7 @@ void showCharStats(TEXT_FORM *pForm, CHARACTER& dude)

// strength
//pForm->SetText( STF_STR,"STR ");
abbreviation = abilityData.GetShortName("Strength");
abbreviation = CString(getGameText(abilityData.GetShortName("Strength")));
abbreviation += " ";
abbreviation = abbreviation.Left(8);
pForm->SetText( STF_STR,abbreviation);
Expand Down Expand Up @@ -632,7 +632,7 @@ void showCharStats(TEXT_FORM *pForm, CHARACTER& dude)
charTrueStat = dude.GetPermInt();
IsAdj = (charCurrStat!=charTrueStat);
//pForm->SetText( STF_INT,"INT ");
abbreviation = abilityData.GetShortName("Intelligence");
abbreviation = CString(getGameText(abilityData.GetShortName("Intelligence")));
abbreviation += " ";
abbreviation = abbreviation.Left(8);
pForm->SetText( STF_INT,abbreviation);
Expand All @@ -649,7 +649,7 @@ void showCharStats(TEXT_FORM *pForm, CHARACTER& dude)
charTrueStat = dude.GetPermWis();
IsAdj = (charCurrStat!=charTrueStat);
//pForm->SetText( STF_WIS,"WIS ");
abbreviation = abilityData.GetShortName("Wisdom");
abbreviation = CString(getGameText(abilityData.GetShortName("Wisdom")));
abbreviation += " ";
abbreviation = abbreviation.Left(8);
pForm->SetText( STF_WIS,abbreviation);
Expand All @@ -666,7 +666,7 @@ void showCharStats(TEXT_FORM *pForm, CHARACTER& dude)
charTrueStat = dude.GetPermDex();
IsAdj = (charCurrStat!=charTrueStat);
//pForm->SetText( STF_DEX,"DEX ");
abbreviation = abilityData.GetShortName("Dexterity");
abbreviation = CString(getGameText(abilityData.GetShortName("Dexterity")));
abbreviation += " ";
abbreviation = abbreviation.Left(8);
pForm->SetText( STF_DEX,abbreviation);
Expand All @@ -683,7 +683,7 @@ void showCharStats(TEXT_FORM *pForm, CHARACTER& dude)
charTrueStat = dude.GetPermCon();
IsAdj = (charCurrStat!=charTrueStat);
//pForm->SetText( STF_CON,"CON ");
abbreviation = abilityData.GetShortName("Constitution");
abbreviation = CString(getGameText(abilityData.GetShortName("Constitution")));
abbreviation += " ";
abbreviation = abbreviation.Left(8);
pForm->SetText( STF_CON,abbreviation);
Expand All @@ -700,7 +700,7 @@ void showCharStats(TEXT_FORM *pForm, CHARACTER& dude)
charTrueStat = dude.GetPermCha();
IsAdj = (charCurrStat!=charTrueStat);
//pForm->SetText( STF_CHA,"CHA ");
abbreviation = abilityData.GetShortName("Charisma");
abbreviation = CString(getGameText(abilityData.GetShortName("Charisma")));
abbreviation += " ";
abbreviation = abbreviation.Left(8);
pForm->SetText( STF_CHA,abbreviation);
Expand Down
2 changes: 1 addition & 1 deletion src/UAFWin/Combatants.cpp
Expand Up @@ -5337,7 +5337,7 @@ CString FormatCombatAttackText()
if (msg.GetLength()==0) msg = "attacks";
temp.Format("%s %s %s",
combatData.GetCombatant(dude)->GetName(),
msg,
getGameText(msg),
combatData.GetCombatant(target)->GetName());

return temp;
Expand Down

0 comments on commit 02044ed

Please sign in to comment.