nucleus/wrappers/windows/main.cpp
Alexandro Sanchez Bach cca12b2990 Fixed SELF loader issues
2017-10-29 15:27:33 +01:00

39 lines
762 B
C++

/**
* (c) 2014-2016 Alexandro Sanchez Bach. All rights reserved.
* Released under GPL v2 license. Read LICENSE for more details.
*/
#include "window.h"
// Nucleus
#include "nucleus/nucleus.h"
#include "nucleus/core/config.h"
#include <thread>
int main(int argc, char **argv) {
// Load configuration
nucleusConfigure(argc, argv);
// Using UI
if (!config.console) {
unsigned int width = 960;
unsigned int height = 544;
Window window("Nucleus", width, height);
nucleusInitialize(window.hwnd, window.hdc, width, height);
auto thread = std::thread([]{
nucleusStart();
});
window.loop();
}
// Using console
else {
nucleusStart();
}
return 0;
}