mirror of
https://github.com/1dot13/source.git
synced 2026-07-22 13:40:22 +02:00
- Bugfix: Bobby Ray shop shown wrong values under 'size' (by DepressivesBrot)
o Both guns and magazines use DisplayMagazine (Laptop\BobbyRGuns.cpp ll. 1989) to display capacity and both try to get their capacity from the Magazine array whereas guns should get it from the Weapon array. git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@5117 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
@@ -1991,7 +1991,11 @@ UINT16 DisplayMagazine(UINT16 usPosY, UINT16 usIndex, UINT16 usFontHeight)
|
||||
CHAR16 sTemp[20];
|
||||
|
||||
DrawTextToScreen(BobbyRText[BOBBYR_GUNS_MAGAZINE], BOBBYR_ITEM_WEIGHT_TEXT_X, (UINT16)usPosY, 0, BOBBYR_ITEM_DESC_TEXT_FONT, BOBBYR_STATIC_TEXT_COLOR, FONT_MCOLOR_BLACK, FALSE, LEFT_JUSTIFIED);
|
||||
swprintf(sTemp, L"%3d %s", Magazine[Item[usIndex].ubClassIndex].ubMagSize, pMessageStrings[ MSG_ROUNDS_ABBREVIATION ] );
|
||||
if(Item[usIndex].usItemClass & IC_BOBBY_GUN){
|
||||
swprintf(sTemp, L"%3d %s", Weapon[Item[usIndex].ubClassIndex].ubMagSize, pMessageStrings[ MSG_ROUNDS_ABBREVIATION ] );
|
||||
}else{
|
||||
swprintf(sTemp, L"%3d %s", Magazine[Item[usIndex].ubClassIndex].ubMagSize, pMessageStrings[ MSG_ROUNDS_ABBREVIATION ] );
|
||||
}
|
||||
DrawTextToScreen(sTemp, BOBBYR_ITEM_WEIGHT_NUM_X, (UINT16)usPosY, BOBBYR_ITEM_WEIGHT_NUM_WIDTH, BOBBYR_ITEM_DESC_TEXT_FONT, BOBBYR_ITEM_DESC_TEXT_COLOR, FONT_MCOLOR_BLACK, FALSE, RIGHT_JUSTIFIED);
|
||||
usPosY += usFontHeight + 2;
|
||||
return(usPosY);
|
||||
|
||||
Reference in New Issue
Block a user