mirror of
https://github.com/1dot13/source.git
synced 2026-09-02 14:36:06 +02:00
- bugfix: Wrong chance to hit calculation on RPG rocket launchers
- bugfix: CTD in German version when using auto fire (-> missing German language strings) - updated German and English language files git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@548 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
@@ -504,7 +504,18 @@ INT32 HandleItem( SOLDIERTYPE *pSoldier, UINT16 usGridNo, INT8 bLevel, UINT16 us
|
||||
sAPCost = CalcTotalAPsToAttack( pSoldier, sTargetGridNo, TRUE, 0 );
|
||||
|
||||
if((__min(pSoldier->bDoAutofire,pSoldier->inv[ pSoldier->ubAttackingHand ].ubGunShotsLeft) - startAuto) > 0 && pSoldier->bTeam == OUR_TEAM)
|
||||
ScreenMsg( FONT_MCOLOR_LTYELLOW, MSG_INTERFACE, gzLateLocalizedString[ 62 ], pSoldier->name, __min(pSoldier->bDoAutofire,pSoldier->inv[ pSoldier->ubAttackingHand ].ubGunShotsLeft) - startAuto );
|
||||
{
|
||||
// More than 1 round
|
||||
if (__min(pSoldier->bDoAutofire,pSoldier->inv[ pSoldier->ubAttackingHand ].ubGunShotsLeft) - startAuto > 1)
|
||||
{
|
||||
ScreenMsg( FONT_MCOLOR_LTYELLOW, MSG_INTERFACE, gzLateLocalizedString[ 62 ], pSoldier->name, __min(pSoldier->bDoAutofire,pSoldier->inv[ pSoldier->ubAttackingHand ].ubGunShotsLeft) - startAuto );
|
||||
}
|
||||
// 1 round
|
||||
else
|
||||
{
|
||||
ScreenMsg( FONT_MCOLOR_LTYELLOW, MSG_INTERFACE, gzLateLocalizedString[ 63 ], pSoldier->name, __min(pSoldier->bDoAutofire,pSoldier->inv[ pSoldier->ubAttackingHand ].ubGunShotsLeft) - startAuto );
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
//ScreenMsg( FONT_MCOLOR_LTYELLOW, MSG_INTERFACE, L"Chance:%d.%d, AvgAps=%f, APs=%d", chanceToMisfire/(diceSides/100),chanceToMisfire%(diceSides/100), avgAPadded,sAPCost-startAPcost);
|
||||
|
||||
@@ -1807,7 +1807,8 @@ void DrawSelectedUIAboveGuy( UINT16 usSoldierID )
|
||||
|
||||
//jones
|
||||
extern void SoldierTooltip(SOLDIERTYPE*);
|
||||
SoldierTooltip(pSoldier);
|
||||
if ( gGameExternalOptions.gfAllowSoldierToolTips )
|
||||
SoldierTooltip(pSoldier);
|
||||
|
||||
SetFont( TINYFONT1 );
|
||||
SetFontBackground( FONT_MCOLOR_BLACK );
|
||||
|
||||
@@ -3003,6 +3003,8 @@ UINT16 PickARandomItem(UINT8 typeIndex, UINT8 maxCoolness, BOOLEAN getMatchingCo
|
||||
usItem = gArmyItemChoices[ typeIndex ].bItemNo[ uiChoice ];
|
||||
|
||||
// WANNE
|
||||
pickItem = FALSE;
|
||||
|
||||
if (usItem >= 0 && Item[usItem].ubCoolness <= maxCoolness && ItemIsLegal(usItem))
|
||||
{
|
||||
// On day
|
||||
|
||||
@@ -402,11 +402,9 @@ void DrawMouseTooltip()
|
||||
extern void DisplayTooltipString( STR16 pStringA, INT16 sX, INT16 sY );
|
||||
extern void j_log(PTR,...);
|
||||
|
||||
// if (!gGameExternalOptions.gfAllowSoldierToolTips) return;
|
||||
|
||||
iX = mouseTT.iX;iY = mouseTT.iY;
|
||||
iW = (INT32)GetWidthOfString( mouseTT.FastHelpText ) + 10;
|
||||
iH = (INT32)( GetNumberOfLinesInHeight( mouseTT.FastHelpText ) * (GetFontHeight(FONT10ARIAL)+1) + 8 );
|
||||
iX = mouseTT.iX;iY = mouseTT.iY;
|
||||
iW = (INT32)GetWidthOfString( mouseTT.FastHelpText ) + 10;
|
||||
iH = (INT32)( GetNumberOfLinesInHeight( mouseTT.FastHelpText ) * (GetFontHeight(FONT10ARIAL)+1) + 8 );
|
||||
|
||||
if(1)//draw at cursor
|
||||
{
|
||||
|
||||
@@ -3573,7 +3573,9 @@ UINT32 CalcChanceToHitGun(SOLDIERTYPE *pSoldier, UINT16 sGridNo, UINT8 ubAimTime
|
||||
if (pSoldier->bShock)
|
||||
iChance -= (pSoldier->bShock * AIM_PENALTY_PER_SHOCK);
|
||||
|
||||
if ( Item[ usInHand ].usItemClass == IC_GUN )
|
||||
// WANNE NEW: Changed this, because RPGs are not in the calculation, only guns
|
||||
//if ( Item[ usInHand ].usItemClass == IC_GUN )
|
||||
if ( Item[ usInHand ].usItemClass == IC_GUN || Item[ usInHand ].usItemClass == IC_LAUNCHER)
|
||||
{
|
||||
iMaxRange = GunRange( pInHand );
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user