From e765dfe90a5519dc221580acf6d78fdd9c74ceab Mon Sep 17 00:00:00 2001 From: _AG Date: Tue, 25 Jun 2019 02:34:29 +0200 Subject: Initial commit for Frontend. Bug fixes: fix #40, fix #39, fix #38, fix #37, fix #21. Code organization and cleanup... --- src/main.cpp | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) (limited to 'src/main.cpp') diff --git a/src/main.cpp b/src/main.cpp index f9ede02d..0dadc131 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -85,6 +85,7 @@ extern void (*DebugMenuProcess)(void); extern void (*DebugMenuRender)(void); void DebugMenuInit(void); +void PrintGameVersion(); RwRGBA gColourTop; @@ -154,6 +155,7 @@ Idle(void *arg) } RenderMenus(); + PrintGameVersion(); DoFade(); Render2dStuffAfterFade(); CCredits::Render(); @@ -186,6 +188,7 @@ FrontendIdle(void) DefinedState(); RenderMenus(); + PrintGameVersion(); DoFade(); Render2dStuffAfterFade(); CFont::DrawFonts(); @@ -772,6 +775,25 @@ AppEventHandler(RsEvent event, void *param) } } +void PrintGameVersion() +{ + CFont::SetPropOn(); + CFont::SetBackgroundOff(); + CFont::SetScale(SCREEN_SCALE_X(0.7f), SCREEN_SCALE_Y(0.5f)); + CFont::SetCentreOff(); + CFont::SetRightJustifyOff(); + CFont::SetBackGroundOnlyTextOff(); + CFont::SetFontStyle(FONT_BANK); + CFont::SetWrapx(SCREEN_WIDTH); + CFont::SetDropShadowPosition(0); + CFont::SetDropColor(CRGBA(0, 0, 0, 255)); + CFont::SetColor(CRGBA(235, 170, 50, 255)); + + strcpy(gString, "RE3"); + AsciiToUnicode(gString, gUString); + CFont::PrintString(SCREEN_SCALE_X(10.5f), SCREEN_SCALE_Y(8.0f), gUString); +} + STARTPATCHES InjectHook(0x48E480, Idle, PATCH_JUMP); InjectHook(0x48E700, FrontendIdle, PATCH_JUMP); -- cgit v1.2.3