PixelCrushers.DialogueSystem.ConditionObserver Class Reference

The Condition Observer component evaluates a condition on a set frequency. More...

Inheritance diagram for PixelCrushers.DialogueSystem.ConditionObserver:
Collaboration diagram for PixelCrushers.DialogueSystem.ConditionObserver:

Classes

class  SendMessageAction
 

Public Member Functions

void Check ()
 Call this method to manually check the condition and fire the action if it's true.
 
void Check (GameObject gameObject)
 Sets the observed GameObject and checks the condition.
 
void Check (string gameObjectName)
 Sets the observed GameObject to the named GameObject and checks the condition.
 
void Fire ()
 Call this method to manually run the action.
 

Public Attributes

float frequency = 1
 The frequency at which to check the condition.
 
bool once
 When observed condition becomes true, run actions and then deactivate this component.
 
GameObject observeGameObject = null
 Observe this game object when evaluating the condition.
 
Condition condition = new Condition()
 The conditions under which the trigger will fire.
 
string questName = string.Empty
 The name of the quest to update when the condition is true.
 
QuestState questState
 The new state of the quest.
 
string luaCode = string.Empty
 The lua code to run.
 
string sequence = string.Empty
 The sequence to play.
 
string alertMessage = string.Empty
 An optional gameplay alert message.
 
TextTable textTable = null
 An optional localized text table to use for the alert message.
 
SendMessageAction[] sendMessages = new SendMessageAction[0]
 
bool useQuestNamePicker = true
 

Detailed Description

The Condition Observer component evaluates a condition on a set frequency.

When the condition is true, it sends a message to a list of GameObjects and shows a gameplay alert message.

Member Function Documentation

◆ Check() [1/3]

void PixelCrushers.DialogueSystem.ConditionObserver.Check ( )
inline

Call this method to manually check the condition and fire the action if it's true.

◆ Check() [2/3]

void PixelCrushers.DialogueSystem.ConditionObserver.Check ( GameObject  gameObject)
inline

Sets the observed GameObject and checks the condition.

Parameters
gameObjectGame object.

◆ Check() [3/3]

void PixelCrushers.DialogueSystem.ConditionObserver.Check ( string  gameObjectName)
inline

Sets the observed GameObject to the named GameObject and checks the condition.

Parameters
gameObjectNameGame object name.

◆ Fire()

void PixelCrushers.DialogueSystem.ConditionObserver.Fire ( )
inline

Call this method to manually run the action.

Member Data Documentation

◆ alertMessage

string PixelCrushers.DialogueSystem.ConditionObserver.alertMessage = string.Empty

An optional gameplay alert message.

Leave blank for no message.

◆ condition

Condition PixelCrushers.DialogueSystem.ConditionObserver.condition = new Condition()

The conditions under which the trigger will fire.

◆ frequency

float PixelCrushers.DialogueSystem.ConditionObserver.frequency = 1

The frequency at which to check the condition.

◆ luaCode

string PixelCrushers.DialogueSystem.ConditionObserver.luaCode = string.Empty

The lua code to run.

◆ observeGameObject

GameObject PixelCrushers.DialogueSystem.ConditionObserver.observeGameObject = null

Observe this game object when evaluating the condition.

◆ once

bool PixelCrushers.DialogueSystem.ConditionObserver.once

When observed condition becomes true, run actions and then deactivate this component.

◆ questName

string PixelCrushers.DialogueSystem.ConditionObserver.questName = string.Empty

The name of the quest to update when the condition is true.

Blank for none.

◆ questState

QuestState PixelCrushers.DialogueSystem.ConditionObserver.questState

The new state of the quest.

◆ sendMessages

SendMessageAction [] PixelCrushers.DialogueSystem.ConditionObserver.sendMessages = new SendMessageAction[0]

◆ sequence

string PixelCrushers.DialogueSystem.ConditionObserver.sequence = string.Empty

The sequence to play.

◆ textTable

TextTable PixelCrushers.DialogueSystem.ConditionObserver.textTable = null

An optional localized text table to use for the alert message.

◆ useQuestNamePicker

bool PixelCrushers.DialogueSystem.ConditionObserver.useQuestNamePicker = true

The documentation for this class was generated from the following file: