KarmaEngine
Game Engine for practical learning and research purposes
Loading...
Searching...
No Matches
EntryPoint.h
Go to the documentation of this file.
1
10#pragma once
11#include "Karma.h"
12
13// Karma's entry point
14
15// If we are on Windows
16#ifdef KR_WINDOWS_PLATFORM
17
18// CreateApplication should be implemented in client
24
35int main(int argc, char** argv)
36{
37 // TODO: add engine initialization code for various systems
39 KR_INFO("Hello Cowboy. Your lucky number is {0}", 7);
40
41 auto app = Karma::CreateApplication();
42
44
45 app->PrepareApplicationForRun();
46 app->Run();
47
48 delete app;
49
51
52 return 0;
53}
54
55// If we are on Linux
56#elif defined KR_LINUX_PLATFORM
57
58// CreateApplication should be implemented in client
69int main(int argc, char** argv)
70{
71 // TODO: add engine initialization code for various systems
73 KR_INFO("Hello Cowboy. Your lucky number is {0}", 7);
74
75 auto app = Karma::CreateApplication();
76
78
79 app->PrepareApplicationForRun();
80 app->Run();
81
82 delete app;
83
85
86 return 0;
87}
88
89// If we are on Mac
90#elif defined KR_MAC_PLATFORM
91
92// CreateApplication should be implemented in client
94
104int main(int argc, char** argv)
105{
106 // TODO: add engine initialization code for various systems
108 KR_INFO("Hello Cowboy. Your lucky number is {0}", 7);
109
110 auto app = Karma::CreateApplication();
111
113
114 app->PrepareApplicationForRun();
115 app->Run();
116 delete app;
117
119
120 return 0;
121}
122
123#endif
Application * CreateApplication()
Declaration of client definable routine.
#define KR_INFO(...)
A macro for logging information in the Client part.
Definition Log.h:117
The class for Game + Editor in application form.
Definition Application.h:48
static void DeInit()
Deinitialize the Input system.
Definition Input.h:257
static void Init()
Initialize the Input system for Karma.
Definition Input.cpp:126
static void Init()
Initializes the logging class.
Definition Log.cpp:8