Message strings added to language files.

This commit is contained in:
Greysa
2026-05-23 21:22:28 +03:00
committed by Asdow
parent ead2932316
commit e1c8bee1d1
10 changed files with 54 additions and 20 deletions
+10 -20
View File
@@ -3879,7 +3879,7 @@ BOOLEAN AutoReload( SOLDIERTYPE * pSoldier, bool aReloadEvenIfNotEmpty )
// Flugente: check for underbarrel weapons and use that object if necessary
pObj = pSoldier->GetUsedWeapon( &(pSoldier->inv[HANDPOS]) );
if (pSoldier->IsValidSecondHandShotForReloadingPurposes()) //check for valid second hand weapon for reloading purposes (ie, not a launcher or something that doesn't use ammo)
if (pSoldier->IsValidSecondHandShotForReloadingPurposes()) //check for valid second hand weapon for reloading purposes (something that doesn't use ammo)
{
pObj2 = pSoldier->GetUsedWeapon( &(pSoldier->inv[SECONDHANDPOS]) );
}
@@ -3888,7 +3888,6 @@ BOOLEAN AutoReload( SOLDIERTYPE * pSoldier, bool aReloadEvenIfNotEmpty )
pObj2 = NULL;
}
// Greysa: Check if weapon is jammed and unjam it first
// Greysa: need to implement and test duel wield unjamming
if ((*pObj)[0]->data.gun.bGunAmmoStatus < 0 || ((pObj2 != NULL) && (*pObj2)[0]->data.gun.bGunAmmoStatus < 0))
{
if ((*pObj)[0]->data.gun.bGunAmmoStatus < 0)
@@ -3907,9 +3906,7 @@ BOOLEAN AutoReload( SOLDIERTYPE * pSoldier, bool aReloadEvenIfNotEmpty )
int iResult = SkillCheck(pSoldier, UNJAM_GUN_CHECK, bChanceMod);
// sevenfm: AI always unjams successfully
// Greysa: no AI check required here
if (iResult > 0)// || !(pSoldier->flags.uiStatusFlags & SOLDIER_PC))
if (iResult > 0)
{
// yay! unjammed the gun
(*pObj)[0]->data.gun.bGunAmmoStatus *= -1;
@@ -3926,19 +3923,15 @@ BOOLEAN AutoReload( SOLDIERTYPE * pSoldier, bool aReloadEvenIfNotEmpty )
PlayJA2Sample(Weapon[Item[pObj->usItem].ubClassIndex].ManualReloadSound, RATE_11025, SoundVolume(HIGHVOLUME, pSoldier->sGridNo), 1, SoundDir(pSoldier->sGridNo));
ScreenMsg(FONT_MCOLOR_LTYELLOW, MSG_INTERFACE, L"%s unjammed %s.", pSoldier->GetName(), ItemNames[pObj->usItem]);
// merc voice feedback?
// Greysa: We want to skip reloading if we attempted to unjam, regardless of outcome
//return FALSE; // Greysa: Do we return false or true here to skip rest of reload? I think true, but test this! Also, need to figure out animation
}
else
{
ScreenMsg(FONT_MCOLOR_LTYELLOW, MSG_INTERFACE, L"%s failed to unjam %s.", pSoldier->GetName(), ItemNames[pObj->usItem]);
//return FALSE;
}
}
else
{
ScreenMsg(FONT_MCOLOR_LTYELLOW, MSG_INTERFACE, L"%s does not have enough APs to unjam %s.", pSoldier->GetName(), ItemNames[pObj->usItem]);
//return FALSE;
}
}
if ((pObj2 != NULL) && (*pObj2)[0]->data.gun.bGunAmmoStatus < 0)
@@ -3956,9 +3949,7 @@ BOOLEAN AutoReload( SOLDIERTYPE * pSoldier, bool aReloadEvenIfNotEmpty )
int iResult = SkillCheck(pSoldier, UNJAM_GUN_CHECK, bChanceMod);
// sevenfm: AI always unjams successfully
// Greysa: no AI check required here
if (iResult > 0)// || !(pSoldier->flags.uiStatusFlags & SOLDIER_PC))
if (iResult > 0)
{
// yay! unjammed the gun
(*pObj2)[0]->data.gun.bGunAmmoStatus *= -1;
@@ -3973,24 +3964,23 @@ BOOLEAN AutoReload( SOLDIERTYPE * pSoldier, bool aReloadEvenIfNotEmpty )
DirtyMercPanelInterface(pSoldier, DIRTYLEVEL2); // Greysa: what does this do?
PlayJA2Sample(Weapon[Item[pObj2->usItem].ubClassIndex].ManualReloadSound, RATE_11025, SoundVolume(HIGHVOLUME, pSoldier->sGridNo), 1, SoundDir(pSoldier->sGridNo));
ScreenMsg(FONT_MCOLOR_LTYELLOW, MSG_INTERFACE, L"%s unjammed %s.", pSoldier->GetName(), ItemNames[pObj2->usItem]);
ScreenMsg(FONT_MCOLOR_LTYELLOW, MSG_INTERFACE, Message[STR_UNJAMMED], pSoldier->GetName(), ItemNames[pObj2->usItem]);
// merc voice feedback?
// Greysa: We want to skip reloading if we attempted to unjam, regardless of outcome
return FALSE; // Greysa: Do we return false or true here to skip rest of reload? I think true, but test this! Also, need to figure out animation
return FALSE; //do I need this?
}
else
{
ScreenMsg(FONT_MCOLOR_LTYELLOW, MSG_INTERFACE, L"%s failed to unjam %s.", pSoldier->GetName(), ItemNames[pObj2->usItem]);
return FALSE;
ScreenMsg(FONT_MCOLOR_LTYELLOW, MSG_INTERFACE, Message[STR_FAILED_UNJAM], pSoldier->GetName(), ItemNames[pObj2->usItem]);
return FALSE; //do I need this?
}
}
else
{
ScreenMsg(FONT_MCOLOR_LTYELLOW, MSG_INTERFACE, L"%s does not have enough APs to unjam %s.", pSoldier->GetName(), ItemNames[pObj2->usItem]);
return FALSE;
ScreenMsg(FONT_MCOLOR_LTYELLOW, MSG_INTERFACE, Message[STR_NO_AP_NO_UNJAM], pSoldier->GetName(), ItemNames[pObj2->usItem]);
return FALSE; //do I need this?
}
}
return FALSE;
return FALSE; // Greysa: We want to skip reloading if we attempted to unjam, regardless of outcome. Return value doesn't seem to matter as there doesn't seem to be any actual checks on the returned value
}
//<SB> manual recharge
+5
View File
@@ -2361,6 +2361,11 @@ CHAR16 Message[][STRING_LENGTH] =
L"没有能够训练的民兵。", //L"No militia that can be drilled present.",
L"%s 已经完全的探索了 %s。", //L"%s has fully explored %s."
// The first %s is a merc name and the second %s is an item name
L"%s unjammed %s.",
L"%s failed to unjam %s.",
L"%s does not have enough APs to unjam %s."
};
// the country and its noun in the game
+5
View File
@@ -2360,6 +2360,11 @@ CHAR16 Message[][STRING_LENGTH] =
L"No militia that can be drilled present.",
L"%s has fully explored %s.", // TODO.Translate
// The first %s is a merc name and the second %s is an item name
L"%s unjammed %s.",
L"%s failed to unjam %s.",
L"%s does not have enough APs to unjam %s."
};
// the country and its noun in the game
+5
View File
@@ -2361,6 +2361,11 @@ CHAR16 Message[][STRING_LENGTH] =
L"No militia that can be drilled present.",
L"%s has fully explored %s.",
// The first %s is a merc name and the second %s is an item name
L"%s unjammed %s.",
L"%s failed to unjam %s.",
L"%s does not have enough APs to unjam %s."
};
// the country and its noun in the game
+5
View File
@@ -2369,6 +2369,11 @@ CHAR16 Message[][STRING_LENGTH] =
L"No militia that can be drilled present.",
L"%s has fully explored %s.", // TODO.Translate
// The first %s is a merc name and the second %s is an item name
L"%s unjammed %s.",
L"%s failed to unjam %s.",
L"%s does not have enough APs to unjam %s."
};
// the country and its noun in the game // TODO.Translate
+5
View File
@@ -2403,6 +2403,11 @@ CHAR16 Message[][STRING_LENGTH] =
L"No militia that can be drilled present.",
L"%s hat %s vollständig erkundet.",
// The first %s is a merc name and the second %s is an item name
L"%s unjammed %s.",
L"%s failed to unjam %s.",
L"%s does not have enough APs to unjam %s."
};
// the country and its noun in the game
+5
View File
@@ -2355,6 +2355,11 @@ CHAR16 Message[][STRING_LENGTH] =
L"No militia that can be drilled present.",
L"%s has fully explored %s.", // TODO.Translate
// The first %s is a merc name and the second %s is an item name
L"%s unjammed %s.",
L"%s failed to unjam %s.",
L"%s does not have enough APs to unjam %s."
};
// the country and its noun in the game
+5
View File
@@ -2367,6 +2367,11 @@ CHAR16 Message[][STRING_LENGTH] =
L"No militia that can be drilled present.",
L"%s has fully explored %s.", // TODO.Translate
// The first %s is a merc name and the second %s is an item name
L"%s unjammed %s.",
L"%s failed to unjam %s.",
L"%s does not have enough APs to unjam %s."
};
// the country and its noun in the game
+5
View File
@@ -2361,6 +2361,11 @@ CHAR16 Message[][STRING_LENGTH] =
L"No militia that can be drilled present.",
L"%s has fully explored %s.", // TODO.Translate
// The first %s is a merc name and the second %s is an item name
L"%s unjammed %s.",
L"%s failed to unjam %s.",
L"%s does not have enough APs to unjam %s."
};
// the country and its noun in the game
+4
View File
@@ -612,6 +612,10 @@ enum
STR_ASSIGNMENT_EXPLORATION_DONE,
STR_UNJAMMED,
STR_FAILED_UNJAM,
STR_NO_AP_NO_UNJAM,
TEXT_NUM_STR_MESSAGE,
};