Class KaijuActuator
Base actuator class.
Inherited Members
Namespace: KaijuSolutions.Agents.Actuators
Syntax
public abstract class KaijuActuator : KaijuBehaviour
Properties
Agent
The KaijuAgent this actuator is assigned to.
Declaration
public KaijuAgent Agent { get; }
Property Value
| Type | Description |
|---|---|
| KaijuAgent |
IsRunning
If the actuator is currently running.
Declaration
public bool IsRunning { get; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
State
The last state of the actuator.
Declaration
public KaijuActuatorState State { get; }
Property Value
| Type | Description |
|---|---|
| KaijuActuatorState |
Methods
Begin()
If the actuator should act in its next execution step.
Declaration
public void Begin()
Cleanup()
Perform any needed resetting of the actuator.
Declaration
protected virtual void Cleanup()
EditorVisualize(Vector3)
Allow for visualizing in the editor. The position of the Agent.
Declaration
public virtual void EditorVisualize(Vector3 position)
Parameters
| Type | Name | Description |
|---|---|---|
| Vector3 | position |
End()
End the execution of this actuator.
Declaration
public void End()
Handle()
Run this actuator if it should be. There is no point in manually calling this.
Declaration
public void Handle()
Run()
Run the actuator.
Declaration
protected abstract KaijuActuatorState Run()
Returns
| Type | Description |
|---|---|
| KaijuActuatorState | The state of the actuator's progress. |
Events
OnDisabled
Callback for when this has finishing becoming disabled.
Declaration
public event KaijuAction OnDisabled
Event Type
| Type | Description |
|---|---|
| KaijuAction |
OnDisabledGlobal
Global callback for when this has finishing becoming disabled.
Declaration
public static event KaijuActuatorAction OnDisabledGlobal
Event Type
| Type | Description |
|---|---|
| KaijuActuatorAction |
OnDone
Callback for when this has successfully fully completed its action.
Declaration
public event KaijuAction OnDone
Event Type
| Type | Description |
|---|---|
| KaijuAction |
OnDoneGlobal
Global callback for when this has successfully fully completed its action.
Declaration
public static event KaijuActuatorAction OnDoneGlobal
Event Type
| Type | Description |
|---|---|
| KaijuActuatorAction |
OnEnabled
Callback for when this has finishing becoming enabled.
Declaration
public event KaijuAction OnEnabled
Event Type
| Type | Description |
|---|---|
| KaijuAction |
OnEnabledGlobal
Global callback for when this has finishing becoming enabled.
Declaration
public static event KaijuActuatorAction OnEnabledGlobal
Event Type
| Type | Description |
|---|---|
| KaijuActuatorAction |
OnExecuting
Callback for when this is continuing to execute.
Declaration
public event KaijuAction OnExecuting
Event Type
| Type | Description |
|---|---|
| KaijuAction |
OnExecutingGlobal
Global callback for when this is continuing to execute.
Declaration
public static event KaijuActuatorAction OnExecutingGlobal
Event Type
| Type | Description |
|---|---|
| KaijuActuatorAction |
OnFailed
Callback for when this has failed its execution.
Declaration
public event KaijuAction OnFailed
Event Type
| Type | Description |
|---|---|
| KaijuAction |
OnFailedGlobal
Global callback when this has failed its execution.
Declaration
public static event KaijuActuatorAction OnFailedGlobal
Event Type
| Type | Description |
|---|---|
| KaijuActuatorAction |
OnInterrupted
Callback for when this has been interrupted during its execution, cancelling the execution.
Declaration
public event KaijuAction OnInterrupted
Event Type
| Type | Description |
|---|---|
| KaijuAction |
OnInterruptedGlobal
Global callback for when this has been interrupted during its execution, cancelling the execution.
Declaration
public static event KaijuActuatorAction OnInterruptedGlobal
Event Type
| Type | Description |
|---|---|
| KaijuActuatorAction |
OnStarted
Callback for when this has started to execute.
Declaration
public event KaijuAction OnStarted
Event Type
| Type | Description |
|---|---|
| KaijuAction |
OnStartedGlobal
Global callback for when this has started to execute.
Declaration
public static event KaijuActuatorAction OnStartedGlobal
Event Type
| Type | Description |
|---|---|
| KaijuActuatorAction |
Operators
Implicit(GameObject to KaijuActuator)
Implicit conversion from a GameObject.
Declaration
public static implicit operator KaijuActuator(GameObject o)
Parameters
| Type | Name | Description |
|---|---|---|
| GameObject | o | The GameObject. |
Returns
| Type | Description |
|---|---|
| KaijuActuator | The actuator attached to the GameObject if there was one. |
Implicit(KaijuActuator to KaijuAgent)
Implicit conversion to a KaijuAgent.
Declaration
public static implicit operator KaijuAgent(KaijuActuator a)
Parameters
| Type | Name | Description |
|---|---|---|
| KaijuActuator | a | The actuator. |
Returns
| Type | Description |
|---|---|
| KaijuAgent | The KaijuAgent attached to the actuator if there was one. |
Implicit(Transform to KaijuActuator)
Implicit conversion from a transform.
Declaration
public static implicit operator KaijuActuator(Transform t)
Parameters
| Type | Name | Description |
|---|---|---|
| Transform | t | The transform. |
Returns
| Type | Description |
|---|---|
| KaijuActuator | The actuator attached to the transform if there was one. |