2019-05-30 21:24:47 +02:00
|
|
|
#include "common.h"
|
|
|
|
#include "patcher.h"
|
|
|
|
#include "Frontend.h"
|
|
|
|
|
2019-06-15 01:34:19 +02:00
|
|
|
int32 &CMenuManager::OS_Language = *(int32*)0x5F2F78;
|
|
|
|
int8 &CMenuManager::m_PrefsUseVibration = *(int8*)0x95CD92;
|
|
|
|
int8 &CMenuManager::m_DisplayControllerOnFoot = *(int8*)0x95CD8D;
|
|
|
|
int8 &CMenuManager::m_PrefsVsync = *(int8*)0x5F2E58;
|
|
|
|
int8 &CMenuManager::m_PrefsVsyncDisp = *(int8*)0x5F2E5C;
|
|
|
|
int8 &CMenuManager::m_PrefsFrameLimiter = *(int8*)0x5F2E60;
|
|
|
|
int8 &CMenuManager::BlurOn = *(int8*)0x95CDAD;
|
|
|
|
int8 &CMenuManager::m_PrefsShowSubtitles = *(int8*)0x5F2E54;
|
|
|
|
int8 &CMenuManager::m_PrefsSpeakers = *(int8*)0x95CD7E;
|
|
|
|
int8 &CMenuManager::m_ControlMethod = *(int8*)0x8F5F7C;
|
|
|
|
int8 &CMenuManager::m_PrefsDMA = *(int8*)0x5F2F74;
|
|
|
|
int8 &CMenuManager::m_PrefsLanguage = *(int8*)0x941238;
|
|
|
|
|
2019-06-17 00:16:38 +02:00
|
|
|
bool &CMenuManager::m_PrefsAllowNastyGame = *(bool*)0x5F2E64;
|
|
|
|
bool &CMenuManager::m_bStartUpFrontEndRequested = *(bool*)0x95CCF4;
|
2019-06-15 01:34:19 +02:00
|
|
|
|
|
|
|
int8 &CMenuManager::m_PrefsUseWideScreen = *(int8*)0x95CD23;
|
|
|
|
int8 &CMenuManager::m_PrefsRadioStation = *(int8*)0x95CDA4;
|
|
|
|
int8 &CMenuManager::m_bDisableMouseSteering = *(int8*)0x60252C;
|
|
|
|
int32 &CMenuManager::m_PrefsBrightness = *(int32*)0x5F2E50;
|
2019-06-17 00:16:38 +02:00
|
|
|
float &CMenuManager::m_PrefsLOD = *(float*)0x8F42C4;
|
2019-06-15 01:34:19 +02:00
|
|
|
int8 &CMenuManager::m_bFrontEnd_ReloadObrTxtGxt = *(int8*)0x628CFC;
|
|
|
|
int32 &CMenuManager::m_PrefsMusicVolume = *(int32*)0x5F2E4C;
|
|
|
|
int32 &CMenuManager::m_PrefsSfxVolume = *(int32*)0x5F2E48;
|
2019-05-31 11:44:43 +02:00
|
|
|
|
2019-05-30 21:24:47 +02:00
|
|
|
CMenuManager &FrontEndMenuManager = *(CMenuManager*)0x8F59D8;
|
|
|
|
|
2019-05-31 11:44:43 +02:00
|
|
|
WRAPPER void CMenuManager::Process(void) { EAXJMP(0x485100); }
|
2019-05-30 21:24:47 +02:00
|
|
|
WRAPPER void CMenuManager::DrawFrontEnd(void) { EAXJMP(0x47A540); }
|
2019-06-02 05:00:38 +02:00
|
|
|
WRAPPER void CMenuManager::UnloadTextures(void) { EAXJMP(0x47A440); }
|
|
|
|
WRAPPER void CMenuManager::LoadAllTextures(void) { EAXJMP(0x47A230); }
|
|
|
|
WRAPPER void CMenuManager::LoadSettings(void) { EAXJMP(0x488EE0); }
|
|
|
|
WRAPPER void CMenuManager::WaitForUserCD(void) { EAXJMP(0x48ADD0); }
|
2019-06-15 01:34:19 +02:00
|
|
|
|
|
|
|
int CMenuManager::FadeIn(int alpha) {
|
2019-06-17 02:10:55 +02:00
|
|
|
if (m_nCurrScreen == MENU_LOADING_IN_PROGRESS ||
|
|
|
|
m_nCurrScreen == MENU_SAVING_IN_PROGRESS ||
|
|
|
|
m_nCurrScreen == MENU_DELETING)
|
2019-06-15 01:34:19 +02:00
|
|
|
return alpha;
|
|
|
|
|
2019-06-17 02:10:55 +02:00
|
|
|
if (m_nMenuFadeAlpha >= alpha)
|
2019-06-15 01:34:19 +02:00
|
|
|
return alpha;
|
|
|
|
|
2019-06-17 02:10:55 +02:00
|
|
|
return m_nMenuFadeAlpha;
|
2019-06-15 01:34:19 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
STARTPATCHES
|
|
|
|
InjectHook(0x48AC60, &CMenuManager::FadeIn, PATCH_JUMP);
|
|
|
|
ENDPATCHES
|