| 2523 | |
| 2524 | #if !defined(PGE_USE_CUSTOM_START) |
| 2525 | olc::rcode PixelGameEngine::Start() |
| 2526 | { |
| 2527 | if (platform->ApplicationStartUp() != olc::OK) return olc::FAIL; |
| 2528 | |
| 2529 | // Construct the window |
| 2530 | if (platform->CreateWindowPane({ 30,30 }, vWindowSize, bFullScreen) != olc::OK) return olc::FAIL; |
| 2531 | olc_UpdateWindowSize(vWindowSize.x, vWindowSize.y); |
| 2532 | |
| 2533 | // Start the thread |
| 2534 | bAtomActive = true; |
| 2535 | std::thread t = std::thread(&PixelGameEngine::EngineThread, this); |
| 2536 | |
| 2537 | // Some implementations may form an event loop here |
| 2538 | platform->StartSystemEventLoop(); |
| 2539 | |
| 2540 | // Wait for thread to be exited |
| 2541 | t.join(); |
| 2542 | |
| 2543 | if (platform->ApplicationCleanUp() != olc::OK) return olc::FAIL; |
| 2544 | |
| 2545 | return olc::OK; |
| 2546 | } |
| 2547 | #endif |
| 2548 | |
| 2549 | void PixelGameEngine::SetDrawTarget(Sprite* target) |
no test coverage detected