Merge pull request #57 from kytulendu/tfe_green_menu

Restore TFE green colors menu.
This commit is contained in:
ptitSeb 2022-05-20 19:41:59 +02:00 committed by GitHub
commit 9f44e31172
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 35 additions and 3 deletions

View File

@ -2804,11 +2804,13 @@ void CGame::GameMainLoop(void)
static CTextureObject _toPointer; static CTextureObject _toPointer;
static CTextureObject _toBcgClouds; static CTextureObject _toBcgClouds;
static CTextureObject _toBcgGrid; static CTextureObject _toBcgGrid;
#ifndef FIRST_ENCOUNTER
static CTextureObject _toBackdrop; static CTextureObject _toBackdrop;
static CTextureObject _toSamU; static CTextureObject _toSamU;
static CTextureObject _toSamD; static CTextureObject _toSamD;
static CTextureObject _toLeftU; static CTextureObject _toLeftU;
static CTextureObject _toLeftD; static CTextureObject _toLeftD;
#endif
static PIXaabbox2D _boxScreen_SE; static PIXaabbox2D _boxScreen_SE;
static PIX _pixSizeI_SE; static PIX _pixSizeI_SE;
@ -2840,20 +2842,24 @@ void CGame::LCDInit(void)
_toBcgGrid.SetData_t(CTFILENAME("TexturesMP\\General\\grid.tex")); _toBcgGrid.SetData_t(CTFILENAME("TexturesMP\\General\\grid.tex"));
#endif #endif
// thoses are not in original TFE datas and must be added externaly (with SE1_10.gro or a minimal versio of it) // thoses are not in original TFE datas and must be added externaly (with SE1_10.gro or a minimal versio of it)
#ifndef FIRST_ENCOUNTER
_toBackdrop.SetData_t(CTFILENAME("TexturesMP\\General\\MenuBack.tex")); _toBackdrop.SetData_t(CTFILENAME("TexturesMP\\General\\MenuBack.tex"));
_toSamU.SetData_t(CTFILENAME("TexturesMP\\General\\SamU.tex")); _toSamU.SetData_t(CTFILENAME("TexturesMP\\General\\SamU.tex"));
_toSamD.SetData_t(CTFILENAME("TexturesMP\\General\\SamD.tex")); _toSamD.SetData_t(CTFILENAME("TexturesMP\\General\\SamD.tex"));
_toLeftU.SetData_t(CTFILENAME("TexturesMP\\General\\LeftU.tex")); _toLeftU.SetData_t(CTFILENAME("TexturesMP\\General\\LeftU.tex"));
_toLeftD.SetData_t(CTFILENAME("TexturesMP\\General\\LeftD.tex")); _toLeftD.SetData_t(CTFILENAME("TexturesMP\\General\\LeftD.tex"));
#endif
// force constant textures // force constant textures
((CTextureData*)_toBcgClouds.GetData())->Force(TEX_CONSTANT); ((CTextureData*)_toBcgClouds.GetData())->Force(TEX_CONSTANT);
((CTextureData*)_toPointer .GetData())->Force(TEX_CONSTANT); ((CTextureData*)_toPointer .GetData())->Force(TEX_CONSTANT);
((CTextureData*)_toBcgGrid .GetData())->Force(TEX_CONSTANT); ((CTextureData*)_toBcgGrid .GetData())->Force(TEX_CONSTANT);
#ifndef FIRST_ENCOUNTER
((CTextureData*)_toBackdrop .GetData())->Force(TEX_CONSTANT); ((CTextureData*)_toBackdrop .GetData())->Force(TEX_CONSTANT);
((CTextureData*)_toSamU .GetData())->Force(TEX_CONSTANT); ((CTextureData*)_toSamU .GetData())->Force(TEX_CONSTANT);
((CTextureData*)_toSamD .GetData())->Force(TEX_CONSTANT); ((CTextureData*)_toSamD .GetData())->Force(TEX_CONSTANT);
((CTextureData*)_toLeftU .GetData())->Force(TEX_CONSTANT); ((CTextureData*)_toLeftU .GetData())->Force(TEX_CONSTANT);
((CTextureData*)_toLeftD .GetData())->Force(TEX_CONSTANT); ((CTextureData*)_toLeftD .GetData())->Force(TEX_CONSTANT);
#endif
} catch (char *strError) { } catch (char *strError) {
FatalError("%s\n", strError); FatalError("%s\n", strError);
@ -2913,6 +2919,7 @@ void CGame::LCDScreenBoxOpenRight(COLOR col)
} }
void CGame::LCDRenderClouds1(void) void CGame::LCDRenderClouds1(void)
{ {
#ifndef FIRST_ENCOUNTER
_pdp_SE->PutTexture(&_toBackdrop, _boxScreen_SE, C_WHITE|255); _pdp_SE->PutTexture(&_toBackdrop, _boxScreen_SE, C_WHITE|255);
if (!_bPopup) { if (!_bPopup) {
@ -2959,7 +2966,9 @@ void CGame::LCDRenderClouds1(void)
_pdp_SE->PutTexture(&_toLeftD, box, SE_COL_BLUE_NEUTRAL|200); _pdp_SE->PutTexture(&_toLeftD, box, SE_COL_BLUE_NEUTRAL|200);
} }
#else
_pdp_SE->Fill(SE_COL_BLUE_DARK_HV | 255);
#endif
MEXaabbox2D boxBcgClouds1; MEXaabbox2D boxBcgClouds1;
TiledTextureSE(_boxScreen_SE, 1.2f*_pdp_SE->GetWidth()/640.0f, TiledTextureSE(_boxScreen_SE, 1.2f*_pdp_SE->GetWidth()/640.0f,
MEX2D(sin(_tmNow_SE*0.5f)*35,sin(_tmNow_SE*0.7f+1)*21), boxBcgClouds1); MEX2D(sin(_tmNow_SE*0.5f)*35,sin(_tmNow_SE*0.7f+1)*21), boxBcgClouds1);

View File

@ -16,16 +16,39 @@ with this program; if not, write to the Free Software Foundation, Inc.,
#ifndef __SECOLORS_H #ifndef __SECOLORS_H
#define __SECOLORS_H 1 #define __SECOLORS_H 1
#ifdef FIRST_ENCOUNTER
// names of defines are incorrect, should be white/green
#define SE_COL_ORANGE_LIGHT 0xFAFAFF00
#define SE_COL_ORANGE_NEUTRAL 0x00F20000
#define SE_COL_ORANGE_DARK 0x007F0000
#define SE_COL_ORANGE_DARK_LT 0x00BF0000
#define SE_COL_BLUE_DARK_HV 0x01160400
#define SE_COL_BLUE_DARK 0x255F2400
#define SE_COL_BLUE_DARK_LT 0x29702D00
#define SE_COL_BLUE_NEUTRAL 0x349D3A00
#define SE_COL_BLUE_NEUTRAL_LT 0x3AAD3600
#define SE_COL_BLUE_LIGHT 0x6AF53E00
#else
#define SE_COL_ORANGE_LIGHT 0xffd70000 #define SE_COL_ORANGE_LIGHT 0xffd70000
#define SE_COL_ORANGE_NEUTRAL 0xee9c0000 #define SE_COL_ORANGE_NEUTRAL 0xee9c0000
#define SE_COL_ORANGE_DARK 0x9b4b0000 #define SE_COL_ORANGE_DARK 0x9b4b0000
#define SE_COL_ORANGE_DARK_LT 0xbc6a0000 #define SE_COL_ORANGE_DARK_LT 0xbc6a0000
#define SE_COL_BLUE_DARK_HV 0x151c2300 #define SE_COL_BLUE_DARK_HV 0x151c2300
#define SE_COL_BLUE_DARK 0x2a384600 #define SE_COL_BLUE_DARK 0x2a384600
#define SE_COL_BLUE_DARK_LT 0x43596f00 #define SE_COL_BLUE_DARK_LT 0x43596f00
#define SE_COL_BLUE_NEUTRAL 0x5c7a9900 #define SE_COL_BLUE_NEUTRAL 0x5c7a9900
#define SE_COL_BLUE_NEUTRAL_LT 0x6097cc00 #define SE_COL_BLUE_NEUTRAL_LT 0x6097cc00
#define SE_COL_BLUE_LIGHT 0x64b4ff00 #define SE_COL_BLUE_LIGHT 0x64b4ff00
#define SE_COL_BLUEGREEN_LT 0x6cff6c00
#endif
#define SE_COL_BLUEGREEN_LT 0x6cff6c00
#endif #endif