mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-04 18:41:51 +00:00
add gui.get_active_frame, set_active_frame & update cursor lock behavior
This commit is contained in:
parent
463098aa1e
commit
8468ab184d
11 changed files with 123 additions and 50 deletions
|
|
@ -302,10 +302,12 @@ void Engine::startPauseLoop() {
|
|||
}
|
||||
|
||||
void Engine::renderFrame() {
|
||||
if (input->isCursorLocked() != (gui->getActiveFrame() == nullptr)) {
|
||||
input->toggleCursor();
|
||||
}
|
||||
screen->draw(time.getDelta());
|
||||
|
||||
DrawContext ctx(nullptr, *window, nullptr);
|
||||
gui->renderFrames(ctx, *assets->getStorage());
|
||||
gui->draw(ctx, *assets->getStorage());
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue