Fixed compilation errors

Signed-off-by: Robear Selwans <robear.selwans@outlook.com>
This commit is contained in:
2021-06-08 19:15:15 +02:00
parent 173d9df4c8
commit 3557199b35
2 changed files with 9 additions and 2 deletions

View File

@@ -13,6 +13,10 @@
{ {
"path": "./res/scenes", "path": "./res/scenes",
"mountpoint": "scenes" "mountpoint": "scenes"
},
{
"path": "./res/shaders",
"mountpoint": "shaders"
} }
], ],
"scenes": [ "scenes": [

View File

@@ -12,6 +12,8 @@
#include IMPORT_MODULE_H #include IMPORT_MODULE_H
#define IMPORT_MODULE evmod_game #define IMPORT_MODULE evmod_game
#include IMPORT_MODULE_H #include IMPORT_MODULE_H
#define IMPORT_MODULE evmod_renderer
#include IMPORT_MODULE_H
// Close window when Q is pressed // Close window when Q is pressed
DECLARE_EVENT_LISTENER(keyPressedListener, (KeyPressedEvent *event) { DECLARE_EVENT_LISTENER(keyPressedListener, (KeyPressedEvent *event) {
@@ -40,7 +42,7 @@ int main(int argc, char **argv)
imports(game_mod , (Game, Object, Camera, Scene)) imports(game_mod , (Game, Object, Camera, Scene))
imports(window_mod , (Window)) imports(window_mod , (Window))
imports(input_mod , (Input)) imports(input_mod , (Input))
imports(renderer_mod,(Renderer)) imports(renderer_mod, (Renderer))
IMPORT_EVENTS_evmod_glfw(window_mod); IMPORT_EVENTS_evmod_glfw(window_mod);
U32 width = 800; U32 width = 800;
@@ -48,7 +50,6 @@ int main(int argc, char **argv)
WindowHandle windowHandle = Window->create(width, height, "Main Window"); WindowHandle windowHandle = Window->create(width, height, "Main Window");
Input->setActiveWindow(windowHandle); Input->setActiveWindow(windowHandle);
Renderer->setWindow(windowHandle);
ACTIVATE_EVENT_LISTENER(keyPressedListener, KeyPressedEvent); ACTIVATE_EVENT_LISTENER(keyPressedListener, KeyPressedEvent);
evstring project_dir = NULL; evstring project_dir = NULL;
@@ -125,6 +126,8 @@ int main(int argc, char **argv)
rmt_SetCurrentThreadName("Main Thread"); rmt_SetCurrentThreadName("Main Thread");
Renderer->setWindow(windowHandle);
U32 result = 0; U32 result = 0;
while(result == 0) { while(result == 0) {
ev_ProfileCPU(WindowUpdate, 0) { ev_ProfileCPU(WindowUpdate, 0) {