SpaceRTS - Starter Pack  1.3
NullPointerGame.DamageSystem.Damageable Class Reference
Inheritance diagram for NullPointerGame.DamageSystem.Damageable:
GameBase.GameEntityComponent

Public Member Functions

override void OnVisualModuleSetted ()
 Called when the Visual Module is setted. Here we need to initialize all the component related functionality. More...
 
override void OnVisualModuleRemoved ()
 Called when the Visual Module is removed. Here we need to uninitialize all the component related functionality. More...
 
bool IsAlive ()
 
void ShowTargetedMarker (bool show)
 
void ShowTargetedConfirmMarker ()
 
void ShowValidTargetMarker ()
 
void OnDamageReceived (DamageType damage)
 
virtual void ApplyFixedDamage (float fixedAmmount)
 
virtual void ApplyFixedHeal (float fixedHeal)
 
virtual void ApplyFactorDamage (float damageFactor)
 
virtual void ApplyFactorHeal (float healFactor)
 
virtual void Explode ()
 

Public Attributes

ProxyRef volume = new ProxyRef(typeof(SphereCollider), "volume")
 
ProxyRef explodeAnimator = new ProxyRef(typeof(Animator), "animator")
 
ProxyRef targetableAnimator = new ProxyRef(typeof(Animator), "targetable_anim")
 
string explodeAnimParam = "Explode"
 
string targetedAnimParam = "Targeted"
 
string targetConfirmAnimParam = "TargetedConfirm"
 
float damageResistance = 100.0f
 
bool removeOnExplode = true
 
float removeDelay = 4.0f
 
Action UnitDestroyed
 

Properties

float MaxHP [get]
 
float HP [get]
 
float HealthFactor [get]
 
Vector3 Position [get]
 
- Properties inherited from GameBase.GameEntityComponent
GameEntity ThisEntity [get]
 The GameEntity attached to this component. More...
 
MessageSink Messages [get]
 Shortcut for the Message sink located at the GameEntity attached to this component. More...
 
ComponentProxy VisualProxy [get]
 Shortcut for the ComponentProxy located at the GameEntity attached to this component. More...
 

Additional Inherited Members

- Protected Member Functions inherited from GameBase.GameEntityComponent
virtual void SetupEntityComponent ()
 virtual class to be implemented. This will be called on the Awake to do a proper initialization of the component ensuring that the GameEntity thisEntity it's already defined at this point. Version 1.1: This will no longer be used in the future. Use instead OnVisualModuleSetted and OnVisualModuleRemoved. More...
 
virtual void OnValidate ()
 Called by unity when the script is reloaded. Here we setup the component and check that all is setted correctly. More...
 
GetSceneSystem< T > ()
 Shortcut for access a SceneSystem registered in the GameScene. More...
 
GetVisualProxyProperty< T > (string name)
 Shortcut for access the property located at the GameEntity visual module. More...
 
void LogsClear ()
 Clears all log messages More...
 
void Log (string message)
 Stores the message as a log that can be used later to show a warning in the editor or console. More...
 
void PushLogs ()
 Push all the stored logs to the console. More...
 

Member Function Documentation

◆ ApplyFactorDamage()

virtual void NullPointerGame.DamageSystem.Damageable.ApplyFactorDamage ( float  damageFactor)
virtual

◆ ApplyFactorHeal()

virtual void NullPointerGame.DamageSystem.Damageable.ApplyFactorHeal ( float  healFactor)
virtual

◆ ApplyFixedDamage()

virtual void NullPointerGame.DamageSystem.Damageable.ApplyFixedDamage ( float  fixedAmmount)
virtual

◆ ApplyFixedHeal()

virtual void NullPointerGame.DamageSystem.Damageable.ApplyFixedHeal ( float  fixedHeal)
virtual

◆ Explode()

virtual void NullPointerGame.DamageSystem.Damageable.Explode ( )
virtual

◆ IsAlive()

bool NullPointerGame.DamageSystem.Damageable.IsAlive ( )

◆ OnDamageReceived()

void NullPointerGame.DamageSystem.Damageable.OnDamageReceived ( DamageType  damage)

◆ OnVisualModuleRemoved()

override void NullPointerGame.DamageSystem.Damageable.OnVisualModuleRemoved ( )
virtual

Called when the Visual Module is removed. Here we need to uninitialize all the component related functionality.

Reimplemented from GameBase.GameEntityComponent.

◆ OnVisualModuleSetted()

override void NullPointerGame.DamageSystem.Damageable.OnVisualModuleSetted ( )
virtual

Called when the Visual Module is setted. Here we need to initialize all the component related functionality.

Reimplemented from GameBase.GameEntityComponent.

◆ ShowTargetedConfirmMarker()

void NullPointerGame.DamageSystem.Damageable.ShowTargetedConfirmMarker ( )

◆ ShowTargetedMarker()

void NullPointerGame.DamageSystem.Damageable.ShowTargetedMarker ( bool  show)

◆ ShowValidTargetMarker()

void NullPointerGame.DamageSystem.Damageable.ShowValidTargetMarker ( )

Member Data Documentation

◆ damageResistance

float NullPointerGame.DamageSystem.Damageable.damageResistance = 100.0f

◆ explodeAnimator

ProxyRef NullPointerGame.DamageSystem.Damageable.explodeAnimator = new ProxyRef(typeof(Animator), "animator")

◆ explodeAnimParam

string NullPointerGame.DamageSystem.Damageable.explodeAnimParam = "Explode"

◆ removeDelay

float NullPointerGame.DamageSystem.Damageable.removeDelay = 4.0f

◆ removeOnExplode

bool NullPointerGame.DamageSystem.Damageable.removeOnExplode = true

◆ targetableAnimator

ProxyRef NullPointerGame.DamageSystem.Damageable.targetableAnimator = new ProxyRef(typeof(Animator), "targetable_anim")

◆ targetConfirmAnimParam

string NullPointerGame.DamageSystem.Damageable.targetConfirmAnimParam = "TargetedConfirm"

◆ targetedAnimParam

string NullPointerGame.DamageSystem.Damageable.targetedAnimParam = "Targeted"

◆ UnitDestroyed

Action NullPointerGame.DamageSystem.Damageable.UnitDestroyed

◆ volume

ProxyRef NullPointerGame.DamageSystem.Damageable.volume = new ProxyRef(typeof(SphereCollider), "volume")

Property Documentation

◆ HealthFactor

float NullPointerGame.DamageSystem.Damageable.HealthFactor
get

◆ HP

float NullPointerGame.DamageSystem.Damageable.HP
get

◆ MaxHP

float NullPointerGame.DamageSystem.Damageable.MaxHP
get

◆ Position

Vector3 NullPointerGame.DamageSystem.Damageable.Position
get