Updated useEvent

This commit is contained in:
2023-02-28 22:18:26 -08:00
parent 8e04742d5a
commit 3f361130fd
10 changed files with 135 additions and 46 deletions

View File

@ -7,8 +7,13 @@
#include "assert/assert.hpp"
namespace Dawn {
class IStateProperty {
public:
std::vector<std::function<void()>> _effectListners;
};
template<class V>
class StateProperty {
class StateProperty : public IStateProperty {
private:
/**
* Method that is invoked every time that the value of this state property
@ -31,7 +36,6 @@ namespace Dawn {
public:
V _realValue;
std::vector<std::function<void()>> _effectListners;
V previous;
/**