diff options
author | aap <aap@papnet.eu> | 2020-08-13 18:14:24 +0200 |
---|---|---|
committer | aap <aap@papnet.eu> | 2020-08-13 18:14:24 +0200 |
commit | afed831aeda5415f1d99612d0f14541fdd34720f (patch) | |
tree | eda5ea030af2ed1b76c2c1e645974fdb4c7b6246 /src/render/Hud.cpp | |
parent | fix render poly bug (diff) | |
download | re3-afed831aeda5415f1d99612d0f14541fdd34720f.tar re3-afed831aeda5415f1d99612d0f14541fdd34720f.tar.gz re3-afed831aeda5415f1d99612d0f14541fdd34720f.tar.bz2 re3-afed831aeda5415f1d99612d0f14541fdd34720f.tar.lz re3-afed831aeda5415f1d99612d0f14541fdd34720f.tar.xz re3-afed831aeda5415f1d99612d0f14541fdd34720f.tar.zst re3-afed831aeda5415f1d99612d0f14541fdd34720f.zip |
Diffstat (limited to 'src/render/Hud.cpp')
-rw-r--r-- | src/render/Hud.cpp | 63 |
1 files changed, 36 insertions, 27 deletions
diff --git a/src/render/Hud.cpp b/src/render/Hud.cpp index 1e536382..08c0cb85 100644 --- a/src/render/Hud.cpp +++ b/src/render/Hud.cpp @@ -175,7 +175,8 @@ void CHud::Draw() rect.right = f3rdX + SCREEN_SCALE_X(32.0f * 0.6f); rect.bottom = f3rdY + SCREEN_SCALE_Y(32.0f * 0.6f); - Sprites[HUD_SITEM16].Draw(CRect(rect), CRGBA(255, 255, 255, 255)); + Sprites[HUD_SITEM16].Draw(CRect(rect), CRGBA(255, 255, 255, 255), + 0.0f, 0.0f, 1.0f, 0.0f, 0.0f, 1.0f, 1.0f, 1.0f); } else { rect.left = f3rdX - SCREEN_SCALE_X(32.0f * 0.4f); @@ -183,7 +184,8 @@ void CHud::Draw() rect.right = f3rdX + SCREEN_SCALE_X(32.0f * 0.4f); rect.bottom = f3rdY + SCREEN_SCALE_Y(32.0f * 0.4f); - Sprites[HUD_SITEM16].Draw(CRect(rect), CRGBA(255, 255, 255, 255)); + Sprites[HUD_SITEM16].Draw(CRect(rect), CRGBA(255, 255, 255, 255), + 0.0f, 0.0f, 1.0f, 0.0f, 0.0f, 1.0f, 1.0f, 1.0f); } } else { @@ -194,7 +196,9 @@ void CHud::Draw() rect.top = (SCREEN_HEIGHT / 2) - SCREEN_SCALE_Y(32.0f); rect.right = (SCREEN_WIDTH / 2) + SCREEN_SCALE_X(32.0f); rect.bottom = (SCREEN_HEIGHT / 2) + SCREEN_SCALE_Y(32.0f); - Sprites[HUD_SITEM16].Draw(CRect(rect), CRGBA(255, 255, 255, 255)); + Sprites[HUD_SITEM16].Draw(CRect(rect), CRGBA(255, 255, 255, 255), + 0.0f, 0.0f, 1.0f, 0.0f, 0.0f, 1.0f, 1.0f, 1.0f); + } else if (Mode == CCam::MODE_1STPERSON_RUNABOUT) { rect.left = (SCREEN_WIDTH / 2) - SCREEN_SCALE_X(32.0f * 0.7f); @@ -202,7 +206,8 @@ void CHud::Draw() rect.right = (SCREEN_WIDTH / 2) + SCREEN_SCALE_X(32.0f * 0.7f); rect.bottom = (SCREEN_HEIGHT / 2) + SCREEN_SCALE_Y(32.0f * 0.7f); - Sprites[HUD_SITEM16].Draw(CRect(rect), CRGBA(255, 255, 255, 255)); + Sprites[HUD_SITEM16].Draw(CRect(rect), CRGBA(255, 255, 255, 255), + 0.0f, 0.0f, 1.0f, 0.0f, 0.0f, 1.0f, 1.0f, 1.0f); } else if (Mode == CCam::MODE_ROCKETLAUNCHER || Mode == CCam::MODE_ROCKETLAUNCHER_RUNABOUT) { RwRenderStateSet(rwRENDERSTATEVERTEXALPHAENABLE, (void *)TRUE); @@ -216,29 +221,33 @@ void CHud::Draw() } else { // Sniper - rect.left = (SCREEN_WIDTH / 2) - SCREEN_SCALE_X(210.0f); - rect.top = (SCREEN_HEIGHT / 2) - SCREEN_SCALE_Y(210.0f); - rect.right = SCREEN_WIDTH / 2; - rect.bottom = SCREEN_HEIGHT / 2; - Sprites[HUD_SITESNIPER].Draw(CRect(rect), CRGBA(255, 255, 255, 255)); - - rect.right = (SCREEN_WIDTH / 2); - rect.top = (SCREEN_HEIGHT / 2) - SCREEN_SCALE_Y(210.0f); - rect.left = SCREEN_SCALE_X(210.0f) + (SCREEN_WIDTH / 2); - rect.bottom = SCREEN_HEIGHT / 2; - Sprites[HUD_SITESNIPER].Draw(CRect(rect), CRGBA(255, 255, 255, 255)); - - rect.left = (SCREEN_WIDTH / 2) - SCREEN_SCALE_X(210.0f); - rect.bottom = (SCREEN_HEIGHT / 2); - rect.right = (SCREEN_WIDTH / 2); - rect.top = SCREEN_SCALE_Y(210.0f) + (SCREEN_HEIGHT / 2); - Sprites[HUD_SITESNIPER].Draw(CRect(rect), CRGBA(255, 255, 255, 255)); - - rect.right = (SCREEN_WIDTH / 2); - rect.bottom = (SCREEN_HEIGHT / 2); - rect.left = SCREEN_SCALE_X(210.0f) + (SCREEN_WIDTH / 2); - rect.top = SCREEN_SCALE_Y(210.0f) + (SCREEN_HEIGHT / 2); - Sprites[HUD_SITESNIPER].Draw(CRect(rect), CRGBA(255, 255, 255, 255)); + rect.left = SCREEN_WIDTH/2 - SCREEN_SCALE_X(210.0f); + rect.top = SCREEN_HEIGHT/2 - SCREEN_SCALE_Y(210.0f); + rect.right = SCREEN_WIDTH/2; + rect.bottom = SCREEN_HEIGHT/2; + Sprites[HUD_SITESNIPER].Draw(CRect(rect), CRGBA(255, 255, 255, 255), + 0.01f, 0.01f, 1.0f, 0.0f, 0.01f, 1.0f, 1.0f, 1.0f); + + rect.left = SCREEN_WIDTH/2; + rect.top = SCREEN_HEIGHT/2 - SCREEN_SCALE_Y(210.0f); + rect.right = SCREEN_WIDTH/2 + SCREEN_SCALE_X(210.0f); + rect.bottom = SCREEN_HEIGHT/2; + Sprites[HUD_SITESNIPER].Draw(CRect(rect), CRGBA(255, 255, 255, 255), + 0.99f, 0.0f, 0.01f, 0.01f, 0.99f, 1.0f, 0.01f, 1.0f); + + rect.left = SCREEN_WIDTH/2 - SCREEN_SCALE_X(210.0f); + rect.top = SCREEN_HEIGHT/2; + rect.right = SCREEN_WIDTH/2; + rect.bottom = SCREEN_HEIGHT/2 + SCREEN_SCALE_Y(210.0f); + Sprites[HUD_SITESNIPER].Draw(CRect(rect), CRGBA(255, 255, 255, 255), + 0.01f, 0.99f, 1.0f, 0.99f, 0.01f, 0.01f, 1.0f, 0.01f); + + rect.left = SCREEN_WIDTH/2; + rect.top = SCREEN_HEIGHT/2; + rect.right = SCREEN_WIDTH/2 + SCREEN_SCALE_X(210.0f); + rect.bottom = SCREEN_HEIGHT/2 + SCREEN_SCALE_Y(210.0f); + Sprites[HUD_SITESNIPER].Draw(CRect(rect), CRGBA(255, 255, 255, 255), + 0.99f, 0.99f, 0.01f, 0.99f, 0.99f, 0.01f, 0.1f, 0.01f); } } RwRenderStateSet(rwRENDERSTATETEXTUREFILTER, (void *)rwFILTERLINEAR); |