5#include "../Gameworld/gameworld.h"
24 void update(
float deltaTime,
float time);
105 class AppExclusiveGameWorld :
public GameWorld {
107 virtual ~AppExclusiveGameWorld();
109 bool started =
false;
110 void runStageStartup();
111 void runStageUpdate(
float deltaTime,
float time);
112 void runStageFixedUpdate(
float deltaTime,
float time);
114 void runStageCleanup();
115 void keyEvent(
int key,
int action);
116 void mousePosEvent(
double xpos,
double ypos);
117 void mouseButtonEvent(
int button,
int action);
118 void scrollEvent(
double distance);
119 void windowResizeEvent(
int width,
int height);
121 std::vector<std::shared_ptr<AppExclusiveGameWorld>> worlds;
Manages several GameWorld. Responsible for assembling them and passing along Staged events as well as...
Definition: app.h:14
std::shared_ptr< GameWorld > createGameWorld()
Create a Game World object.
Definition: app.cpp:77
void draw()
Invoke the Draw stage of any managed World.
Definition: app.cpp:38
void windowResizeEvent(int width, int height)
Invoked whenever the user resize the window.
Definition: app.cpp:71
void scrollEvent(double distance)
Invoke a scroll event, that happens when the user scroll with the mouse.
Definition: app.cpp:62
void keyEvent(int key, int action)
Invoke a keyboard event.
Definition: app.cpp:44
virtual ~App()
Definition: app.cpp:12
void mousePosEvent(double xpos, double ypos)
Invoke a mouse position event. This happens whenever the mouse changes position.
Definition: app.cpp:50
void update(float deltaTime, float time)
This invokes the Update stages of any world, or the Start stage if this is the world's first frame.
Definition: app.cpp:22
void framebufferResizeEvent(int width, int height)
Invoked whenever the framebuffer needs to be resized.
Definition: app.cpp:68
void mouseButtonEvent(int button, int action)
Invoke a mouse button event.
Definition: app.cpp:56
App()
Definition: app.cpp:9
void removeGameWorld(std::shared_ptr< GameWorld > world)
Remove a GameWorld.
Definition: app.cpp:85
void fixedUpdate(float deltaTime, float time)
This invokes the FixedUpdate stages of any world, if that world has been started. Fixed updates shoul...
Definition: app.cpp:32
Maintains a game world, where Entity, Component, Systems, and MetaSystems can be added,...
Definition: gameworld.h:28