PropertyInterface
Nectunia.PropertyInterface.PropertyTriggerHandler Class Reference

Detailed Description

Allow to handle targeted Property on trigger.

This class is used as an example on how to create a custom tagged component wich will use Nectunia.PropetyInterface asset.

Inheritance diagram for Nectunia.PropertyInterface.PropertyTriggerHandler:
Nectunia.PropertyInterface.MonoBehaviourTagged

Properties

TypedValue TypedValue [get, set]
 The Typed value to apply on trigger. More...
 
ActionOnTrigger Action [get, set]
 The action to do on trigger. More...
 
bool AffectChildren [get, set]
 Does the handler have to change the children as well. More...
 
List< GameObject > Targets [get]
 List of all targets that have triggered the PropertyTriggerHandler. More...
 
- Properties inherited from Nectunia.PropertyInterface.MonoBehaviourTagged
TagID TagID [get, set]
 The TagID used by the component. More...
 
Tag.ValueType ValuesType [get, protected set]
 The Tag.ValueType of the component's values. More...
 
Tag Tag [get]
 Get from the Tags list the Tag wich have the same TagID than this component. More...
 
Texture2D Icon [get]
 Get the icon of the Tag More...
 

Public Types

enum  ActionOnTrigger { ActionOnTrigger.Add, ActionOnTrigger.ChangeTo }
 List of possible action. More...
 

Public Member Functions

void OnTriggerEnter (Collider other)
 Happens when an other object trigger the collider attached. More...
 
void OnTriggerExit (Collider other)
 Happens when a triggered object exit the collider attached. More...
 
void Update ()
 
- Public Member Functions inherited from Nectunia.PropertyInterface.MonoBehaviourTagged
virtual void UpdateValuesType ()
 Update ValuesType. More...
 
virtual bool CheckIntegrity ()
 Check if the Tag, ValuesType are good. Update the Icon anyway. More...
 
bool CheckValuesType (Tag tag)
 Check if the ValuesType is equals to the passed Tag.ValuesType. More...
 

Protected Member Functions

override void OnValuesTypeChanged ()
 Event triggered when the Type of the values changed. More...
 
- Protected Member Functions inherited from Nectunia.PropertyInterface.MonoBehaviourTagged
virtual void OnTagIDChanged ()
 Event triggered when TagID changed. More...
 
virtual void WarningUpdate ()
 Log a warning in the console to say the MonoBehaviourTagged have to be updated. More...
 
virtual void WarningUpdate (Tag tag)
 Log a warning in the console to say the MonoBehaviourTagged have to be updated. More...
 
virtual void WarningUnknownTag ()
 Log a warning in the console to say the MonoBehaviourTagged have an Unknown Tag. More...
 
virtual void WarningIconUpdated (Tag tag)
 Log a warning in the console to say the MonoBehaviourTagged icon have been automaticaly updated. More...
 

Additional Inherited Members

- Static Public Member Functions inherited from Nectunia.PropertyInterface.MonoBehaviourTagged
static List< MonoBehaviourTaggedGetMonoBehavioursTagged (bool includeInactive=false)
 Get all MonoBehaviourTagged in the current scene. More...
 
static List< MonoBehaviourTaggedGetMonoBehavioursTagged (TagID tagID, bool includeInactive=false)
 Get all MonoBehaviourTagged in the current scene wich have the passed TagID. More...
 
static List< MonoBehaviourTaggedGetMonoBehavioursTagged (GameObject target)
 Get all MonoBehaviourTagged in the target gameobject. More...
 
static List< MonoBehaviourTaggedGetMonoBehavioursTagged (GameObject target, TagID tagID)
 Get all MonoBehaviourTagged in the target gameobject wich have the passed TagID. More...
 
static void GetMonoBehavioursTagged (ref List< MonoBehaviourTagged > results, bool includeInactive=false)
 Get all MonoBehaviourTagged in the current scene. More...
 
static void GetMonoBehavioursTagged (TagID tagID, ref List< MonoBehaviourTagged > results, bool includeInactive=false)
 Get all MonoBehaviourTagged in the current scene wich have the passed TagID. More...
 
static void GetMonoBehavioursTagged (GameObject target, ref List< MonoBehaviourTagged > results)
 Get all MonoBehaviourTagged in the target gameobject. More...
 
static void GetMonoBehavioursTagged (GameObject target, TagID tagID, ref List< MonoBehaviourTagged > results)
 Get all MonoBehaviourTagged in the target gameobject wich have the passed TagID. More...
 
static List< MonoBehaviourTaggedGetMonoBehavioursTaggedInChildren (GameObject target, bool includeInactive=false)
 Get all MonoBehaviourTagged in the target gameobject and it's children. More...
 
static List< MonoBehaviourTaggedGetMonoBehavioursTaggedInChildren (GameObject target, TagID tagID, bool includeInactive=false)
 Get all MonoBehaviourTagged with the passed TagID in the target gameobject and it's children. More...
 
static void GetMonoBehavioursTaggedInChildren (GameObject target, ref List< MonoBehaviourTagged > results, bool includeInactive=false)
 Get all MonoBehaviourTagged in the target gameobject and it's children. More...
 
static void GetMonoBehavioursTaggedInChildren (GameObject target, TagID tagID, ref List< MonoBehaviourTagged > results, bool includeInactive=false)
 Get all MonoBehaviourTagged with the passed TagID in the target gameobject and it's children. More...
 
static MonoBehaviourTagged GetMonoBehaviourTagged (bool includeInactive=false)
 Get the First MonoBehaviourTagged in the current scene. More...
 
static MonoBehaviourTagged GetMonoBehaviourTagged (TagID tagID, bool includeInactive=false)
 Get the first MonoBehaviourTagged in the current scene wich have the passed TagID. More...
 
static MonoBehaviourTagged GetMonoBehaviourTagged (GameObject target)
 Get the first MonoBehaviourTagged in the target gameobject. . More...
 
static MonoBehaviourTagged GetMonoBehaviourTagged (GameObject target, TagID tagID)
 Get the first MonoBehaviourTagged in the target gameobject wich have the passed TagID. More...
 
static void GetMonoBehaviourTagged (ref MonoBehaviourTagged result, bool includeInactive=false)
 Get the first MonoBehaviourTagged in the current scene. More...
 
static void GetMonoBehaviourTagged (TagID tagID, ref MonoBehaviourTagged result, bool includeInactive=false)
 Get the first MonoBehaviourTagged in the current scene wich have the passed TagID. More...
 
static void GetMonoBehaviourTagged (GameObject target, ref MonoBehaviourTagged result)
 Get the first MonoBehaviourTagged in the target gameobject. More...
 
static void GetMonoBehaviourTagged (GameObject target, TagID tagID, ref MonoBehaviourTagged result)
 Get the first MonoBehaviourTagged in the target gameobject wich have the passed TagID. More...
 
static MonoBehaviourTagged GetMonoBehaviourTaggedInChildren (GameObject target, bool includeInactive=false)
 Get the first MonoBehaviourTagged in the target gameobject and it's children. More...
 
static MonoBehaviourTagged GetMonoBehaviourTaggedInChildren (GameObject target, TagID tagID, bool includeInactive=false)
 Get the first MonoBehaviourTagged with the passed TagID in the target gameobject and it's children. More...
 
static void GetMonoBehaviourTaggedInChildren (GameObject target, ref MonoBehaviourTagged result, bool includeInactive=false)
 Get the first MonoBehaviourTagged in the target gameobject and it's children. More...
 
static void GetMonoBehaviourTaggedInChildren (GameObject target, TagID tagID, ref MonoBehaviourTagged result, bool includeInactive=false)
 Get the first MonoBehaviourTagged with the passed TagID in the target gameobject and it's children. More...
 
static bool Exists (bool includeInactive=false)
 Return True if at least one MonoBehaviourTagged exists in the current scene or False otherwise. More...
 
static bool Exists (TagID tagId, bool includeInactive=false)
 Return True if at least one MonoBehaviourTagged with passed TagID exists in the current scene or False otherwise. More...
 
static bool Exists (GameObject target)
 Return True if at least one MonoBehaviourTagged exists in the target gameobject or False otherwise. More...
 
static bool Exists (GameObject target, TagID tagId)
 Return True if at least one MonoBehaviourTagged with passed TagID exists in the target gameobject or False otherwise. More...
 
static bool ExistsInChildren (GameObject target, bool includeInactive=false)
 Return True if at least one MonoBehaviourTagged exists in the target gameobject and its children or False otherwise. More...
 
static bool ExistsInChildren (GameObject target, TagID tagId, bool includeInactive=false)
 Return True if at least one MonoBehaviourTagged with passed TagID exists in the target gameobject and its children or False otherwise. More...
 
- Protected Attributes inherited from Nectunia.PropertyInterface.MonoBehaviourTagged
TagID _tagID = -1L
 
Tag.ValueType _valuesType = Tag.DEFAULT_VALUESTYPE
 

Property Documentation

◆ Action

ActionOnTrigger Nectunia.PropertyInterface.PropertyTriggerHandler.Action
getset

The action to do on trigger.

◆ AffectChildren

bool Nectunia.PropertyInterface.PropertyTriggerHandler.AffectChildren
getset

Does the handler have to change the children as well.

◆ Targets

List<GameObject> Nectunia.PropertyInterface.PropertyTriggerHandler.Targets
get

List of all targets that have triggered the PropertyTriggerHandler.

◆ TypedValue

TypedValue Nectunia.PropertyInterface.PropertyTriggerHandler.TypedValue
getset

The Typed value to apply on trigger.

Member Function Documentation

◆ OnTriggerEnter()

void Nectunia.PropertyInterface.PropertyTriggerHandler.OnTriggerEnter ( Collider  other)

Happens when an other object trigger the collider attached.

Parameters
otherthe object wich have triggered the collider.

◆ OnTriggerExit()

void Nectunia.PropertyInterface.PropertyTriggerHandler.OnTriggerExit ( Collider  other)

Happens when a triggered object exit the collider attached.

Parameters
otherthe object wich exit the collider.

◆ OnValuesTypeChanged()

override void Nectunia.PropertyInterface.PropertyTriggerHandler.OnValuesTypeChanged ( )
protectedvirtual

Event triggered when the Type of the values changed.

Reimplemented from Nectunia.PropertyInterface.MonoBehaviourTagged.

◆ Update()

void Nectunia.PropertyInterface.PropertyTriggerHandler.Update ( )

Member Enumeration Documentation

◆ ActionOnTrigger

List of possible action.

Enumerator
Add 
ChangeTo