Class Channel
Inheritance
object
Channel
Assembly: Dew.Core.dll
Syntax
Fields
blockedActions
Blocked actions for the owner of this channel.
This channel will fail if any of the cancelable blocks is disobeyed.
Declaration
public Channel.BlockedAction blockedActions
Field Value
duration
Total duration of this channel.
Declaration
Field Value
isAttack
Only a single attack channel can exist in an entity.
Declaration
Field Value
onCancel
Callback function to be called when this channel has been canceled.
This can be because of either an invalidation flag from any of the validators, or cancelable block being canceled by an entity.
Declaration
Field Value
| Type |
Description |
| System.Action |
|
onComplete
Callback function to be called when this channel has been successfully completed.
Declaration
Field Value
| Type |
Description |
| System.Action |
|
onTick
Called every logic update tick while channel is alive.
Declaration
public Action<float> onTick
Field Value
| Type |
Description |
| System.Action<T><float> |
|
uncancellableTime
If this channel is cancellable, it won't be cancellable during this period to prevent accidental cancel.
Declaration
public float uncancellableTime
Field Value
Properties
elapsedTime
Declaration
public float elapsedTime { get; }
Property Value
isAlive
Declaration
public bool isAlive { get; }
Property Value
Methods
AddOnCancel(Action)
Declaration
public Channel AddOnCancel(Action callback)
Parameters
| Type |
Name |
Description |
| System.Action |
callback |
|
Returns
AddOnComplete(Action)
Declaration
public Channel AddOnComplete(Action callback)
Parameters
| Type |
Name |
Description |
| System.Action |
callback |
|
Returns
AddOnTick(Action<float>)
Declaration
public Channel AddOnTick(Action<float> callback)
Parameters
| Type |
Name |
Description |
| System.Action<T><float> |
callback |
|
Returns
AddValidation(IBinaryEntityValidator, Entity)
Adds an binary entity validation for this channel. This channel will fail if any of the added validators evaluates to false.
Declaration
public Channel AddValidation(IBinaryEntityValidator validator, Entity entity)
Parameters
Returns
AddValidation(IEntityValidator)
Adds an entity validation for this channel. This channel will fail if any of the added validators evaluates to false.
Declaration
public Channel AddValidation(IEntityValidator validator)
Parameters
Returns
Cancel()
Cancel this channel next channel update.
Declaration
Returns
Complete()
Complete this channel next channel update.
Declaration
public Channel Complete()
Returns
Dispatch(Entity)
Declaration
public Channel Dispatch(Entity e)
Parameters
| Type |
Name |
Description |
| Entity |
e |
|
Returns