From 37100bf9c139155ead730ad9acfaf4cea7cdde4b Mon Sep 17 00:00:00 2001 From: itsmattkc Date: Thu, 27 Apr 2023 19:19:39 -0700 Subject: [PATCH] initial commit --- .gitignore | 1 + app/define.cpp | 14 + app/define.h | 17 + app/isle.cpp | 603 +++++++++++++++++++++++++++++++++ app/isle.h | 74 ++++ app/main.cpp | 134 ++++++++ isle.mak | 295 ++++++++++++++++ isle.mdp | Bin 0 -> 36352 bytes isle.ncb | Bin 0 -> 58368 bytes lib/define.h | 8 + lib/lego1.def | 137 ++++++++ lib/lego1.exp | Bin 0 -> 21310 bytes lib/lego1.lib | Bin 0 -> 100720 bytes lib/legoanimationmanager.h | 10 + lib/legobuildingmanager.h | 10 + lib/legogamestate.h | 13 + lib/legoinputmanager.h | 22 ++ lib/legomodelpresenter.h | 10 + lib/legoomni.h | 99 ++++++ lib/legopartpresenter.h | 10 + lib/legoroi.h | 10 + lib/legovideomanager.h | 15 + lib/legoworldpresenter.h | 10 + lib/mxatomid.h | 14 + lib/mxbackgroundaudiomanager.h | 10 + lib/mxbitmap.h | 10 + lib/mxdirectdraw.h | 10 + lib/mxdsaction.h | 52 +++ lib/mxdsfile.h | 10 + lib/mxomni.h | 15 + lib/mxomnicreateflags.h | 14 + lib/mxomnicreateparam.h | 25 ++ lib/mxpalette.h | 9 + lib/mxrect32.h | 13 + lib/mxstreamcontroller.h | 21 ++ lib/mxstreamer.h | 14 + lib/mxstring.h | 16 + lib/mxticklemanager.h | 19 ++ lib/mxtimer.h | 10 + lib/mxtransitionmanager.h | 12 + lib/mxvariabletable.h | 10 + lib/mxvideoparam.h | 32 ++ lib/mxvideoparamflags.h | 93 +++++ 43 files changed, 1901 insertions(+) create mode 100644 .gitignore create mode 100644 app/define.cpp create mode 100644 app/define.h create mode 100644 app/isle.cpp create mode 100644 app/isle.h create mode 100644 app/main.cpp create mode 100644 isle.mak create mode 100644 isle.mdp create mode 100644 isle.ncb create mode 100644 lib/define.h create mode 100644 lib/lego1.def create mode 100644 lib/lego1.exp create mode 100644 lib/lego1.lib create mode 100644 lib/legoanimationmanager.h create mode 100644 lib/legobuildingmanager.h create mode 100644 lib/legogamestate.h create mode 100644 lib/legoinputmanager.h create mode 100644 lib/legomodelpresenter.h create mode 100644 lib/legoomni.h create mode 100644 lib/legopartpresenter.h create mode 100644 lib/legoroi.h create mode 100644 lib/legovideomanager.h create mode 100644 lib/legoworldpresenter.h create mode 100644 lib/mxatomid.h create mode 100644 lib/mxbackgroundaudiomanager.h create mode 100644 lib/mxbitmap.h create mode 100644 lib/mxdirectdraw.h create mode 100644 lib/mxdsaction.h create mode 100644 lib/mxdsfile.h create mode 100644 lib/mxomni.h create mode 100644 lib/mxomnicreateflags.h create mode 100644 lib/mxomnicreateparam.h create mode 100644 lib/mxpalette.h create mode 100644 lib/mxrect32.h create mode 100644 lib/mxstreamcontroller.h create mode 100644 lib/mxstreamer.h create mode 100644 lib/mxstring.h create mode 100644 lib/mxticklemanager.h create mode 100644 lib/mxtimer.h create mode 100644 lib/mxtransitionmanager.h create mode 100644 lib/mxvariabletable.h create mode 100644 lib/mxvideoparam.h create mode 100644 lib/mxvideoparamflags.h diff --git a/.gitignore b/.gitignore new file mode 100644 index 00000000..c509ad24 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +Release/ diff --git a/app/define.cpp b/app/define.cpp new file mode 100644 index 00000000..09b3f25c --- /dev/null +++ b/app/define.cpp @@ -0,0 +1,14 @@ +#include "define.h" + +Isle *g_isle = 0; +int g_closed = 0; + +const char *WNDCLASS_NAME = "Lego Island MainNoM App"; +const char *WINDOW_TITLE = "LEGO®"; + +unsigned char g_mousedown = 0; +unsigned char g_mousemoved = 0; +int _DAT_00410050 = 0; +int _DAT_00410064 = 0; +int _DAT_004101bc = 200; +int _last_frame_time = 0; diff --git a/app/define.h b/app/define.h new file mode 100644 index 00000000..45522c2c --- /dev/null +++ b/app/define.h @@ -0,0 +1,17 @@ +#ifndef DEFINE_H +#define DEFINE_H + +class Isle; + +extern Isle *g_isle; +extern int g_closed; +extern const char *WNDCLASS_NAME; +extern const char *WINDOW_TITLE; +extern unsigned char g_mousedown; +extern unsigned char g_mousemoved; +extern int _DAT_00410050; +extern int _DAT_00410064; +extern int _DAT_004101bc; +extern int _last_frame_time; + +#endif // DEFINE_H diff --git a/app/isle.cpp b/app/isle.cpp new file mode 100644 index 00000000..bfaadc8c --- /dev/null +++ b/app/isle.cpp @@ -0,0 +1,603 @@ +#include "isle.h" + +#include "define.h" +#include "../lib/legoomni.h" +#include "../lib/mxdirectdraw.h" +#include "../lib/mxdsaction.h" +#include "../lib/mxomni.h" + +RECT windowRect = {0, 0, 640, 480}; + +Isle::Isle() +{ + m_hdPath = NULL; + m_cdPath = NULL; + m_deviceId = NULL; + m_savePath = NULL; + m_fullScreen = 1; + m_flipSurfaces = 0; + m_backBuffersInVram = 1; + m_using8bit = 0; + m_using16bit = 1; + m_unk24 = 0; + m_drawCursor = 0; + m_use3dSound = 1; + m_useMusic = 1; + m_useJoystick = 0; + m_joystickIndex = 0; + m_wideViewAngle = 1; + m_islandQuality = 1; + m_islandTexture = 1; + m_gameStarted = 0; + m_frameDelta = 10; + m_windowActive = 1; + + MxRect32 rect; + rect.m_left = 0; + rect.m_top = 0; + rect.m_right = 639; + rect.m_bottom = 479; + + m_videoParam = MxVideoParam(rect, NULL, 1, MxVideoParamFlags()); + m_videoParam.flags().Enable16Bit(MxDirectDraw::GetPrimaryBitDepth() == 16); + + m_windowHandle = NULL; + m_cursor1 = NULL; + m_cursor2 = NULL; + m_cursor3 = NULL; + m_cursor4 = NULL; + + LegoOmni::CreateInstance(); +} + +Isle::~Isle() +{ + if (LegoOmni::GetInstance()) { + close(); + MxOmni::DestroyInstance(); + } + + if (m_hdPath) { + delete [] m_hdPath; + } + + if (m_cdPath) { + delete [] m_cdPath; + } + + if (m_deviceId) { + delete [] m_deviceId; + } + + if (m_savePath) { + delete [] m_savePath; + } +} + +void Isle::close() +{ + MxDSAction ds; + + if (Lego()) { + GameState()->Save(0); + if (InputManager()) { + InputManager()->QueueEvent(KEYDOWN, 0, 0, 0, 0x20); + } + + // FIXME: Untangle + //VideoManager()->GetViewManager()->RemoveAll(NULL); + //ViewManager::RemoveAll + // (*(ViewManager **)(*(int *)(*(int *)(pLVar4 + 0x68) + 8) + 0x88), NULL); + + MxAtomId id; + long local_88 = 0; + Lego()->RemoveWorld(id, local_88); + Lego()->vtable24(ds); + TransitionManager()->SetWaitIndicator(NULL); + Lego()->vtable3c(); + + long lVar8; + do { + lVar8 = Streamer()->Close(NULL); + } while (lVar8 == 0); + + while (Lego()) { + if (Lego()->vtable28(ds) != 0) { + break; + } + + Timer()->GetRealTime(); + TickleManager()->vtable08(); + } + } +} + +BOOL readReg(LPCSTR name, LPSTR outValue, DWORD outSize) +{ + HKEY hKey; + DWORD valueType; + + if (RegOpenKeyExA(HKEY_LOCAL_MACHINE, "SOFTWARE\\Mindscape\\LEGO Island", 0, KEY_READ, &hKey) == ERROR_SUCCESS) { + if (RegQueryValueExA(hKey, name, NULL, &valueType, (LPBYTE) outValue, &outSize) == ERROR_SUCCESS) { + if (RegCloseKey(hKey) == ERROR_SUCCESS) { + return TRUE; + } + } + } + + return FALSE; +} + +int readRegBool(LPCSTR name, BOOL *out) +{ + char buffer[256]; + + BOOL read = readReg(name, buffer, 0x100); + if (read) { + if (strcmp("YES", buffer) == 0) { + *out = TRUE; + return TRUE; + } + + if (strcmp("NO", buffer) == 0) { + *out = FALSE; + return TRUE; + } + } + return FALSE; +} + +int readRegInt(LPCSTR name, int *out) +{ + char buffer[256]; + + if (readReg(name, buffer, 0x100)) { + *out = atoi(buffer); + return TRUE; + } + + return FALSE; +} + +void Isle::loadConfig() +{ + char buffer[256]; + + if (!readReg("diskpath", buffer, 0x400)) { + strcpy(buffer, MxOmni::GetHD()); + } + + m_hdPath = new char[strlen(buffer) + 1]; + strcpy(m_hdPath, buffer); + MxOmni::SetHD(m_hdPath); + + if (!readReg("cdpath", buffer, 0x400)) { + strcpy(buffer, MxOmni::GetCD()); + } + + m_cdPath = new char[strlen(buffer) + 1]; + strcpy(m_cdPath, buffer); + MxOmni::SetCD(m_cdPath); + + readRegBool("Flip Surfaces", &m_flipSurfaces); + readRegBool("Full Screen", &m_fullScreen); + readRegBool("Wide View Angle", &m_wideViewAngle); + readRegBool("3DSound", &m_use3dSound); + readRegBool("Music", &m_useMusic); + readRegBool("UseJoystick", &m_useJoystick); + readRegInt("JoystickIndex", &m_joystickIndex); + readRegBool("Draw Cursor", &m_drawCursor); + + int backBuffersInVRAM; + if (readRegBool("Back Buffers in Video RAM",&backBuffersInVRAM)) { + m_backBuffersInVram = !backBuffersInVRAM; + } + + int bitDepth; + if (readRegInt("Display Bit Depth", &bitDepth)) { + if (bitDepth == 8) { + m_using8bit = TRUE; + } else if (bitDepth == 16) { + m_using16bit = TRUE; + } + } + + if (!readReg("Island Quality", buffer, 0x400)) { + strcpy(buffer, "1"); + } + m_islandQuality = atoi(buffer); + + if (!readReg("Island Texture", buffer, 0x400)) { + strcpy(buffer, "1"); + } + m_islandTexture = atoi(buffer); + + if (readReg("3D Device ID", buffer, 0x400)) { + m_deviceId = new char[strlen(buffer) + 1]; + strcpy(m_deviceId, buffer); + } + + if (readReg("savepath", buffer, 0x400)) { + m_savePath = new char[strlen(buffer) + 1]; + strcpy(m_savePath, buffer); + } +} + +void Isle::setupVideoFlags(BOOL fullScreen, BOOL flipSurfaces, BOOL backBuffers, + BOOL using8bit, BOOL m_using16bit, BOOL param_6, BOOL param_7, + BOOL wideViewAngle, char *deviceId) +{ + m_videoParam.flags().EnableFullScreen(fullScreen); + m_videoParam.flags().EnableFlipSurfaces(flipSurfaces); + m_videoParam.flags().EnableBackBuffers(backBuffers); + m_videoParam.flags().EnableUnknown1(param_6); + m_videoParam.flags().EnableUnknown2(TRUE); + m_videoParam.flags().EnableWideViewAngle(wideViewAngle); + m_videoParam.SetDeviceName(deviceId); + if (using8bit) { + m_videoParam.flags().Enable16Bit(FALSE); + } + if (m_using16bit) { + m_videoParam.flags().Enable16Bit(TRUE); + } +} + +BOOL Isle::setupMediaPath() +{ + char mediaPath[256]; + GetProfileStringA("LEGO Island", "MediaPath", "", mediaPath, 0x100); + + MxOmniCreateParam createParam(mediaPath, (struct HWND__ *) m_windowHandle, m_videoParam, MxOmniCreateFlags()); + + if (Lego()->Create(createParam) != FAILURE) { + VariableTable()->SetVariable("ACTOR_01", ""); + TickleManager()->vtable1c(VideoManager(), 10); + return TRUE; + } + + return FALSE; +} + +LRESULT WINAPI WndProc(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam) +{ + if (!g_isle) { + return DefWindowProcA(hWnd, uMsg, wParam, lParam); + } + + switch (uMsg) { + case WM_PAINT: + return DefWindowProcA(hWnd, WM_PAINT, wParam, lParam); + case WM_ACTIVATE: + return DefWindowProcA(hWnd, WM_ACTIVATE, wParam, lParam); + case WM_ACTIVATEAPP: + if (g_isle) { + if ((wParam != 0) && (g_isle->m_fullScreen)) { + MoveWindow(hWnd, windowRect.left, windowRect.top, + (windowRect.right - windowRect.left) + 1, + (windowRect.bottom - windowRect.top) + 1, TRUE); + } + // FIXME: Untangle + //g_isle->m_windowActive = wParam; + } + return DefWindowProcA(hWnd,WM_ACTIVATEAPP,wParam,lParam); + case WM_CLOSE: + if (!g_closed && g_isle) { + if (g_isle) { + delete g_isle; + } + g_isle = NULL; + g_closed = TRUE; + return 0; + } + return DefWindowProcA(hWnd,WM_CLOSE,wParam,lParam); + case WM_GETMINMAXINFO: + { + MINMAXINFO *mmi = (MINMAXINFO *) lParam; + + mmi->ptMaxTrackSize.x = (windowRect.right - windowRect.left) + 1; + mmi->ptMaxTrackSize.y = (windowRect.bottom - windowRect.top) + 1; + mmi->ptMinTrackSize.x = (windowRect.right - windowRect.left) + 1; + mmi->ptMinTrackSize.y = (windowRect.bottom - windowRect.top) + 1; + + return 0; + } + case WM_ENTERMENULOOP: + return DefWindowProcA(hWnd,WM_ENTERMENULOOP,wParam,lParam); + case WM_SYSCOMMAND: + if (wParam == 0xf140) { + return 0; + } + if (wParam == 0xf060 && g_closed == 0) { + if (g_isle) { + if (_DAT_00410050 != 0) { + ShowWindow(g_isle->m_windowHandle, SW_RESTORE); + } + PostMessageA(g_isle->m_windowHandle, 0x10, 0, 0); + return 0; + } + } else if (g_isle && g_isle->m_fullScreen && (wParam == 0xf010 || wParam == 0xf100)) { + return 0; + } + return DefWindowProcA(hWnd,WM_SYSCOMMAND,wParam,lParam); + case WM_EXITMENULOOP: + return DefWindowProcA(hWnd,WM_EXITMENULOOP,wParam,lParam); + case WM_MOVING: + if (g_isle && g_isle->m_fullScreen) { + GetWindowRect(hWnd, (LPRECT) lParam); + return 0; + } + return DefWindowProcA(hWnd,WM_MOVING,wParam,lParam); + case WM_NCPAINT: + if (g_isle && g_isle->m_fullScreen) { + return 0; + } + return DefWindowProcA(hWnd, WM_NCPAINT, wParam, lParam); + case WM_DISPLAYCHANGE: + /* FIXME: Untangle + if (g_isle && VideoManager() && g_isle->m_fullScreen && ((pLVar7 = VideoManager(), *(int *)(pLVar7 + 0x74) != 0 && (pLVar7 = VideoManager(), *(int *)(*(int *)(pLVar7 + 0x74) + 0x880) != 0))) { + if (_DAT_00410054 == 0) { + unsigned char bVar1 = FALSE; + if (LOWORD(lParam) == _DAT_00410058 && HIWORD(lParam) == _DAT_0041005c && _DAT_00410060 == wParam) { + bVar1 = TRUE; + } + if (_DAT_00410050 == 0) { + if (!bVar1) { + _DAT_00410050 = 1; + Lego()->vtable38(); + VideoManager()->DisableRMDevice(); + } + } + else if (bVar1) { + _DAT_00410064 = 1; + } + } + else { + _DAT_00410054 = 0; + _DAT_00410060 = wParam; + } + }*/ + return DefWindowProcA(hWnd,WM_DISPLAYCHANGE,wParam,lParam); + + case WM_SETCURSOR: + case WM_KEYDOWN: + case WM_MOUSEMOVE: + case WM_TIMER: + case WM_LBUTTONDOWN: + case WM_LBUTTONUP: + { + + NotificationId type = NONE; + unsigned char keyCode = 0; + + switch (uMsg) { + case WM_KEYDOWN: + if (lParam & 0x40000000) { + return DefWindowProcA(hWnd,WM_KEYDOWN,wParam,lParam); + } + keyCode = wParam; + type = KEYDOWN; + break; + case WM_MOUSEMOVE: + g_mousemoved = 1; + type = MOUSEMOVE; + break; + case WM_TIMER: + type = TIMER; + break; + case WM_SETCURSOR: + if (g_isle) { + HCURSOR hCursor = g_isle->m_cursor4; + if (g_isle->m_cursor2 == hCursor || g_isle->m_cursor3 == hCursor || hCursor == NULL) { + SetCursor(hCursor); + return 0; + } + } + break; + case WM_LBUTTONDOWN: + g_mousedown = 1; + type = MOUSEDOWN; + break; + case WM_LBUTTONUP: + g_mousedown = 0; + type = MOUSEUP; + break; + case 0x5400: + if (g_isle) { + // FIXME: Untangle + //FUN_00402e80(g_isle,wParam); + return 0; + } + } + + if (g_isle) { + if (InputManager()) { + InputManager()->QueueEvent(type, wParam, LOWORD(lParam), HIWORD(lParam), keyCode); + } + if (g_isle && g_isle->m_drawCursor && type == MOUSEMOVE) { + unsigned short x = LOWORD(lParam); + unsigned short y = HIWORD(lParam); + if (639 < x) { + x = 639; + } + if (479 < y) { + y = 479; + } + VideoManager()->MoveCursor(x,y); + } + } + return 0; + } + } + + return DefWindowProcA(hWnd,uMsg,wParam,lParam); +} + +MxResult Isle::setupWindow(HINSTANCE hInstance) +{ + WNDCLASSA wndclass; + ZeroMemory(&wndclass, sizeof(WNDCLASSA)); + + loadConfig(); + + setupVideoFlags(m_fullScreen, m_flipSurfaces, m_backBuffersInVram, m_using8bit, + m_using16bit, m_unk24, FALSE, m_wideViewAngle, m_deviceId); + + MxOmni::SetSound3D(m_use3dSound); + + srand(timeGetTime() / 1000); + SystemParametersInfoA(SPI_SETMOUSETRAILS, 0, NULL, 0); + + ZeroMemory(&wndclass, sizeof(WNDCLASSA)); + + wndclass.cbClsExtra = 0; + wndclass.style = CS_HREDRAW | CS_VREDRAW; + wndclass.lpfnWndProc = WndProc; + wndclass.cbWndExtra = 0; + wndclass.hIcon = LoadIconA(hInstance, MAKEINTRESOURCE(105)); + wndclass.hCursor = LoadCursorA(hInstance, MAKEINTRESOURCE(102)); + m_cursor4 = wndclass.hCursor; + m_cursor1 = wndclass.hCursor; + m_cursor2 = LoadCursorA(hInstance, MAKEINTRESOURCE(104)); + m_cursor3 = LoadCursorA(hInstance, MAKEINTRESOURCE(103)); + wndclass.hInstance = hInstance; + wndclass.hbrBackground = GetStockObject(BLACK_BRUSH); + wndclass.lpszClassName = WNDCLASS_NAME; + + if (!RegisterClassA(&wndclass)) { + return FAILURE; + } + + DWORD dwStyle; + int x, y, width, height; + + if (!m_fullScreen) { + AdjustWindowRectEx(&windowRect, WS_CAPTION | WS_SYSMENU, 0, WS_EX_APPWINDOW); + + height = windowRect.bottom - windowRect.top; + width = windowRect.right - windowRect.left; + + y = CW_USEDEFAULT; + x = CW_USEDEFAULT; + dwStyle = WS_CAPTION | WS_SYSMENU | WS_MAXIMIZEBOX | WS_MINIMIZEBOX; + } else { + AdjustWindowRectEx(&windowRect, WS_CAPTION | WS_SYSMENU, 0, WS_EX_APPWINDOW); + height = windowRect.bottom - windowRect.top; + width = windowRect.right - windowRect.left; + dwStyle = WS_CAPTION | WS_SYSMENU; + x = windowRect.left; + y = windowRect.top; + } + + m_windowHandle = CreateWindowExA(WS_EX_APPWINDOW, WNDCLASS_NAME, WINDOW_TITLE, dwStyle, + x, y, width + 1, height + 1, NULL, NULL, hInstance, NULL); + if (!m_windowHandle) { + return FAILURE; + } + + if (m_fullScreen) { + MoveWindow(m_windowHandle, windowRect.left, windowRect.top, (windowRect.right - windowRect.left) + 1, (windowRect.bottom - windowRect.top) + 1, TRUE); + } + + ShowWindow(m_windowHandle, SW_SHOWNORMAL); + UpdateWindow(m_windowHandle); + if (!setupMediaPath()) { + return FAILURE; + } + + GameState()->SetSavePath(m_savePath); + GameState()->SerializePlayersInfo(1); + GameState()->SerializeScoreHistory(1); + + int iVar10; + if (m_islandQuality == 0) { + iVar10 = 1; + } else if (m_islandQuality == 1) { + iVar10 = 2; + } else { + iVar10 = 100; + } + + int uVar1 = (m_islandTexture == 0); + LegoModelPresenter::configureLegoModelPresenter(uVar1); + LegoPartPresenter::configureLegoPartPresenter(uVar1,iVar10); + LegoWorldPresenter::configureLegoWorldPresenter(m_islandQuality); + LegoBuildingManager::configureLegoBuildingManager(m_islandQuality); + LegoROI::configureLegoROI(iVar10); + LegoAnimationManager::configureLegoAnimationManager(m_islandQuality); + if (LegoOmni::GetInstance()) { + if (LegoOmni::GetInstance()->GetInputManager()) { + LegoOmni::GetInstance()->GetInputManager()->m_unk00[0xCD] = m_useJoystick; + LegoOmni::GetInstance()->GetInputManager()->m_unk00[0x67] = m_joystickIndex; + } + } + if (m_fullScreen) { + MoveWindow(m_windowHandle, windowRect.left, windowRect.top, (windowRect.right - windowRect.left) + 1, (windowRect.bottom - windowRect.top) + 1, TRUE); + } + ShowWindow(m_windowHandle, SW_SHOWNORMAL); + UpdateWindow(m_windowHandle); + + return SUCCESS; +} + +void Isle::tick(BOOL sleepIfNotNextFrame) +{ + if (this->m_windowActive) { + if (!Lego()) return; + if (!TickleManager()) return; + if (!Timer()) return; + + long currentTime = Timer()->GetRealTime(); + if (currentTime < _last_frame_time) { + _last_frame_time = -this->m_frameDelta; + } + if (this->m_frameDelta + _last_frame_time < currentTime) { + if (!Lego()->vtable40()) { + TickleManager()->vtable08(); + } + _last_frame_time = currentTime; + + if (_DAT_004101bc == 0) { + return; + } + + _DAT_004101bc--; + if (_DAT_004101bc != 0) { + return; + } + + LegoOmni::GetInstance()->CreateBackgroundAudio(); + BackgroundAudioManager()->Enable(this->m_useMusic); + + MxStreamController *stream = Streamer()->Open("\\lego\\scripts\\isle\\isle", 0); + MxDSAction ds; + + if (!stream) { + stream = Streamer()->Open("\\lego\\scripts\\nocd", 0); + if (!stream) { + return; + } + + ds.m_atomId = stream->atom; + ds.m_unk24 = 0xFFFF; + ds.m_unk1c = 0; + VideoManager()->EnableFullScreenMovie(TRUE, TRUE); + + if (Start(&ds) != SUCCESS) { + return; + } + } else { + ds.m_atomId = stream->atom; + ds.m_unk24 = 0xFFFF; + ds.m_unk1c = 0; + if (Start(&ds) != SUCCESS) { + return; + } + this->m_gameStarted = 1; + } + return; + } + if (sleepIfNotNextFrame == 0) return; + } + + Sleep(0); +} diff --git a/app/isle.h b/app/isle.h new file mode 100644 index 00000000..9b7ffc05 --- /dev/null +++ b/app/isle.h @@ -0,0 +1,74 @@ +#ifndef ISLE_H +#define ISLE_H + +#include + +#include "../lib/define.h" +#include "../lib/mxvideoparam.h" + +class Isle +{ +public: + Isle(); + ~Isle(); + + static void close(); + + MxResult setupWindow(HINSTANCE hInstance); + + void tick(BOOL sleepIfNotNextFrame); + + BOOL setupMediaPath(); + void loadConfig(); + void setupVideoFlags(BOOL fullScreen, BOOL flipSurfaces, BOOL backBuffers, + BOOL using8bit, BOOL m_using16bit, BOOL param_6, BOOL param_7, + BOOL wideViewAngle, char *deviceId); + +//private: + + // 0 + LPSTR m_hdPath; + LPSTR m_cdPath; + LPSTR m_deviceId; + LPSTR m_savePath; + + // 10 + BOOL m_fullScreen; + BOOL m_flipSurfaces; + BOOL m_backBuffersInVram; + BOOL m_using8bit; + + // 20 + BOOL m_using16bit; + int m_unk24; + BOOL m_use3dSound; + BOOL m_useMusic; + + // 30 + BOOL m_useJoystick; + int m_joystickIndex; + BOOL m_wideViewAngle; + int m_islandQuality; + + // 40 + int m_islandTexture; + int m_gameStarted; + long m_frameDelta; + + // 4c + MxVideoParam m_videoParam; + + // 70 + BOOL m_windowActive; + HWND m_windowHandle; + BOOL m_drawCursor; + HCURSOR m_cursor1; + + // 80 + HCURSOR m_cursor2; + HCURSOR m_cursor3; + HCURSOR m_cursor4; + +}; + +#endif // ISLE_H diff --git a/app/main.cpp b/app/main.cpp new file mode 100644 index 00000000..e762cd69 --- /dev/null +++ b/app/main.cpp @@ -0,0 +1,134 @@ +#include +#include + +#include "define.h" +#include "isle.h" +#include "../lib/legoomni.h" + +BOOL findExistingInstance(void) +{ + HWND hWnd = FindWindowA(WNDCLASS_NAME, WINDOW_TITLE); + if (hWnd) { + if (SetForegroundWindow(hWnd)) { + ShowWindow(hWnd, SW_RESTORE); + } + return 0; + } + return 1; +} + +BOOL startDirectSound(void) +{ + LPDIRECTSOUND lpDS; + HRESULT ret = DirectSoundCreate(NULL, &lpDS, NULL); + if (ret == DS_OK && lpDS != NULL) { + lpDS->Release(); + return TRUE; + } + + return FALSE; +} + +int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine, int nShowCmd) +{ + // Look for another instance, if we find one, bring it to the foreground instead + if (!findExistingInstance()) { + return 0; + } + + // Attempt to create DirectSound instance + BOOL soundReady = FALSE; + for (int i = 0; i < 20; i++) { + if (startDirectSound()) { + soundReady = TRUE; + break; + } + Sleep(500); + } + + // Throw error if sound unavailable + if (!soundReady) { + MessageBoxA(NULL, "\"LEGO® Island\" is not detecting a DirectSound compatible sound card. Please quit all other applications and try again.", + "Lego Island Error",0); + return 0; + } + + // Create global app instance + g_isle = new Isle(); + + // Create window + if (g_isle->setupWindow(hInstance) != SUCCESS) { + MessageBoxA(NULL, "\"LEGO® Island\" failed to start. Please quit all other applications and try again.", "LEGO® Island Error",0); + return 0; + } + + // Get reference to window + HWND window; + if (g_isle->m_windowHandle) { + window = g_isle->m_windowHandle; + } + + // Load accelerator (don't know what this does) + LoadAcceleratorsA(hInstance, "AppAccel"); + + MSG msg; + + while (!g_closed) { + while (!PeekMessageA(&msg, NULL, 0, 0, PM_NOREMOVE)) { + if (g_isle) { + g_isle->tick(1); + } + } + + if (g_isle) { + g_isle->tick(1); + } + + if (g_closed) { + break; + } + + do { + if (!PeekMessageA(&msg, NULL, 0, 0, PM_REMOVE)) { + break; + } + + MSG nextMsg; + if (!g_isle + || !g_isle->m_windowHandle + || msg.message != WM_MOUSEMOVE + || !PeekMessageA(&nextMsg, NULL, 0, 0, PM_NOREMOVE) + || nextMsg.message != WM_MOUSEMOVE) { + TranslateMessage(&msg); + DispatchMessageA(&msg); + } + + if (_DAT_00410064 != 0) { + _DAT_00410064 = 0; + VideoManager()->EnableRMDevice(); + _DAT_00410050 = 0; + Lego()->vtable3c(); + } + + if (g_closed) { + break; + } + + if (g_mousedown == 0) { +LAB_00401bc7: + if (g_mousemoved) { + g_mousemoved = FALSE; + } + } else if (g_mousemoved) { + if (g_isle) { + g_isle->tick(0); + } + goto LAB_00401bc7; + } + } while (!g_closed); + } + + DestroyWindow(window); + + return msg.wParam; +} diff --git a/isle.mak b/isle.mak new file mode 100644 index 00000000..37b25818 --- /dev/null +++ b/isle.mak @@ -0,0 +1,295 @@ +# Microsoft Developer Studio Generated NMAKE File, Format Version 4.20 +# ** DO NOT EDIT ** + +# TARGTYPE "Win32 (x86) Application" 0x0101 + +!IF "$(CFG)" == "" +CFG=isle - Win32 Debug +!MESSAGE No configuration specified. Defaulting to isle - Win32 Debug. +!ENDIF + +!IF "$(CFG)" != "isle - Win32 Release" && "$(CFG)" != "isle - Win32 Debug" +!MESSAGE Invalid configuration "$(CFG)" specified. +!MESSAGE You can specify a configuration when running NMAKE on this makefile +!MESSAGE by defining the macro CFG on the command line. For example: +!MESSAGE +!MESSAGE NMAKE /f "isle.mak" CFG="isle - Win32 Debug" +!MESSAGE +!MESSAGE Possible choices for configuration are: +!MESSAGE +!MESSAGE "isle - Win32 Release" (based on "Win32 (x86) Application") +!MESSAGE "isle - Win32 Debug" (based on "Win32 (x86) Application") +!MESSAGE +!ERROR An invalid configuration is specified. +!ENDIF + +!IF "$(OS)" == "Windows_NT" +NULL= +!ELSE +NULL=nul +!ENDIF +################################################################################ +# Begin Project +# PROP Target_Last_Scanned "isle - Win32 Debug" +CPP=cl.exe +MTL=mktyplib.exe +RSC=rc.exe + +!IF "$(CFG)" == "isle - Win32 Release" + +# PROP BASE Use_MFC 0 +# PROP BASE Use_Debug_Libraries 0 +# PROP BASE Output_Dir "Release" +# PROP BASE Intermediate_Dir "Release" +# PROP BASE Target_Dir "" +# PROP Use_MFC 0 +# PROP Use_Debug_Libraries 0 +# PROP Output_Dir "Release" +# PROP Intermediate_Dir "Release" +# PROP Target_Dir "" +OUTDIR=.\Release +INTDIR=.\Release + +ALL : "$(OUTDIR)\isle.exe" + +CLEAN : + -@erase "$(INTDIR)\define.obj" + -@erase "$(INTDIR)\isle.obj" + -@erase "$(INTDIR)\main.obj" + -@erase "$(OUTDIR)\isle.exe" + +"$(OUTDIR)" : + if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)" + +# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /YX /c +# ADD CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /YX /c +CPP_PROJ=/nologo /ML /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS"\ + /Fp"$(INTDIR)/isle.pch" /YX /Fo"$(INTDIR)/" /c +CPP_OBJS=.\Release/ +CPP_SBRS=.\. +# ADD BASE MTL /nologo /D "NDEBUG" /win32 +# ADD MTL /nologo /D "NDEBUG" /win32 +MTL_PROJ=/nologo /D "NDEBUG" /win32 +# ADD BASE RSC /l 0x409 /d "NDEBUG" +# ADD RSC /l 0x409 /d "NDEBUG" +BSC32=bscmake.exe +# ADD BASE BSC32 /nologo +# ADD BSC32 /nologo +BSC32_FLAGS=/nologo /o"$(OUTDIR)/isle.bsc" +BSC32_SBRS= \ + +LINK32=link.exe +# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386 +# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib dsound.lib winmm.lib lib/lego1.lib /nologo /subsystem:windows /machine:I386 +LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib\ + advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib\ + odbccp32.lib dsound.lib winmm.lib lib/lego1.lib /nologo /subsystem:windows\ + /incremental:no /pdb:"$(OUTDIR)/isle.pdb" /machine:I386\ + /out:"$(OUTDIR)/isle.exe" +LINK32_OBJS= \ + "$(INTDIR)\define.obj" \ + "$(INTDIR)\isle.obj" \ + "$(INTDIR)\main.obj" + +"$(OUTDIR)\isle.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS) + $(LINK32) @<< + $(LINK32_FLAGS) $(LINK32_OBJS) +<< + +!ELSEIF "$(CFG)" == "isle - Win32 Debug" + +# PROP BASE Use_MFC 0 +# PROP BASE Use_Debug_Libraries 1 +# PROP BASE Output_Dir "Debug" +# PROP BASE Intermediate_Dir "Debug" +# PROP BASE Target_Dir "" +# PROP Use_MFC 0 +# PROP Use_Debug_Libraries 1 +# PROP Output_Dir "Debug" +# PROP Intermediate_Dir "Debug" +# PROP Target_Dir "" +OUTDIR=.\Debug +INTDIR=.\Debug + +ALL : "$(OUTDIR)\isle.exe" + +CLEAN : + -@erase "$(INTDIR)\define.obj" + -@erase "$(INTDIR)\isle.obj" + -@erase "$(INTDIR)\main.obj" + -@erase "$(INTDIR)\vc40.idb" + -@erase "$(INTDIR)\vc40.pdb" + -@erase "$(OUTDIR)\isle.exe" + -@erase "$(OUTDIR)\isle.ilk" + -@erase "$(OUTDIR)\isle.pdb" + +"$(OUTDIR)" : + if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)" + +# ADD BASE CPP /nologo /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /YX /c +# ADD CPP /nologo /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /YX /c +CPP_PROJ=/nologo /MLd /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS"\ + /Fp"$(INTDIR)/isle.pch" /YX /Fo"$(INTDIR)/" /Fd"$(INTDIR)/" /c +CPP_OBJS=.\Debug/ +CPP_SBRS=.\. +# ADD BASE MTL /nologo /D "_DEBUG" /win32 +# ADD MTL /nologo /D "_DEBUG" /win32 +MTL_PROJ=/nologo /D "_DEBUG" /win32 +# ADD BASE RSC /l 0x409 /d "_DEBUG" +# ADD RSC /l 0x409 /d "_DEBUG" +BSC32=bscmake.exe +# ADD BASE BSC32 /nologo +# ADD BSC32 /nologo +BSC32_FLAGS=/nologo /o"$(OUTDIR)/isle.bsc" +BSC32_SBRS= \ + +LINK32=link.exe +# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /debug /machine:I386 +# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib dsound.lib winmm.lib lib/lego1.lib /nologo /subsystem:windows /debug /machine:I386 +LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib\ + advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib\ + odbccp32.lib dsound.lib winmm.lib lib/lego1.lib /nologo /subsystem:windows\ + /incremental:yes /pdb:"$(OUTDIR)/isle.pdb" /debug /machine:I386\ + /out:"$(OUTDIR)/isle.exe" +LINK32_OBJS= \ + "$(INTDIR)\define.obj" \ + "$(INTDIR)\isle.obj" \ + "$(INTDIR)\main.obj" + +"$(OUTDIR)\isle.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS) + $(LINK32) @<< + $(LINK32_FLAGS) $(LINK32_OBJS) +<< + +!ENDIF + +.c{$(CPP_OBJS)}.obj: + $(CPP) $(CPP_PROJ) $< + +.cpp{$(CPP_OBJS)}.obj: + $(CPP) $(CPP_PROJ) $< + +.cxx{$(CPP_OBJS)}.obj: + $(CPP) $(CPP_PROJ) $< + +.c{$(CPP_SBRS)}.sbr: + $(CPP) $(CPP_PROJ) $< + +.cpp{$(CPP_SBRS)}.sbr: + $(CPP) $(CPP_PROJ) $< + +.cxx{$(CPP_SBRS)}.sbr: + $(CPP) $(CPP_PROJ) $< + +################################################################################ +# Begin Target + +# Name "isle - Win32 Release" +# Name "isle - Win32 Debug" + +!IF "$(CFG)" == "isle - Win32 Release" + +!ELSEIF "$(CFG)" == "isle - Win32 Debug" + +!ENDIF + +################################################################################ +# Begin Source File + +SOURCE=.\app\define.cpp +DEP_CPP_DEFIN=\ + ".\app\define.h"\ + + +"$(INTDIR)\define.obj" : $(SOURCE) $(DEP_CPP_DEFIN) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +# End Source File +################################################################################ +# Begin Source File + +SOURCE=.\app\isle.cpp +DEP_CPP_ISLE_=\ + ".\app\define.h"\ + ".\app\isle.h"\ + ".\lib\define.h"\ + ".\lib\legoanimationmanager.h"\ + ".\lib\legobuildingmanager.h"\ + ".\lib\legogamestate.h"\ + ".\lib\legoinputmanager.h"\ + ".\lib\legomodelpresenter.h"\ + ".\lib\legoomni.h"\ + ".\lib\legopartpresenter.h"\ + ".\lib\legoroi.h"\ + ".\lib\legovideomanager.h"\ + ".\lib\legoworldpresenter.h"\ + ".\lib\mxatomid.h"\ + ".\lib\mxbackgroundaudiomanager.h"\ + ".\lib\mxdirectdraw.h"\ + ".\lib\mxdsaction.h"\ + ".\lib\mxomni.h"\ + ".\lib\mxomnicreateflags.h"\ + ".\lib\mxomnicreateparam.h"\ + ".\lib\mxpalette.h"\ + ".\lib\mxrect32.h"\ + ".\lib\mxstreamcontroller.h"\ + ".\lib\mxstreamer.h"\ + ".\lib\mxstring.h"\ + ".\lib\mxticklemanager.h"\ + ".\lib\mxtimer.h"\ + ".\lib\mxtransitionmanager.h"\ + ".\lib\mxvariabletable.h"\ + ".\lib\mxvideoparam.h"\ + ".\lib\mxvideoparamflags.h"\ + + +"$(INTDIR)\isle.obj" : $(SOURCE) $(DEP_CPP_ISLE_) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +# End Source File +################################################################################ +# Begin Source File + +SOURCE=.\app\main.cpp +DEP_CPP_MAIN_=\ + ".\app\define.h"\ + ".\app\isle.h"\ + ".\lib\define.h"\ + ".\lib\legoanimationmanager.h"\ + ".\lib\legobuildingmanager.h"\ + ".\lib\legogamestate.h"\ + ".\lib\legoinputmanager.h"\ + ".\lib\legomodelpresenter.h"\ + ".\lib\legoomni.h"\ + ".\lib\legopartpresenter.h"\ + ".\lib\legoroi.h"\ + ".\lib\legovideomanager.h"\ + ".\lib\legoworldpresenter.h"\ + ".\lib\mxatomid.h"\ + ".\lib\mxbackgroundaudiomanager.h"\ + ".\lib\mxdsaction.h"\ + ".\lib\mxomnicreateflags.h"\ + ".\lib\mxomnicreateparam.h"\ + ".\lib\mxpalette.h"\ + ".\lib\mxrect32.h"\ + ".\lib\mxstreamcontroller.h"\ + ".\lib\mxstreamer.h"\ + ".\lib\mxstring.h"\ + ".\lib\mxticklemanager.h"\ + ".\lib\mxtimer.h"\ + ".\lib\mxtransitionmanager.h"\ + ".\lib\mxvariabletable.h"\ + ".\lib\mxvideoparam.h"\ + ".\lib\mxvideoparamflags.h"\ + + +"$(INTDIR)\main.obj" : $(SOURCE) $(DEP_CPP_MAIN_) "$(INTDIR)" + $(CPP) $(CPP_PROJ) $(SOURCE) + + +# End Source File +# End Target +# End Project +################################################################################ diff --git a/isle.mdp b/isle.mdp new file mode 100644 index 0000000000000000000000000000000000000000..311a68ed9887e486a54f7f88bf1a4fb92c2e0e2b GIT binary patch literal 36352 zcmeI4TXWk)6vvN}IM_)^n#3tkZlSc?8``AY%B5`_(jil3Xu?cp81t}^w$2i*q>LvOQ{L`Rci0y{1@~A?a(=TkqnE4bPX!yA&_109+byrcsf8}hMvp10Jb0i z0w4eaAOHddCGe-3qEocv{7fhG>(og>y@XpJ00JNY0w4eaHUfVnxF4|bDf+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K0BH)N9X<||zLd)OZAS?rq}djzIAj+%F^Hl;7FfGe6+iC{C}pnQTbnO zvX#+!RvuKrY7cBPu7*pkzc7wfLa0qp`X6l|UBeewz!f+&6xc)lP5b}S`u`p{9q&(h zE;(-Yjtnwja=c|I%L(pMd4Qsy3 zQe(~jQ-A-d#`<-i+W#Lnu7RsK!>z_yxSI3dC$7)u>R>%V(jVEB#vbY1Kec3vbN(pB zlD-4Y4@~F(y`BEt&78Mrtoq^#j2Z=MnM9T5f91A9v<#;IF0LT=X}s?=t5ymy~Z`Lu9#ucmiDiOG#|Ll{ObMFcwRh6 zo}EB`ZJfclSulBy`f6X7?q{(8wxB{-gs8V3(>+^rut^7}Y z@A-dJea!wauD}~AP|r)R)A~Oh|8IxW{IBtT#`MI*1L^yH_Q*!C} zpMF(QUY!4zOUL^g@O5Jgu{^d4J0J7K6>tSch61)_y3Qc&)T2F6*y3V zCtsKUL+)?N|2gmfKTs!US700p!a=*@Kf_w z!J5CH%(u^Iu0ToB$A26CdocC)C&v17m@lq?D{$y3(Ar7<-%ydh z>-WKW-_KBVkNGQL#RpG|Gx_AVd;0%*liv$>Ykq)!!=pI{oVP5UW4METW$JJI$pPs< zU|(DTSK#0(u!c;YzVA!t9g5cRS6q@@rV#a;Kb;-K|Bp%eAb;W}KNsKsrLscHC-AeL z)6^dQ{_jL%l?9qlFlfwcJd^TaJA5`5yNdKCY&W)#6UcmV1zZ7Fz!h)>Tme_W6>tSy Q0aw5ka0Og}gQLK|0cu%?)c^nh literal 0 HcmV?d00001 diff --git a/lib/define.h b/lib/define.h new file mode 100644 index 00000000..a591766f --- /dev/null +++ b/lib/define.h @@ -0,0 +1,8 @@ +#ifndef MX_DEFINE +#define MX_DEFINE + +typedef unsigned long MxResult; +const MxResult SUCCESS = 0; +const MxResult FAILURE = 0xFFFFFFFFL; + +#endif // MX_DEFINE diff --git a/lib/lego1.def b/lib/lego1.def new file mode 100644 index 00000000..eb8c8fb3 --- /dev/null +++ b/lib/lego1.def @@ -0,0 +1,137 @@ +; +; Definition file of Lego1.dll +; Automatic generated by gendef +; written by Kai Tietz 2008 +; +LIBRARY "Lego1.dll" +EXPORTS +??0LegoBackgroundColor@@QAE@PBD0@Z ; has WINAPI (@8) +??0LegoGameState@@QAE@XZ +??0LegoWorld@@QAE@XZ +??0MxAtomId@@QAE@PBDW4LookupMode@@@Z ; has WINAPI (@8) +??0MxBitmap@@QAE@XZ +??0MxCore@@QAE@XZ +??0MxCriticalSection@@QAE@XZ +??0MxDSAction@@QAE@XZ +??0MxDSFile@@QAE@PBDK@Z ; has WINAPI (@8) +??0MxOmniCreateFlags@@QAE@XZ +??0MxOmniCreateParam@@QAE@PBDPAUHWND__@@AAVMxVideoParam@@VMxOmniCreateFlags@@@Z ; has WINAPI (@16) +??0MxString@@QAE@ABV0@@Z ; has WINAPI (@4) +??0MxVideoParam@@QAE@AAV0@@Z ; has WINAPI (@4) +??0MxVideoParam@@QAE@AAVMxRect32@@PAVMxPalette@@KAAVMxVideoParamFlags@@@Z ; has WINAPI (@16) +??0MxVideoParam@@QAE@XZ +??0MxVideoParamFlags@@QAE@XZ +??1LegoEntity@@UAE@XZ +??1LegoGameState@@QAE@XZ +??1LegoWorld@@UAE@XZ +??1MXIOINFO@@QAE@XZ +??1MxAtomId@@QAE@XZ +??1MxBitmap@@UAE@XZ +??1MxCore@@UAE@XZ +??1MxCriticalSection@@QAE@XZ +??1MxDSAction@@UAE@XZ +??1MxDSFile@@UAE@XZ +??1MxPresenter@@UAE@XZ +??1MxString@@UAE@XZ +??1MxVideoParam@@QAE@XZ +??4MxAtomId@@QAEAAV0@ABV0@@Z ; has WINAPI (@4) +??4MxString@@QAEABV0@PBD@Z ; has WINAPI (@4) +??4MxVideoParam@@QAEAAV0@ABV0@@Z ; has WINAPI (@4) +??8MxPalette@@QAEEAAV0@@Z ; has WINAPI (@4) +?BackgroundAudioManager@@YAPAVMxBackgroundAudioManager@@XZ +?Close@MxDSFile@@UAEJXZ +?Close@MxStreamer@@QAEJPBD@Z ; has WINAPI (@4) +?CreateBackgroundAudio@LegoOmni@@QAEXXZ +?CreateInstance@LegoOmni@@SAXXZ +?CreatePalette@MxBitmap@@UAEPAVMxPalette@@XZ +?CreateStreamObject@@YAPAVMxDSObject@@PAVMxDSFile@@F@Z +?DestroyInstance@MxOmni@@SAXXZ +?Detach@MxPalette@@QAEXXZ +?DisableRMDevice@LegoVideoManager@@QAEHXZ +?DoneTickle@MxPresenter@@MAEXXZ +?Enable@MxBackgroundAudioManager@@QAEXE@Z ; has WINAPI (@4) +?Enable@MxPresenter@@UAEXE@Z ; has WINAPI (@4) +?EnableFullScreenMovie@LegoVideoManager@@QAEXEE@Z ; has WINAPI (@8) +?EnableRMDevice@LegoVideoManager@@QAEHXZ +?EndAction@MxPresenter@@UAEXXZ +?EventManager@@YAPAVMxEventManager@@XZ +?FlipToGDISurface@MxDirectDraw@@QAEHXZ +?GameState@@YAPAVLegoGameState@@XZ +?GetBufferSize@MxDSFile@@UAEKXZ +?GetCD@MxOmni@@SAPBDXZ +?GetCurrPathInfo@LegoOmni@@SAHPAPAVLegoPathBoundary@@AAH@Z +?GetDefaults@LegoNavController@@SAXPAHPAM11111111PAE@Z +?GetHD@MxOmni@@SAPBDXZ +?GetInstance@LegoOmni@@SAPAV1@XZ +?GetInstance@MxOmni@@SAPAV1@XZ +?GetInstance@MxScheduler@@SAPAV1@XZ +?GetNoCD_SourceName@@YAPBDXZ +?GetPartsThreshold@RealtimeView@@SAMXZ +?GetPrimaryBitDepth@MxDirectDraw@@SAHXZ +?GetRealTime@MxTimer@@QAEJXZ +?GetStreamBuffersNum@MxDSFile@@UAEKXZ +?GetUserMaxLOD@RealtimeView@@SAMXZ +?GetVariable@MxVariableTable@@QAEPBDPBD@Z ; has WINAPI (@4) +?Init@MxPresenter@@IAEXXZ +?InputManager@@YAPAVLegoInputManager@@XZ +?InvalidateRect@MxVideoManager@@QAEXAAVMxRect32@@@Z ; has WINAPI (@4) +?IsSound3D@MxOmni@@SAEXZ +?Lego@@YAPAVLegoOmni@@XZ +?Load@LegoGameState@@QAEJK@Z ; has WINAPI (@4) +?MSoundManager@@YAPAVMxSoundManager@@XZ +?MakeSourceName@@YAXPADPBD@Z +?MoveCursor@LegoVideoManager@@QAEXHH@Z ; has WINAPI (@8) +?MusicManager@@YAPAVMxMusicManager@@XZ +?NotificationManager@@YAPAVMxNotificationManager@@XZ +?Notify@MxCore@@UAEJAAVMxParam@@@Z ; has WINAPI (@4) +?Open@MxDSFile@@UAEJK@Z ; has WINAPI (@4) +?Open@MxStreamer@@QAEPAVMxStreamController@@PBDG@Z ; has WINAPI (@8) +?ParseExtra@MxPresenter@@MAEXXZ +?Pause@MxDirectDraw@@QAEHH@Z ; has WINAPI (@4) +?PickEntity@@YAPAVLegoEntity@@JJ@Z +?PickROI@@YAPAVLegoROI@@JJ@Z +?QueueEvent@LegoInputManager@@QAEXW4NotificationId@@EJJE@Z ; has WINAPI (@20) +?Read@MxBitmap@@UAEJPBD@Z ; has WINAPI (@4) +?Read@MxDSFile@@UAEJPAEK@Z ; has WINAPI (@8) +?RealizePalette@MxVideoManager@@UAEJPAVMxPalette@@@Z ; has WINAPI (@4) +?Register@LegoInputManager@@QAEXPAVMxCore@@@Z ; has WINAPI (@4) +?RemoveAll@ViewManager@@QAEXPAVViewROI@@@Z ; has WINAPI (@4) +?RemoveWorld@LegoOmni@@QAEXABVMxAtomId@@J@Z ; has WINAPI (@8) +?Save@LegoGameState@@QAEJK@Z ; has WINAPI (@4) +?Seek@MxDSFile@@UAEJJH@Z ; has WINAPI (@8) +?SerializePlayersInfo@LegoGameState@@QAEXF@Z ; has WINAPI (@4) +?SerializeScoreHistory@LegoGameState@@QAEXF@Z ; has WINAPI (@4) +?SetCD@MxOmni@@SAXPBD@Z +?SetDefaults@LegoNavController@@SAXHMMMMMMMMME@Z +?SetDeviceName@MxVideoParam@@QAEXPAD@Z ; has WINAPI (@4) +?SetDisplayBB@LegoROI@@QAEXH@Z ; has WINAPI (@4) +?SetDoMutex@MxCriticalSection@@SAXXZ +?SetHD@MxOmni@@SAXPBD@Z +?SetObjectName@MxDSObject@@QAEXPBD@Z ; has WINAPI (@4) +?SetOmniUserMessage@@YAXP6AXPBDH@Z@Z +?SetPartsThreshold@RealtimeView@@SAXM@Z +?SetSavePath@LegoGameState@@QAEXPAD@Z ; has WINAPI (@4) +?SetSound3D@MxOmni@@SAXE@Z +?SetUserMaxLOD@RealtimeView@@SAXM@Z +?SetVariable@MxVariableTable@@QAEXPAVMxVariable@@@Z ; has WINAPI (@4) +?SetVariable@MxVariableTable@@QAEXPBD0@Z ; has WINAPI (@8) +?SetWaitIndicator@MxTransitionManager@@QAEXPAVMxVideoPresenter@@@Z ; has WINAPI (@4) +?SoundManager@@YAPAVLegoSoundManager@@XZ +?Start@@YAJPAVMxDSAction@@@Z +?StartAction@MxPresenter@@UAEJPAVMxStreamController@@PAVMxDSAction@@@Z ; has WINAPI (@8) +?StartMultiTasking@MxScheduler@@QAEXK@Z ; has WINAPI (@4) +?Streamer@@YAPAVMxStreamer@@XZ +?Tickle@MxPresenter@@UAEJXZ +?TickleManager@@YAPAVMxTickleManager@@XZ +?Timer@@YAPAVMxTimer@@XZ +?TransitionManager@@YAPAVMxTransitionManager@@XZ +?UnRegister@LegoInputManager@@QAEXPAVMxCore@@@Z ; has WINAPI (@4) +?VariableTable@@YAPAVMxVariableTable@@XZ +?VideoManager@@YAPAVLegoVideoManager@@XZ +?configureLegoAnimationManager@LegoAnimationManager@@SAXH@Z +?configureLegoBuildingManager@LegoBuildingManager@@SAXH@Z +?configureLegoModelPresenter@LegoModelPresenter@@SAXH@Z +?configureLegoPartPresenter@LegoPartPresenter@@SAXHH@Z +?configureLegoROI@LegoROI@@SAXH@Z +?configureLegoWorldPresenter@LegoWorldPresenter@@SAXH@Z +_DllMain@12@12 diff --git a/lib/lego1.exp b/lib/lego1.exp new file mode 100644 index 0000000000000000000000000000000000000000..300d78fd0e2de13fbf715e9210396c9390a239da GIT binary patch literal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0Gb zULD!Kj0L!^ybfOI0cfl@ACB5*w+?Y8kFAEwy*bO?KeTG^=tj#grL zC@DF}Q+orVk1!{(D+3qtR~+&}M0emrKXDiJoeeAQJ`=(n&8$&jr=~E}C1h@YJnnJ| z?w--$PNkY)r>6LP(8JEWA8|aozUhGhly|iDep})qotnzK&xUYE>qZcl+4>QQvFOxY z2!v!)d#q&N#Ywg}iuGV3-b_4Lu2dfKx&sr_GZW)86O%JSRPkPd=q*e=oF3izVhBrY z*;rMGg_6>tJ3~YhghEMz5B@|8-#cB|Qm heAaRj}9V + +#include "mxomnicreateflags.h" +#include "mxstring.h" +#include "mxvideoparam.h" + +class MxOmniCreateParam +{ +public: + __declspec(dllexport) MxOmniCreateParam(const char *mediaPath, struct HWND__ *windowHandle, MxVideoParam &vparam, MxOmniCreateFlags flags); + + virtual void vtable00(); + +private: + MxString m_mediaPath; + HWND m_windowHandle; + MxVideoParam m_videoParam; + MxOmniCreateFlags m_createFlags; + +}; + +#endif // MXOMNICREATEPARAM_H diff --git a/lib/mxpalette.h b/lib/mxpalette.h new file mode 100644 index 00000000..6ed23153 --- /dev/null +++ b/lib/mxpalette.h @@ -0,0 +1,9 @@ +#ifndef MXPALETTE_H +#define MXPALETTE_H + +class MxPalette +{ +public: +}; + +#endif // MXPALETTE_H diff --git a/lib/mxrect32.h b/lib/mxrect32.h new file mode 100644 index 00000000..764117ec --- /dev/null +++ b/lib/mxrect32.h @@ -0,0 +1,13 @@ +#ifndef MXRECT32_H +#define MXRECT32_H + +class MxRect32 +{ +public: + int m_left; + int m_top; + int m_right; + int m_bottom; +}; + +#endif // MXRECT32_H diff --git a/lib/mxstreamcontroller.h b/lib/mxstreamcontroller.h new file mode 100644 index 00000000..d98699cd --- /dev/null +++ b/lib/mxstreamcontroller.h @@ -0,0 +1,21 @@ +#ifndef MXSTREAMCONTROLLER_H +#define MXSTREAMCONTROLLER_H + +class MxStreamController +{ +public: + int m_unk00; + int m_unk04; + int m_unk08; + int m_unk0c; + int m_unk10; + int m_unk14; + int m_unk18; + int m_unk1c; + int m_unk20; + MxAtomId atom; + int m_unk28; + int m_unk2c; +}; + +#endif // MXSTREAMCONTROLLER_H diff --git a/lib/mxstreamer.h b/lib/mxstreamer.h new file mode 100644 index 00000000..785c475b --- /dev/null +++ b/lib/mxstreamer.h @@ -0,0 +1,14 @@ +#ifndef MXSTREAMER_H +#define MXSTREAMER_H + +#include "mxstreamcontroller.h" + +class MxStreamer +{ +public: + __declspec(dllexport) MxStreamController *Open(const char *name, unsigned short p); + __declspec(dllexport) long Close(const char *p); + +}; + +#endif // MXSTREAMER_H diff --git a/lib/mxstring.h b/lib/mxstring.h new file mode 100644 index 00000000..a28e446c --- /dev/null +++ b/lib/mxstring.h @@ -0,0 +1,16 @@ +#ifndef MXSTRING_H +#define MXSTRING_H + +class MxString +{ +public: + +private: + int m_unk00; + int m_unk04; + int m_unk08; + int m_unk0c; + +}; + +#endif // MXSTRING_H diff --git a/lib/mxticklemanager.h b/lib/mxticklemanager.h new file mode 100644 index 00000000..ff27d76c --- /dev/null +++ b/lib/mxticklemanager.h @@ -0,0 +1,19 @@ +#ifndef MXTICKLEMANAGER_H +#define MXTICKLEMANAGER_H + +class MxTickleManager +{ +public: + virtual ~MxTickleManager(); + + virtual void vtable04(); + virtual void vtable08(); + virtual void vtable0c(); + virtual void vtable10(); + virtual void vtable14(); + virtual void vtable18(); + virtual void vtable1c(void *v, int p); + virtual void vtable20(); +}; + +#endif // MXTICKLEMANAGER_H diff --git a/lib/mxtimer.h b/lib/mxtimer.h new file mode 100644 index 00000000..35d888fa --- /dev/null +++ b/lib/mxtimer.h @@ -0,0 +1,10 @@ +#ifndef MXTIMER_H +#define MXTIMER_H + +class MxTimer +{ +public: + __declspec(dllexport) long GetRealTime(); +}; + +#endif // MXTIMER_H diff --git a/lib/mxtransitionmanager.h b/lib/mxtransitionmanager.h new file mode 100644 index 00000000..d91b4a4d --- /dev/null +++ b/lib/mxtransitionmanager.h @@ -0,0 +1,12 @@ +#ifndef MXTRANSITIONMANAGER_H +#define MXTRANSITIONMANAGER_H + +class MxVideoPresenter; + +class MxTransitionManager +{ +public: + void SetWaitIndicator(MxVideoPresenter *videoPresenter); +}; + +#endif // MXTRANSITIONMANAGER_H diff --git a/lib/mxvariabletable.h b/lib/mxvariabletable.h new file mode 100644 index 00000000..53868a22 --- /dev/null +++ b/lib/mxvariabletable.h @@ -0,0 +1,10 @@ +#ifndef MXVARIABLETABLE_H +#define MXVARIABLETABLE_H + +class MxVariableTable +{ +public: + __declspec(dllexport) void SetVariable(const char *key, const char *value); +}; + +#endif // MXVARIABLETABLE_H diff --git a/lib/mxvideoparam.h b/lib/mxvideoparam.h new file mode 100644 index 00000000..c5b7199f --- /dev/null +++ b/lib/mxvideoparam.h @@ -0,0 +1,32 @@ +#ifndef MXVIDEOPARAM_H +#define MXVIDEOPARAM_H + +#include "mxpalette.h" +#include "mxrect32.h" +#include "mxvariabletable.h" +#include "mxvideoparamflags.h" + +class MxVideoParam +{ +public: + __declspec(dllexport) MxVideoParam(); + __declspec(dllexport) MxVideoParam(MxRect32 &rect, MxPalette *pal, unsigned long p3, MxVideoParamFlags &flags); + + __declspec(dllexport) void SetDeviceName(char *id); + + inline MxVideoParamFlags &flags() { return m_flags; } + +private: + int m_left; + int m_top; + int m_right; + int m_bottom; + MxPalette *m_palette; + BOOL m_backBuffers; + MxVideoParamFlags m_flags; + int m_unk1c; + char *m_deviceId; + +}; + +#endif // MXVIDEOPARAM_H diff --git a/lib/mxvideoparamflags.h b/lib/mxvideoparamflags.h new file mode 100644 index 00000000..192eb397 --- /dev/null +++ b/lib/mxvideoparamflags.h @@ -0,0 +1,93 @@ +#ifndef MXVIDEOPARAMFLAGS_H +#define MXVIDEOPARAMFLAGS_H + +class MxVideoParamFlags +{ +public: + enum LowFlags + { + FULL_SCREEN = 0x1, + FLIP_SURFACES = 0x2, + BACK_BUFFERS = 0x4, + ENABLE_16BIT = 0x20, + WIDE_VIEW_ANGLE = 0x40 + }; + + enum HighFlags + { + UNKNOWN1 = 0x1, + UNKNOWN2 = 0x2 + }; + + __declspec(dllexport) MxVideoParamFlags(); + + inline void EnableFullScreen(BOOL e) + { + if (e) { + m_flags1 |= FULL_SCREEN; + } else { + m_flags1 &= ~FULL_SCREEN; + } + } + + inline void EnableFlipSurfaces(BOOL e) + { + if (e) { + m_flags1 |= FLIP_SURFACES; + } else { + m_flags1 &= ~FLIP_SURFACES; + } + } + + inline void EnableBackBuffers(BOOL e) + { + if (e) { + m_flags1 |= BACK_BUFFERS; + } else { + m_flags1 &= ~BACK_BUFFERS; + } + } + + inline void Enable16Bit(BOOL e) + { + if (e) { + m_flags1 |= ENABLE_16BIT; + } else { + m_flags1 &= ~ENABLE_16BIT; + } + } + + inline void EnableWideViewAngle(BOOL e) + { + if (e) { + m_flags1 |= WIDE_VIEW_ANGLE; + } else { + m_flags1 &= ~WIDE_VIEW_ANGLE; + } + } + + inline void EnableUnknown1(BOOL e) + { + if (e) { + m_flags2 |= UNKNOWN1; + } else { + m_flags2 &= ~UNKNOWN1; + } + } + + inline void EnableUnknown2(BOOL e) + { + if (e) { + m_flags2 |= UNKNOWN2; + } else { + m_flags2 &= ~UNKNOWN2; + } + } + +private: + unsigned char m_flags1; + unsigned char m_flags2; + +}; + +#endif // MXVIDEOPARAMFLAGS_H