SUNENGINE 0.0.2
A simple and bright C++ game engine.
 
Loading...
Searching...
No Matches
UpdatableAttorney.h
1#ifndef UpdatableAttorney_H
2#define UpdatableAttorney_H
3
4#include "Updatable.h"
5
14{
15 public:
21 {
22 friend class UpdatableManager;
23
28 static void Update(Updatable* p) { p->Update(); }
29
36 };
37 public:
43 {
44 friend class UpdateRegistrationCommand;
45 friend class UpdateDeregistrationCommand;
46
47 private:
53
59 };
60};
61
62#endif
Provides access to the game loop related functions of Updatable.
Definition UpdatableAttorney.h:21
static UpdatableManager::StorageListRef & GetRef(Updatable *p)
Retrieves the storage list reference of the Updatable object.
Definition UpdatableAttorney.h:35
static void Update(Updatable *p)
Calls the Update method of the Updatable object.
Definition UpdatableAttorney.h:28
Provides access to the registration related functions of Updatable.
Definition UpdatableAttorney.h:43
static void SceneRegistration(Updatable *p)
Registers the Updatable object for updates in the scene.
Definition UpdatableAttorney.h:52
static void SceneDeregistration(Updatable *p)
Deregisters the Updatable object from updates in the scene.
Definition UpdatableAttorney.h:58
Provides controlled access to the Updatable class for specific classes.
Definition UpdatableAttorney.h:14
Base class for objects that can be updated in the game loop.
Definition Updatable.h:19
void SceneRegistration()
Registers the GameObject for updates in the scene.
Definition Updatable.cpp:36
void SceneDeregistration()
Deregisters the GameObject from updates in the scene.
Definition Updatable.cpp:43
UpdatableManager::StorageListRef pMyDeleteRef
Reference to the storage list iterator for the GameObject.
Definition Updatable.h:57
virtual void Update()
Virtual method to be implemented by derived classes for update functionality.
Definition Updatable.h:62
StorageList::iterator StorageListRef
Type alias for the storage list iterator.
Definition UpdatableManager.h:56