From b9c3c8138e520781184a9f53dd38413234feffce Mon Sep 17 00:00:00 2001 From: Jack Andersen Date: Tue, 18 Aug 2015 13:30:23 -1000 Subject: [PATCH] TOneStatic tweak --- Runtime/MP1/main.cpp | 8 ++++---- Runtime/RetroTemplates.hpp | 1 + 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/Runtime/MP1/main.cpp b/Runtime/MP1/main.cpp index 063ce10a8..d64a8acbf 100644 --- a/Runtime/MP1/main.cpp +++ b/Runtime/MP1/main.cpp @@ -274,10 +274,10 @@ struct ApplicationCallback : boo::IApplicationCallback int main(int argc, const char* argv[]) { - ApplicationCallback appCB; + Retro::TOneStatic appCB; std::unique_ptr app = - boo::ApplicationBootstrap(boo::IApplication::PLAT_AUTO, appCB, + boo::ApplicationBootstrap(boo::IApplication::PLAT_AUTO, *appCB, "mp1", "MP1", argc, argv); - Retro::MP1::CMain main; - return main.RsMain(argc, argv); + Retro::TOneStatic main; + return main->RsMain(argc, argv); } diff --git a/Runtime/RetroTemplates.hpp b/Runtime/RetroTemplates.hpp index a2a854d93..427a1109c 100644 --- a/Runtime/RetroTemplates.hpp +++ b/Runtime/RetroTemplates.hpp @@ -19,6 +19,7 @@ public: static T* GetAllocSpace() {return (T*)m_allocspace;} static u32& ReferenceCount() {return m_refCount;} T* operator->() const {return (T*)m_allocspace;} + T& operator*() const {return *(T*)m_allocspace;} void* operator new(size_t) = delete; void operator delete(void*) = delete;