mirror of
https://github.com/DrBeef/Raze.git
synced 2024-11-15 08:52:00 +00:00
- added widescreen titlepic for Duke Nukem 3D:
Also made some tweaks to the intro sequence drawer so that it recognizes image formats not depending on the game palette.
This commit is contained in:
parent
f5d14f826a
commit
af298411df
3 changed files with 29 additions and 7 deletions
|
@ -169,7 +169,7 @@ public:
|
|||
{
|
||||
const uint64_t duration = 7'000'000'000;
|
||||
const auto tex = tileGetTexture(DREALMS, true);
|
||||
const int translation = TRANSLATION(Translation_BasePalettes, DREALMSPAL);
|
||||
int translation = tex->GetTexture()->GetImage()->UseGamePalette() ? TRANSLATION(Translation_BasePalettes, DREALMSPAL) : 0;
|
||||
|
||||
twod->ClearScreen();
|
||||
DrawTexture(twod, tex, 0, 0, DTA_FullscreenEx, FSMode_ScaleToFit43, DTA_TranslationIndex, translation, DTA_LegacyRenderStyle, STYLE_Normal, TAG_DONE);
|
||||
|
@ -188,17 +188,21 @@ class DTitleScreen : public DScreenJob
|
|||
int soundanm = 0;
|
||||
|
||||
public:
|
||||
DTitleScreen() : DScreenJob(fadein | fadeout) {}
|
||||
DTitleScreen() : DScreenJob(fadein | fadeout)
|
||||
{
|
||||
}
|
||||
|
||||
int Frame(uint64_t nsclock, bool skiprequest) override
|
||||
{
|
||||
twod->ClearScreen();
|
||||
int clock = nsclock * 120 / 1'000'000'000;
|
||||
|
||||
auto translation = TRANSLATION(Translation_BasePalettes, TITLEPAL);
|
||||
|
||||
twod->ClearScreen();
|
||||
DrawTexture(twod, tileGetTexture(BETASCREEN, true), 0, 0, DTA_FullscreenEx, FSMode_ScaleToFit43, DTA_TranslationIndex, translation, DTA_LegacyRenderStyle, STYLE_Normal, TAG_DONE);
|
||||
|
||||
// Only translate if the image depends on the global palette.
|
||||
auto tex = tileGetTexture(BETASCREEN, true);
|
||||
int translation = tex->GetTexture()->GetImage()->UseGamePalette() ? TRANSLATION(Translation_BasePalettes, TITLEPAL) : 0;
|
||||
DrawTexture(twod, tex, 0, 0, DTA_FullscreenEx, FSMode_ScaleToFit43, DTA_TranslationIndex, translation, DTA_LegacyRenderStyle, STYLE_Normal, TAG_DONE);
|
||||
|
||||
if (soundanm == 0 && clock >= 120 && clock < 120 + 60)
|
||||
{
|
||||
|
@ -223,20 +227,35 @@ public:
|
|||
|
||||
double scale = clamp(clock - 120, 0, 60) / 64.;
|
||||
if (scale > 0.)
|
||||
{
|
||||
tex = tileGetTexture(DUKENUKEM, true);
|
||||
translation = tex->GetTexture()->GetImage()->UseGamePalette() ? TRANSLATION(Translation_BasePalettes, TITLEPAL) : 0;
|
||||
|
||||
DrawTexture(twod, tileGetTexture(DUKENUKEM, true), 160, 104, DTA_FullscreenScale, FSMode_Fit320x200,
|
||||
DTA_CenterOffsetRel, true, DTA_TranslationIndex, translation, DTA_ScaleX, scale, DTA_ScaleY, scale, TAG_DONE);
|
||||
DTA_CenterOffsetRel, true, DTA_TranslationIndex, translation, DTA_ScaleX, scale, DTA_ScaleY, scale, TAG_DONE);
|
||||
}
|
||||
|
||||
scale = clamp(clock - 220, 0, 30) / 32.;
|
||||
if (scale > 0.)
|
||||
{
|
||||
tex = tileGetTexture(THREEDEE, true);
|
||||
translation = tex->GetTexture()->GetImage()->UseGamePalette() ? TRANSLATION(Translation_BasePalettes, TITLEPAL) : 0;
|
||||
|
||||
DrawTexture(twod, tileGetTexture(THREEDEE, true), 160, 129, DTA_FullscreenScale, FSMode_Fit320x200,
|
||||
DTA_CenterOffsetRel, true, DTA_TranslationIndex, translation, DTA_ScaleX, scale, DTA_ScaleY, scale, TAG_DONE);
|
||||
}
|
||||
|
||||
if (PLUTOPAK)
|
||||
{
|
||||
scale = (410 - clamp(clock, 280, 395)) / 16.;
|
||||
if (scale > 0. && clock > 280)
|
||||
DrawTexture(twod, tileGetTexture(PLUTOPAKSPRITE+1, true), 160, 151, DTA_FullscreenScale, FSMode_Fit320x200,
|
||||
{
|
||||
tex = tileGetTexture(PLUTOPAKSPRITE + 1, true);
|
||||
translation = tex->GetTexture()->GetImage()->UseGamePalette() ? TRANSLATION(Translation_BasePalettes, TITLEPAL) : 0;
|
||||
|
||||
DrawTexture(twod, tileGetTexture(PLUTOPAKSPRITE + 1, true), 160, 151, DTA_FullscreenScale, FSMode_Fit320x200,
|
||||
DTA_CenterOffsetRel, true, DTA_TranslationIndex, translation, DTA_ScaleX, scale, DTA_ScaleY, scale, TAG_DONE);
|
||||
}
|
||||
}
|
||||
|
||||
if (clock > (860 + 120))
|
||||
|
|
|
@ -5,6 +5,9 @@ tilefromtexture 2326 { file "tiles/duke3d/2326.png" xoffset 16 ifcrc -1415291705
|
|||
// Status Bar (by fgsfds)
|
||||
tilefromtexture 2462 { file "tiles/duke3d/2462.png" xoffset 0 yoffset 14 ifcrc 126028789 }
|
||||
|
||||
// Titlepic (by Kinsie)
|
||||
tilefromtexture 2493 { file "tiles/duke3d/2493.png" ifcrc -1469434308 }
|
||||
|
||||
// all weapon graphics from Megaton edition.
|
||||
|
||||
// HUD Pistol
|
||||
|
|
BIN
wadsrc/static/filter/duke/tiles/duke3d/2493.png
Normal file
BIN
wadsrc/static/filter/duke/tiles/duke3d/2493.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 42 KiB |
Loading…
Reference in a new issue