Skyscraper
2.0
src
frontend
main.cpp
Go to the documentation of this file.
1
/*
2
Skyscraper 2.1 - Simulation Frontend
3
Copyright (C)2003-2025 Ryan Thoryk
4
https://www.skyscrapersim.net
5
https://sourceforge.net/projects/skyscraper/
6
Contact - ryan@skyscrapersim.net
7
8
This program is free software; you can redistribute it and/or
9
modify it under the terms of the GNU General Public License
10
as published by the Free Software Foundation; either version 2
11
of the License, or (at your option) any later version.
12
13
This program is distributed in the hope that it will be useful,
14
but WITHOUT ANY WARRANTY; without even the implied warranty of
15
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16
GNU General Public License for more details.
17
18
You should have received a copy of the GNU General Public License
19
along with this program; if not, write to the Free Software
20
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
21
*/
22
23
#ifdef USING_WX
24
#include "wx/wx.h"
25
#endif
26
27
#include "
skyscraper.h
"
28
#include "
vm.h
"
29
30
using namespace
SBS
;
31
32
#ifndef SW_SHOWNORMAL
33
#define SW_SHOWNORMAL 1
34
#endif
35
36
int
main
(
int
argc,
char
* argv[])
37
{
38
#if OGRE_PLATFORM == OGRE_PLATFORM_LINUX
39
//force X11 if on Wayland
40
setenv(
"GDK_BACKEND"
,
"x11"
,
false
);
41
#endif
42
43
#ifdef USING_WX
44
//main wxWidgets entry point
45
wxEntry(argc, argv);
46
#else
47
::Skyscraper::Skyscraper
*skyscraper = new ::Skyscraper::Skyscraper();
48
skyscraper->initApp();
49
while
(
true
)
50
{
51
skyscraper->
Loop
();
52
//std::this_thread::sleep_for(std::chrono::milliseconds(1));
53
}
54
skyscraper->closeApp();
55
return
0;
56
#endif
57
}
Skyscraper::Skyscraper
Definition
skyscraper.h:71
Skyscraper::Skyscraper::Loop
bool Loop()
Definition
skyscraper.cpp:391
main
int main(int argc, char *argv[])
Definition
main.cpp:36
SBS
Definition
skyscraper.h:45
skyscraper.h
vm.h
Generated by
1.11.0