-
Notifications
You must be signed in to change notification settings - Fork 15
/
main.cpp
27 lines (24 loc) · 935 Bytes
/
main.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#include "LawnApp.h"
#include "Resources.h"
#include "Sexy.TodLib/TodStringFile.h"
using namespace Sexy;
bool (*gAppCloseRequest)(); //[0x69E6A0]
bool (*gAppHasUsedCheatKeys)(); //[0x69E6A4]
SexyString (*gGetCurrentLevelName)();
//0x44E8F0
int WINAPI WinMain(_In_ HINSTANCE /* hInstance */, _In_opt_ HINSTANCE /* hPrevInstance */, _In_ LPSTR /* lpCmdLine */, _In_ int /* nCmdShow */)
{
TodStringListSetColors(gLawnStringFormats, gLawnStringFormatCount);
gGetCurrentLevelName = LawnGetCurrentLevelName;
gAppCloseRequest = LawnGetCloseRequest;
gAppHasUsedCheatKeys = LawnHasUsedCheatKeys;
gExtractResourcesByName = Sexy::ExtractResourcesByName;
gLawnApp = new LawnApp();
gLawnApp->mChangeDirTo = (!Sexy::FileExists("properties\\resources.xml") && Sexy::FileExists("..\\properties\\resources.xml")) ? ".." : ".";
gLawnApp->Init();
gLawnApp->Start();
gLawnApp->Shutdown();
if (gLawnApp)
delete gLawnApp;
return 0;
};