Class AUnityEffector
Use this class to create effectors that have to execute code in Unity's thread You need to call the base constructor when inheriting this class and implement the Init and SafeEffectorUpdate methods
Inherited Members
Namespace: Xareus.Scenarios.Unity
Assembly: Xareus.Scenarios.Unity.dll
Syntax
public abstract class AUnityEffector : AEffector
Constructors
AUnityEffector(Event, Dictionary<string, Parameter>, IContext, IContext, IContext, IContext)
Declaration
protected AUnityEffector(Event @event, Dictionary<string, Parameter> parameters, IContext externalContext, IContext scenarioContext, IContext sequenceContext, IContext eventContext)
Parameters
Type | Name | Description |
---|---|---|
Event | event | |
Dictionary<string, Parameter> | parameters | |
IContext | externalContext | |
IContext | scenarioContext | |
IContext | sequenceContext | |
IContext | eventContext |
Methods
EffectorUpdate()
Declaration
public override void EffectorUpdate()
Overrides
FillParameters()
Override the base method as we need to execute this in the Unity thread
Declaration
public override void FillParameters()
Overrides
Init()
Initialize an effector. Note that this code will be executed in unity's thread and the declared parameters (using the ConfigurationParameter attribute) are already filled
Declaration
[Obsolete("Use the SafeReset method instead")]
public virtual void Init()
Reset()
Declaration
public override void Reset()
Overrides
SafeEffectorUpdate()
Actual effector code. Note that this code will be executed in unity's thread
Declaration
public abstract void SafeEffectorUpdate()
SafeReset()
Reset an effector. Note that this code will be executed in unity's thread and the declared parameters (using the ConfigurationParameter attribute) are already filled
Declaration
public virtual void SafeReset()
UnityThreadFillParameters()
Declaration
protected virtual void UnityThreadFillParameters()