Feature #152 and potential fix #320

- Added Lua scripts hud.open, inventory.create and inventory.remove
- Window now resizes even if it is not focused
This commit is contained in:
opchik98
2024-11-07 18:38:24 +02:00
parent 5faca685ec
commit 8e549fe806
11 changed files with 117 additions and 13 deletions
+3 -5
View File
@@ -72,11 +72,9 @@ bool Window::isFocused() {
void window_size_callback(GLFWwindow*, int width, int height) {
if (width && height) {
if (Window::isFocused()) {
glViewport(0, 0, width, height);
Window::width = width;
Window::height = height;
}
glViewport(0, 0, width, height);
Window::width = width;
Window::height = height;
if (!Window::isFullscreen() && !Window::isMaximized()) {
Window::getSettings()->width.set(width);