diff options
author | WBoerenkamps <wrj.boerenkamps@student.avans.nl> | 2024-12-05 00:03:10 +0100 |
---|---|---|
committer | WBoerenkamps <wrj.boerenkamps@student.avans.nl> | 2024-12-05 00:03:10 +0100 |
commit | 8aa43f634c1a89f05681ffc5f3cd0a3477e50e71 (patch) | |
tree | a1321d75328da0952ba7bf294a8036f50debb60f /src/crepe/api/BehaviorScript.h | |
parent | d9e46281c1e24a5f23d779d314e5df87fa3317a3 (diff) | |
parent | cfb67ffddb9f4bb0357c2b9df4239bfee7364c5a (diff) |
added loopTimer to mediator and fixed update loop
Diffstat (limited to 'src/crepe/api/BehaviorScript.h')
-rw-r--r-- | src/crepe/api/BehaviorScript.h | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/src/crepe/api/BehaviorScript.h b/src/crepe/api/BehaviorScript.h index d556fe5..3909b96 100644 --- a/src/crepe/api/BehaviorScript.h +++ b/src/crepe/api/BehaviorScript.h @@ -23,14 +23,13 @@ class BehaviorScript : public Component { protected: /** * \param id Parent \c GameObject id - * \param component_manager Reference to component manager (passed through to \c Script - * instance) + * \param mediator Mediator reference * * \note Calls to this constructor (should) always pass through \c GameObject::add_component, * which has an exception for this specific component type. This was done so the user does * not have to pass references used within \c Script to each \c BehaviorScript instance. */ - BehaviorScript(game_object_id_t id, ComponentManager & component_manager); + BehaviorScript(game_object_id_t id, Mediator & mediator); //! Only ComponentManager is allowed to instantiate BehaviorScript friend class ComponentManager; @@ -55,8 +54,8 @@ protected: friend class ScriptSystem; protected: - //! Reference to component manager (passed to Script) - ComponentManager & component_manager; + //! Reference mediator + Mediator & mediator; }; /** |