25 #include "EntityContainer.h" 27 #include "GraphicsApi.h" 28 #include "ModelContainer.h" 29 #include "RenderWindow.h" 30 #include "RenderStates.h" 32 #include "ViewContainer.h" 37 #ifndef DOXYGEN_SHOULD_SKIP_THIS 101 void processEvent(
Event& event);
115 void handleActions(
Window& window);
128 void update(
Time time);
192 void setActive(
bool active =
true);
201 bool isActive()
const;
226 bool isPaused()
const;
251 bool isHidden()
const;
268 m_views.addView(view);
277 m_actions.addAction(action);
286 m_models.addModel(model);
295 m_worldEntities.addEntity(entity);
304 return m_worldEntities.removeEntity(entity);
313 m_hudEntities.addEntity(entity);
322 return m_hudEntities.removeEntity(entity);
339 void setWorldViewCenter(
Vector2f center);
346 void setWorldViewSize(
Vector2f size);
382 virtual bool doEarlyProcessEvent(
Event& event);
387 virtual void doProcessEvent(
Event& event);
392 virtual void doHandleActions(
Window& window);
397 virtual void doUpdate(
Time time);
407 virtual void doPause();
412 virtual void doResume();
417 virtual void doHide();
422 virtual void doShow();
429 virtual void onActivityChange(
bool active);
443 enum class Visibility {
448 Visibility m_visibility;
451 Action m_closeWindowAction;
465 #ifndef DOXYGEN_SHOULD_SKIP_THIS View & getWorldView()
Get the world view.
Definition: Scene.h:366
2D camera that defines what region is shown on framebuffer
Definition: View.h:94
A set of actions.
Definition: Action.h:240
Screen view.
Definition: Views.h:354
Base class for all render targets (window, texture, ...)
Definition: RenderTarget.h:102
Define the states used for drawing to a RenderTarget.
Definition: RenderStates.h:82
void addHudEntity(Entity &entity)
Add a HUD entity to the scene.
Definition: Scene.h:312
View & getHudView()
Get the HUD view.
Definition: Scene.h:373
A container of views.
Definition: ViewContainer.h:52
void setClearColor(gf::Color4f color)
Set the new clear color.
Definition: Scene.h:162
Represents a time value.
Definition: Time.h:65
A collection of models.
Definition: ModelContainer.h:54
A game object that can be updated.
Definition: Model.h:46
The window is hidden (data in event.window)
void addWorldEntity(Entity &entity)
Add a world entity to the scene.
Definition: Scene.h:294
void addModel(Model &model)
Add a model to the scene.
Definition: Scene.h:285
A game entity.
Definition: Entity.h:53
Entity * removeWorldEntity(Entity *entity)
Remove a world entity from the scene.
Definition: Scene.h:303
A scene manager.
Definition: SceneManager.h:61
The namespace for gf classes.
Definition: Action.h:35
Extend view.
Definition: Views.h:220
An OS window.
Definition: Window.h:82
A 4D vector.
Definition: Vector.h:852
Entity * removeHudEntity(Entity *entity)
Remove a HUD entity from the scene.
Definition: Scene.h:321
The window is shown (data in event.window)
void addAction(Action &action)
Add an action to the scene.
Definition: Scene.h:276
An action that can be triggered by different controls.
Definition: Action.h:53
Defines a system event and its parameters.
Definition: Event.h:224
Adaptative view.
Definition: View.h:390
A scene in the game.
Definition: Scene.h:66
void addView(AdaptativeView &view)
Add a view to the scene.
Definition: Scene.h:267
gf::Color4f getClearColor() const
Get the current clear color.
Definition: Scene.h:172
A collection of entities.
Definition: EntityContainer.h:60