mirror of
https://github.com/ZDoom/raze-gles.git
synced 2025-01-02 14:40:40 +00:00
- aded Alt. HUD icon tiles
Not tested yet, this merely uses the numbers from the item pickup function.
This commit is contained in:
parent
f7291960c3
commit
d6701d91a3
2 changed files with 11 additions and 10 deletions
|
@ -635,7 +635,7 @@ public:
|
||||||
DrawTexture(twod, tileGetTexture(TITLE_PIC), 0, 0, DTA_FullscreenEx, FSMode_ScaleToFit43, DTA_LegacyRenderStyle, STYLE_Normal, TAG_DONE);
|
DrawTexture(twod, tileGetTexture(TITLE_PIC), 0, 0, DTA_FullscreenEx, FSMode_ScaleToFit43, DTA_LegacyRenderStyle, STYLE_Normal, TAG_DONE);
|
||||||
|
|
||||||
MNU_DrawString(160, 170, /*DemoMode ? GStrings("TXT_LBDEMO") :*/ GStrings("TXT_ENTERING"), 1, 16, 0);
|
MNU_DrawString(160, 170, /*DemoMode ? GStrings("TXT_LBDEMO") :*/ GStrings("TXT_ENTERING"), 1, 16, 0);
|
||||||
MNU_DrawString(160, 180, currentLevel->DisplayName(), 1, 16, 0);
|
MNU_DrawString(160, 180, rec->DisplayName(), 1, 16, 0);
|
||||||
|
|
||||||
// Initiate the level load once the page has been faded in completely.
|
// Initiate the level load once the page has been faded in completely.
|
||||||
if (callback && GetFadeState() == visible)
|
if (callback && GetFadeState() == visible)
|
||||||
|
|
|
@ -755,17 +755,16 @@ private:
|
||||||
void DrawHUD2()
|
void DrawHUD2()
|
||||||
{
|
{
|
||||||
BeginHUD(320, 200, 1);
|
BeginHUD(320, 200, 1);
|
||||||
const int HEALTH = 0, SHIELD = 0;
|
|
||||||
|
|
||||||
auto pp = Player + screenpeek;
|
auto pp = Player + screenpeek;
|
||||||
USERp u = User[pp->PlayerSprite];
|
USERp u = User[pp->PlayerSprite];
|
||||||
|
|
||||||
double imgScale = (numberFont.mFont->GetHeight()) * 0.7;
|
double imgScale = (numberFont.mFont->GetHeight()) * 0.9;
|
||||||
|
|
||||||
//
|
//
|
||||||
// Health
|
// Health
|
||||||
//
|
//
|
||||||
auto imgHealth = tileGetTexture(HEALTH);
|
auto imgHealth = tileGetTexture(ICON_SM_MEDKIT);
|
||||||
auto healthScale = imgScale / imgHealth->GetDisplayHeight();
|
auto healthScale = imgScale / imgHealth->GetDisplayHeight();
|
||||||
DrawGraphic(imgHealth, 2, -1.5, DI_ITEM_LEFT_BOTTOM, 1., -1, -1, healthScale, healthScale);
|
DrawGraphic(imgHealth, 2, -1.5, DI_ITEM_LEFT_BOTTOM, 1., -1, -1, healthScale, healthScale);
|
||||||
|
|
||||||
|
@ -784,7 +783,7 @@ private:
|
||||||
//
|
//
|
||||||
// Armor
|
// Armor
|
||||||
//
|
//
|
||||||
auto imgArmor = tileGetTexture(SHIELD);
|
auto imgArmor = tileGetTexture(ICON_ARMOR);
|
||||||
auto armorScale = imgScale / imgArmor->GetDisplayHeight();
|
auto armorScale = imgScale / imgArmor->GetDisplayHeight();
|
||||||
DrawGraphic(imgArmor, 77.375, -1.5, DI_ITEM_LEFT_BOTTOM, 1., -1, -1, armorScale, armorScale);
|
DrawGraphic(imgArmor, 77.375, -1.5, DI_ITEM_LEFT_BOTTOM, 1., -1, -1, armorScale, armorScale);
|
||||||
|
|
||||||
|
@ -796,14 +795,16 @@ private:
|
||||||
//
|
//
|
||||||
int weapon = u->WeaponNum;
|
int weapon = u->WeaponNum;
|
||||||
|
|
||||||
if (u->WeaponNum != WPN_SWORD && u->WeaponNum != WPN_FIST && (!althud_flashing || (int)totalclock & 32 || pp->WpnAmmo[weapon] > (DamageData[weapon].max_ammo / 10)))
|
if ((!althud_flashing || (int)totalclock & 32 || pp->WpnAmmo[weapon] > (DamageData[weapon].max_ammo / 10)))
|
||||||
|
{
|
||||||
|
static const short ammo_sprites[] = { -1, ICON_STAR, ICON_LG_SHOTSHELL, ICON_LG_UZI_AMMO, ICON_MICRO_BATTERY, ICON_LG_GRENADE, ICON_LG_MINE, ICON_RAIL_AMMO,
|
||||||
|
ICON_FIREBALL_LG_AMMO, ICON_HEART_LG_AMMO, ICON_FIREBALL_LG_AMMO, ICON_FIREBALL_LG_AMMO,ICON_MICRO_BATTERY, -1 };
|
||||||
|
|
||||||
|
int wicon = ammo_sprites[weapon];
|
||||||
|
if (wicon > 0)
|
||||||
{
|
{
|
||||||
format.Format("%d", pp->WpnAmmo[weapon]);
|
format.Format("%d", pp->WpnAmmo[weapon]);
|
||||||
SBar_DrawString(this, &numberFont, format, -3, -numberFont.mFont->GetHeight(), DI_TEXT_ALIGN_RIGHT, CR_UNTRANSLATED, 1, 0, 0, 1, 1);
|
SBar_DrawString(this, &numberFont, format, -3, -numberFont.mFont->GetHeight(), DI_TEXT_ALIGN_RIGHT, CR_UNTRANSLATED, 1, 0, 0, 1, 1);
|
||||||
|
|
||||||
int wicon = 0;// ammo_sprites[weapon];
|
|
||||||
//if (wicon > 0)
|
|
||||||
{
|
|
||||||
auto imgWeap = tileGetTexture(wicon);
|
auto imgWeap = tileGetTexture(wicon);
|
||||||
auto weapScale = imgScale / imgWeap->GetDisplayHeight();
|
auto weapScale = imgScale / imgWeap->GetDisplayHeight();
|
||||||
auto imgX = 20.;
|
auto imgX = 20.;
|
||||||
|
|
Loading…
Reference in a new issue