mirror of
https://github.com/ZDoom/qzdoom.git
synced 2024-11-08 14:01:32 +00:00
2a77ea0155
* When the drawbar code was optimized border was accidently used as how many pixels to reserve from the background instead of the foreground. I've reversed how the code works (bg over fg instead of fg over bg). * Added armorclass to drawnumber. * Added an interpolateArmor variable which acts just like interpolateHealth except the effect is applied to armor. * Added armor flag to drawgem since we can interpolate armor now. * Added a reverse flag to drawgem. * Fixed drawgem didn't allow for '|' to separate the flags. - Fixed: Menu texts for skill definitions unconditionally interpreted the given text as an index into the string table. SVN r752 (trunk)
73 lines
1.6 KiB
C++
73 lines
1.6 KiB
C++
#ifndef __SBarInfo_SBAR_H__
|
|
#define __SBarInfo_SBAR_H__
|
|
|
|
#include "tarray.h"
|
|
#include "v_collection.h"
|
|
|
|
class FBarTexture;
|
|
class FScanner;
|
|
|
|
struct SBarInfoCommand; //we need to be able to use this before it is defined.
|
|
|
|
struct SBarInfoBlock
|
|
{
|
|
TArray<SBarInfoCommand> commands;
|
|
bool forceScaled;
|
|
SBarInfoBlock();
|
|
};
|
|
|
|
struct SBarInfoCommand
|
|
{
|
|
SBarInfoCommand();
|
|
~SBarInfoCommand();
|
|
void setString(FScanner &sc, const char* source, int strnum, int maxlength=-1, bool exact=false);
|
|
|
|
int type;
|
|
int special;
|
|
int special2;
|
|
int special3;
|
|
int special4;
|
|
int flags;
|
|
int x;
|
|
int y;
|
|
int value;
|
|
int sprite;
|
|
FString string[2];
|
|
FFont *font;
|
|
EColorRange translation;
|
|
EColorRange translation2;
|
|
EColorRange translation3;
|
|
SBarInfoBlock subBlock; //for type SBarInfo_CMD_GAMEMODE
|
|
};
|
|
|
|
struct SBarInfo
|
|
{
|
|
TArray<FString> Images;
|
|
SBarInfoBlock huds[6];
|
|
bool automapbar;
|
|
bool interpolateHealth;
|
|
bool interpolateArmor;
|
|
bool completeBorder;
|
|
int interpolationSpeed;
|
|
int armorInterpolationSpeed;
|
|
int height;
|
|
int gameType;
|
|
|
|
int GetGameType() { return gameType; }
|
|
void ParseSBarInfo(int lump);
|
|
void ParseSBarInfoBlock(FScanner &sc, SBarInfoBlock &block);
|
|
void getCoordinates(FScanner &sc, SBarInfoCommand &cmd); //retrieves the next two arguments as x and y.
|
|
int getSignedInteger(FScanner &sc); //returns a signed integer.
|
|
int newImage(const char* patchname);
|
|
void Init();
|
|
EColorRange GetTranslation(FScanner &sc, char* translation);
|
|
SBarInfo();
|
|
SBarInfo(int lumpnum);
|
|
~SBarInfo();
|
|
};
|
|
|
|
extern SBarInfo *SBarInfoScript;
|
|
|
|
void FreeSBarInfoScript();
|
|
|
|
#endif //__SBarInfo_SBAR_H__
|