- Changed gameinfo_t and gameborder_t to be named structs instead of

typedef'ed anonymous structs.
- Fixed: P_AutoUseHealth() used autousemodes 0 and 1 instead of 1 and 2.
- Fixed: SBARINFO did not recognize 5:4 aspect ratio.
- Fixed: screenshot_dir was ignored.


SVN r1505 (trunk)
This commit is contained in:
Randy Heit 2009-03-26 02:06:14 +00:00
parent 03e8f0e355
commit 854097ba03
5 changed files with 17 additions and 10 deletions

View file

@ -1,4 +1,11 @@
March 25, 2009 (Changes by Graf Zahl) March 25, 2009
- Changed gameinfo_t and gameborder_t to be named structs instead of
typedef'ed anonymous structs.
- Fixed: P_AutoUseHealth() used autousemodes 0 and 1 instead of 1 and 2.
- Fixed: SBARINFO did not recognize 5:4 aspect ratio.
- Fixed: screenshot_dir was ignored.
March 25, 2009 (Changes by Graf Zahl)
- Removed some obsolete code from G_InitLevelLocals that was causing problems - Removed some obsolete code from G_InitLevelLocals that was causing problems
with maps that have no name. with maps that have no name.
- Fixed: The inner loop in AWeaponSlot::PickWeapon could endlessly loop when - Fixed: The inner loop in AWeaponSlot::PickWeapon could endlessly loop when

View file

@ -275,7 +275,7 @@ enum //aspect ratios
ASPECTRATIO_4_3 = 0, ASPECTRATIO_4_3 = 0,
ASPECTRATIO_16_9 = 1, ASPECTRATIO_16_9 = 1,
ASPECTRATIO_16_10 = 2, ASPECTRATIO_16_10 = 2,
ASPECTRATIO_5_4 = 3, ASPECTRATIO_5_4 = 4,
}; };
enum //Key words enum //Key words

View file

@ -47,7 +47,7 @@
extern const char *GameNames[17]; extern const char *GameNames[17];
typedef struct struct gameborder_t
{ {
BYTE offset; BYTE offset;
BYTE size; BYTE size;
@ -59,9 +59,9 @@ typedef struct
char bl[8]; char bl[8];
char b[8]; char b[8];
char br[8]; char br[8];
} gameborder_t; };
typedef struct struct gameinfo_t
{ {
int flags; int flags;
EGameType gametype; EGameType gametype;
@ -94,7 +94,7 @@ typedef struct
FString intermissionMusic; FString intermissionMusic;
const char *GetFinalePage(unsigned int num) const; const char *GetFinalePage(unsigned int num) const;
} gameinfo_t; };
extern gameinfo_t gameinfo; extern gameinfo_t gameinfo;

View file

@ -648,7 +648,7 @@ void M_ScreenShot (const char *filename)
{ {
size_t dirlen; size_t dirlen;
autoname = Args->CheckValue("-shotdir"); autoname = Args->CheckValue("-shotdir");
if (autoname == NULL) if (autoname.IsEmpty())
{ {
autoname = screenshot_dir; autoname = screenshot_dir;
} }
@ -671,6 +671,7 @@ void M_ScreenShot (const char *filename)
} }
} }
autoname = NicePath(autoname); autoname = NicePath(autoname);
CreatePath(autoname);
if (!FindFreeName (autoname, writepcx ? "pcx" : "png")) if (!FindFreeName (autoname, writepcx ? "pcx" : "png"))
{ {
Printf ("M_ScreenShot: Delete some screenshots\n"); Printf ("M_ScreenShot: Delete some screenshots\n");
@ -682,7 +683,6 @@ void M_ScreenShot (const char *filename)
autoname = filename; autoname = filename;
DefaultExtension (autoname, writepcx ? ".pcx" : ".png"); DefaultExtension (autoname, writepcx ? ".pcx" : ".png");
} }
CreatePath(screenshot_dir);
// save the screenshot // save the screenshot
const BYTE *buffer; const BYTE *buffer;

View file

@ -779,8 +779,8 @@ void P_AutoUseHealth(player_t *player, int saveHealth)
{ {
int mode = static_cast<AHealthPickup*>(inv)->autousemode; int mode = static_cast<AHealthPickup*>(inv)->autousemode;
if (mode == 0) NormalHealthItems.Push(inv); if (mode == 1) NormalHealthItems.Push(inv);
else if (mode == 1) LargeHealthItems.Push(inv); else if (mode == 2) LargeHealthItems.Push(inv);
} }
} }