Class Engine

Page Contents

Class Documentation

class Engine

Engine initialization. It is a starting point for Simple2DEngine. You can init engine with Engine engine(config) and start with engine.run().

Public Functions

Engine(const Configuration &config)

Engine initialization.

See
Configuration
Parameters

void run()

Start Engine. Call it after initialization and activation of scene.

void stop()

Stop Engine. You can call it in any scene. It will stop engine loop.

SceneManager &getSceneManager()

Get scene manager.

See
SceneManager.

AssetManager &getAssetManager()

Get asset manager.

See
AssetManager.

InputManager &getInputManager()

Get input manager.

See
InputManager.

const Configuration &getConfiguration()

Get current configuration.

See
Configuration.

sf::RenderWindow &getRenderWindow()

Get render window. It is used by SFML and needed for drawing objects.