3 * Iter Vehemens ad Necem (IVAN)
4 * Copyright (C) Timo Kiviluoto
5 * Released under the GNU General
8 * See LICENSING which should be included
9 * along with this file for more details
27 int Main (int argc
, char **argv
) {
28 if (argc
> 1 && (!strcmp(argv
[1], "--version") || !strcmp(argv
[1], "-v"))) {
29 std::cout
<< "Iter Vehemens ad Necem version " << IVAN_VERSION
<< std::endl
;
33 femath::SetSeed(time(0));
34 game::InitGlobalValueMap();
35 scriptsystem::Initialize();
36 databasesystem::Initialize();
38 ivanconfig::Initialize();
40 game::CreateBusyAnimationCache();
41 globalwindowhandler::SetQuitMessageHandler(game::HandleQuitMessage
);
43 protosystem::Initialize();
47 int Select
= iosystem::Menu(
48 igraph::GetMenuGraphic(),
49 v2(RES
.X
/ 2, RES
.Y
/ 2 - 20),
51 CONST_S("Start Game\rContinue Game\rConfiguration\rHighscores\rQuit\r"),
53 CONST_S("Released under the GNU\rGeneral Public License\rMore info: see COPYING\r"),
54 CONST_S("IVAN v" IVAN_VERSION
"\r"),
57 case -1: return 0; // esc
67 festring LoadName
= iosystem::ContinueMenu(WHITE
, LIGHT_GRAY
, game::GetSaveDir());
68 if (LoadName
.GetSize()) {
69 LoadName
.Resize(LoadName
.GetSize()-4);
70 if (game::Init(LoadName
)) {
93 int PASCAL
WinMain (HINSTANCE hInstance
, HINSTANCE hPrevInstance
, LPSTR lpszCmdLine
, int nCmdShow
) {
94 //return Main(argc, argv);
96 static char *argv
[2] = { "ivan.exe", NULL
};