![]() |
SpaceRTS - Starter Pack
1.3
|
Core Component for each interactable Entity in the Game. Acts as a Controller for the visual Avatar through its ComponentProxy. More...
Public Member Functions | |
void | ChangeVisualModule (ComponentProxy newVisualModule) |
Change the visual module of this GameEntity. If already has a reference to a module than notifies to each GameEntityComponent that the VisualModule has been removed. Then assign the new module and notifies to each GameEntityComponent that a visual module has been set. More... | |
T | GetSceneSystem< T > () |
Returns a casted GameSceneSystem. More... | |
Static Public Member Functions | |
static IEnumerable< T > | Collect< T > (IEnumerable< GameEntity > entities) |
Collects all the components of type T from each GameEntity. Note that will return only components in the same GameObject of GameEntity and if they are found. More... | |
Public Attributes | |
ComponentProxy | visualModule |
Reference to the ComponentProxy located at the root of the controlled Avatar. More... | |
Protected Member Functions | |
virtual void | Start () |
Initialize the GameScene reference and if there is a VisualModule then notifies to each GameEntityComponent that it can initialize their own systems. More... | |
virtual void | OnDestroy () |
Properties | |
MessageSink | Messages [get] |
Returns the MessageSink class that belongs to this GameEntity. More... | |
ComponentProxy | VisualProxy [get] |
Returns the ComponentProxy (View) for this GameEntity (Controller) More... | |
GameScene | GameScene [get] |
Returns the GameScene where is located this GameEntity. More... | |
Core Component for each interactable Entity in the Game. Acts as a Controller for the visual Avatar through its ComponentProxy.
void GameBase.GameEntity.ChangeVisualModule | ( | ComponentProxy | newVisualModule | ) |
Change the visual module of this GameEntity. If already has a reference to a module than notifies to each GameEntityComponent that the VisualModule has been removed. Then assign the new module and notifies to each GameEntityComponent that a visual module has been set.
newVisualModule |
|
static |
Collects all the components of type T from each GameEntity. Note that will return only components in the same GameObject of GameEntity and if they are found.
T |
entities | Collection of GameEntity where to find the components. |
T GameBase.GameEntity.GetSceneSystem< T > | ( | ) |
Returns a casted GameSceneSystem.
T | must inherit from GameSceneSystem. |
T | : | GameSceneSystem |
|
protectedvirtual |
|
protectedvirtual |
Initialize the GameScene reference and if there is a VisualModule then notifies to each GameEntityComponent that it can initialize their own systems.
ComponentProxy GameBase.GameEntity.visualModule |
Reference to the ComponentProxy located at the root of the controlled Avatar.
|
get |
Returns the GameScene where is located this GameEntity.
|
get |
Returns the MessageSink class that belongs to this GameEntity.
|
get |
Returns the ComponentProxy (View) for this GameEntity (Controller)