Squishing string-related bugs in Bomb display and Weapon reordering
This commit is contained in:
parent
f782692332
commit
4a6b3f2b8b
|
@ -1,5 +1,9 @@
|
|||
D2X-Rebirth Changelog
|
||||
|
||||
20091201
|
||||
--------
|
||||
main/gauges.c, main/weapon.c: Squishing string-related bugs in Bomb display and Weapon reordering
|
||||
|
||||
20091130
|
||||
--------
|
||||
d2x-rebirth.xcodeproj/project.pbxproj: Update to not compile redundant net_ipx.c for Mac OS X
|
||||
|
|
|
@ -1112,9 +1112,9 @@ void show_bomb_count(int x,int y,int bg_color,int always_show,int right_align)
|
|||
bomb = which_bomb();
|
||||
count = Players[Player_num].secondary_ammo[bomb];
|
||||
|
||||
#ifndef RELEASE
|
||||
// #ifndef RELEASE
|
||||
count = min(count,99); //only have room for 2 digits - cheating give 200
|
||||
#endif
|
||||
// #endif
|
||||
|
||||
countx = (bomb==PROXIMITY_INDEX)?count:-count;
|
||||
|
||||
|
@ -1126,7 +1126,7 @@ void show_bomb_count(int x,int y,int bg_color,int always_show,int right_align)
|
|||
else
|
||||
gr_set_fontcolor(bg_color,bg_color); //erase by drawing in background color
|
||||
|
||||
sprintf(txt,"B:%02d",count);
|
||||
snprintf(txt, sizeof(txt), "B:%02d", count);
|
||||
|
||||
while ((t=strchr(txt,'1')) != NULL)
|
||||
*t = '\x84'; //convert to wide '1'
|
||||
|
|
|
@ -570,15 +570,12 @@ void ReorderPrimary ()
|
|||
{
|
||||
newmenu_item m[MAX_PRIMARY_WEAPONS+1];
|
||||
int i;
|
||||
char never_autoselect[32]="";
|
||||
|
||||
sprintf(never_autoselect,"%s%s%s%s%s%s%s Never Autoselect %s%s%s%s%s%s%s",DOWN_ARROW_MARKER,DOWN_ARROW_MARKER,DOWN_ARROW_MARKER,DOWN_ARROW_MARKER,DOWN_ARROW_MARKER,DOWN_ARROW_MARKER,DOWN_ARROW_MARKER,DOWN_ARROW_MARKER,DOWN_ARROW_MARKER,DOWN_ARROW_MARKER,DOWN_ARROW_MARKER,DOWN_ARROW_MARKER,DOWN_ARROW_MARKER,DOWN_ARROW_MARKER);
|
||||
|
||||
for (i=0;i<MAX_PRIMARY_WEAPONS+1;i++)
|
||||
{
|
||||
m[i].type=NM_TYPE_MENU;
|
||||
if (PlayerCfg.PrimaryOrder[i]==255)
|
||||
m[i].text=never_autoselect;
|
||||
m[i].text="--- Never Autoselect below ---";
|
||||
else
|
||||
m[i].text=(char *)PRIMARY_WEAPON_NAMES(PlayerCfg.PrimaryOrder[i]);
|
||||
m[i].value=PlayerCfg.PrimaryOrder[i];
|
||||
|
@ -595,15 +592,12 @@ void ReorderSecondary ()
|
|||
{
|
||||
newmenu_item m[MAX_SECONDARY_WEAPONS+1];
|
||||
int i;
|
||||
char never_autoselect[32]="";
|
||||
|
||||
sprintf(never_autoselect,"%s%s%s%s%s%s%s Never Autoselect %s%s%s%s%s%s%s",DOWN_ARROW_MARKER,DOWN_ARROW_MARKER,DOWN_ARROW_MARKER,DOWN_ARROW_MARKER,DOWN_ARROW_MARKER,DOWN_ARROW_MARKER,DOWN_ARROW_MARKER,DOWN_ARROW_MARKER,DOWN_ARROW_MARKER,DOWN_ARROW_MARKER,DOWN_ARROW_MARKER,DOWN_ARROW_MARKER,DOWN_ARROW_MARKER,DOWN_ARROW_MARKER);
|
||||
|
||||
for (i=0;i<MAX_SECONDARY_WEAPONS+1;i++)
|
||||
{
|
||||
m[i].type=NM_TYPE_MENU;
|
||||
if (PlayerCfg.SecondaryOrder[i]==255)
|
||||
m[i].text=never_autoselect;
|
||||
m[i].text="--- Never Autoselect below ---";
|
||||
else
|
||||
m[i].text=(char *)SECONDARY_WEAPON_NAMES(PlayerCfg.SecondaryOrder[i]);
|
||||
m[i].value=PlayerCfg.SecondaryOrder[i];
|
||||
|
|
Loading…
Reference in a new issue