![]() |
MAGE
v0.171.0
Matthias Advanced Game Engine
|
#include <engine.hpp>
Public Member Functions | |
Engine (const EngineSetup &setup, rendering::DisplayConfiguration display_config) | |
Engine (const Engine &engine)=delete | |
Engine (Engine &&engine) noexcept | |
~Engine () | |
Engine & | operator= (const Engine &engine)=delete |
Engine & | operator= (Engine &&engine)=delete |
int | Run (UniquePtr< Scene > &&scene, int nCmdShow=SW_NORMAL) |
const input::Manager & | GetInputManager () const noexcept |
const rendering::Manager & | GetRenderingManager () const noexcept |
Scene * | GetScene () const noexcept |
void | RequestScene (UniquePtr< Scene > &&scene) noexcept |
const GameTime & | GetTime () const noexcept |
Private Member Functions | |
void | InitializeSystems (const EngineSetup &setup, rendering::DisplayConfiguration display_config) |
void | UninitializeSystems () noexcept |
void | ApplyRequestedScene () |
bool | UpdateInput () |
bool | UpdateRendering () |
bool | UpdateScripting () |
A class of engines.
|
explicit |
Constructs an engine from the given engine setup.
[in] | setup | A reference to an engine setup. |
[in] | display_config | The display configuration. |
Exception | Failed to initialize the engine. |
|
delete |
Constructs an engine from the given engine.
[in] | engine | A reference to the engine to copy. |
|
defaultnoexcept |
Constructs an engine by moving the given engine.
[in] | engine | A reference to the engine to move. |
mage::Engine::~Engine | ( | ) |
Destructs this engine.
|
private |
|
noexcept |
Returns the input manager of this engine.
|
noexcept |
Returns the rendering manager of this engine.
|
noexcept |
Returns the current scene of this engine.
|
noexcept |
Returns the game time of this game engine.
|
private |
Initializes the different systems of this engine.
[in] | setup | A reference to an engine setup. |
[in] | display_config | The display configuration. |
Exception | Failed to initialize at least one of the different systems of this engine. |
Copies the given engine to this engine.
[in] | engine | A reference to the engine to copy. |
Copies the given engine to this engine.
[in] | engine | A reference to the engine to move. |
Sets the scene of this engine to the given scene.
[in] | scene | A reference to the start scene. |
Runs this engine.
[in] | scene | A reference to the start scene. |
[in] | nCmdShow | Controls how the engine window is to be shown. |
0
, if the function terminates before entering the message loop. wParam
parameter contained in the WM_QUIT
message.
|
privatenoexcept |
Uninitializes the different systems of this engine.
|
private |
|
private |
|
private |
|
private |
Flag indicating whether the application is active or not.
|
private |
The fixed delta time (in seconds) of this engine.
If the fixed delta time is equal to zero, fixed delta time updates will be treated as non-fixed delta time updates by this engine.
|
private |
The fixed time budget (in seconds) of this engine.
|
private |
A flag indicating whether this engine has a requested scene.
A separate flag is needed, because the requested scene maybe nullptr
.
|
private |
A pointer to the input manager of this engine.
|
private |
The window message handler of this engine.
|
private |
Flag indicating whether the application should switch between full screen and windowed mode.
|
private |
A pointer to the rendering manager of this engine.
A pointer to the requested scene of this engine.
|
private |
The current time of this engine.
|
private |
The timer of this engine.