Lots of UI Component Updates
This commit is contained in:
@@ -16,6 +16,7 @@ namespace Dawn {
|
||||
public:
|
||||
SceneItem &item;
|
||||
Transform &transform;
|
||||
bool_t hasInitialized = false;
|
||||
|
||||
/**
|
||||
* Constructs a new SceneItemComponent. Components are attached to
|
||||
@@ -28,9 +29,17 @@ namespace Dawn {
|
||||
|
||||
/**
|
||||
* Requested on the first frame that the parent scene item has become
|
||||
* active.
|
||||
* active, after all of my dependencies are ready.
|
||||
*/
|
||||
virtual void start() = 0;
|
||||
void init();
|
||||
|
||||
/**
|
||||
* Optionally return all dependencies for this component to wait for init
|
||||
* for before the component will be initialized.
|
||||
*
|
||||
* @return Array of dependencies.
|
||||
*/
|
||||
virtual std::vector<SceneItemComponent*> getDependencies();
|
||||
|
||||
/**
|
||||
* Shorthand to return the scene that this component's item belongs to.
|
||||
@@ -44,6 +53,11 @@ namespace Dawn {
|
||||
*/
|
||||
DawnGame & getGame();
|
||||
|
||||
/**
|
||||
* Same as init, but intended for your subclass to override.
|
||||
*/
|
||||
virtual void onStart();
|
||||
|
||||
/**
|
||||
* Cleanup the SceneItemComponent.
|
||||
*/
|
||||
|
Reference in New Issue
Block a user