Scene fixing
This commit is contained in:
@@ -6,6 +6,7 @@
|
||||
*/
|
||||
|
||||
#include "display/display.h"
|
||||
#include "engine/engine.h"
|
||||
#include "console/console.h"
|
||||
#include "display/framebuffer.h"
|
||||
#include "scene/scenemanager.h"
|
||||
@@ -77,14 +78,14 @@ errorret_t displayUpdate(void) {
|
||||
while(SDL_PollEvent(&event)) {
|
||||
switch(event.type) {
|
||||
case SDL_QUIT: {
|
||||
consoleExec("quit");
|
||||
ENGINE.running = false;
|
||||
break;
|
||||
}
|
||||
|
||||
case SDL_WINDOWEVENT: {
|
||||
switch(event.window.event) {
|
||||
case SDL_WINDOWEVENT_CLOSE: {
|
||||
consoleExec("quit");
|
||||
ENGINE.running = false;
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -122,9 +123,9 @@ errorret_t displayUpdate(void) {
|
||||
SDL_GL_SwapWindow(DISPLAY.window);
|
||||
#endif
|
||||
|
||||
GLenum err = glGetError();
|
||||
if (err != GL_NO_ERROR) {
|
||||
printf("GL Error: %d\n", err);
|
||||
GLenum err;
|
||||
while((err = glGetError()) != GL_NO_ERROR) {
|
||||
consolePrint("GL Error: %d\n", err);
|
||||
}
|
||||
|
||||
// For now, we just return an OK error.
|
||||
|
Reference in New Issue
Block a user