Arbor 3: FSM & BT Graph Editor 3.1.3

- Main Page
- Packages
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Member Functions | Public Attributes | Protected Member Functions | Properties | List of all members
State Class Reference

Class that represents the state More...

Inheritance diagram for State:

## Public Member Functions
| State (ArborFSMInternal stateMachine, int nodeID, bool resident)
| State constructor More...
void | AddBehaviour (StateBehaviour behaviour)
| Adds the behaviour. More...
StateBehaviour | AddBehaviour (System.Type type)
| Adds the behaviour. More...
T | AddBehaviour< T > ()
| Adds the behaviour. More...
void | InsertBehaviour (int index, StateBehaviour behaviour)
| Insert the behaviour. More...
StateBehaviour | InsertBehaviour (int index, System.Type type)
| Insert the behaviour. More...
T | InsertBehaviour< T > (int index)
| Adds the behaviour. More...
StateBehaviour | GetBehaviourFromIndex (int index)
| Get StateBehavior from index. More...
Object | GetBehaviourObjectFromIndex (int index)
| Get Object of StateBehavior from index. More...
StateBehaviour | GetBehaviour (System.Type type)
| Gets the behaviour. More...
T | GetBehaviour< T > ()
| Gets the behaviour. More...
StateBehaviour[] | GetBehaviours (System.Type type)
| Gets the behaviours. More...
T[] | GetBehaviours< T > ()
| Gets the behaviours. More...
bool | Contains (StateBehaviour behaviour)
| Whether StateBehaviour are included. More...
void | RemoveBehaviour (Object behaviourObj)
| I want to remove the StateBehaviour. More...
void | SwapBehaviour (int fromIndex, int toIndex)
| Swap the order of StateBehaviour. More...
void | MoveBehaviour (int fromIndex, int toIndex)
| Move the order of StateBehaviour. More...
void | SetBehaviour (int index, StateBehaviour behaviour)
| Set StateBehaviour. More...
override bool | IsContainsBehaviour (NodeBehaviour behaviour)
| Check if it contains NodeBehaviour. More...
void | DisconnectState (int stateID)
| For internal. More...
void | DestroyBehaviour (Object behaviourObj)
| Destroy StateBehaviour More...
void | DestroyBehaviours ()
| For internal. More...
void | UpdateBehaviours ()
| For internal. More...
void | LateUpdateBehaviours ()
| For internal. More...
void | SendTrigger (string message)
| Send a trigger message. More...
override string | GetName ()
| Get node name. More...
Public Member Functions inherited from Node
| Node (NodeGraph nodeGraph, int nodeID)
| Node constructor More...
virtual bool | IsDeletable ()
| Returns whether or not it can be deleted. More...
override string | ToString ()
| Convert node to string (for debugging). More...

## Public Attributes
string | name = "New State"
| The name of the state. More...
Public Attributes inherited from Node
Rect | position
| Position on the Arbor Editor. More...
bool | showComment
| Whether to display comments More...
string | nodeComment
| Comment More...

## Protected Member Functions
override void | OnGraphChanged ()
| Called when the NodeGraph to which the Node belongs has changed. More...

## Properties
ArborFSMInternal | stateMachine`[get]`
| Gets the state machine. More...
StateBehaviour[] | behaviours`[get]`
| Deprecated. More...
int | behaviourCount`[get]`
| Get a count of Behavior. More...
int | stateID`[get]`
| Gets the state identifier. More...
bool | resident`[get]`
| Gets a value indicating whether this State is resident. More...
bool | breakPoint`[get, set]`
| Break point. More...
uint | transitionCount`[get, set]`
| Transition count. More...
Properties inherited from Node
NodeGraph | nodeGraph`[get]`
| Gets the NodeGraph. More...
int | nodeID`[get]`
| Gets the node identifier. More...

## Detailed Description

Class that represents the state

## Constructor & Destructor Documentation

State | ( | ArborFSMInternal | stateMachine,
|  | int | nodeID,
|  | bool | resident
| ) |  |

State constructor

Parameters

  stateMachine | StateMachine with this node
  nodeID | Node ID
  resident | Resident state

Please use the ArborFSMInternal.CreateState(bool) state creating.

## Member Function Documentation

void AddBehaviour | ( | StateBehaviour | behaviour | ) |

Adds the behaviour.

Parameters

  behaviour | Add StateBehaviour

StateBehaviour AddBehaviour | ( | System.Type | type | ) |

Adds the behaviour.

Parameters

  type | Type of add StateBehaviour

Returns
  Added StateBehaviour

T AddBehaviour< T > | ( |  | ) |

Adds the behaviour.

Template Parameters

  T | Type of add StateBehaviour

Returns
  Added StateBehaviour

Type Constraints

  T | : | StateBehaviour |

bool Contains | ( | StateBehaviour | behaviour | ) |

Whether StateBehaviour are included.

Parameters

  behaviour | Judges StateBehaviour.

Returns
  Whether included are.

void DestroyBehaviour | ( | Object | behaviourObj | ) |

Destroy StateBehaviour

Parameters

  behaviourObj | The StateBehavior you want to destroy.

void DestroyBehaviours | ( |  | ) |

For internal.

void DisconnectState | ( | int | stateID | ) |

For internal.

StateBehaviour GetBehaviour | ( | System.Type | type | ) |

Gets the behaviour.

Parameters

  type | Type of you want to get StateBehaviour.

Returns
  Found StateBehaviour. Or null if it is not.

T GetBehaviour< T > | ( |  | ) |

Gets the behaviour.

Template Parameters

  T | Type of you want to get StateBehaviour.

Returns
  Found StateBehaviour. Or null if it is not.

Type Constraints

  T | : | StateBehaviour |

StateBehaviour GetBehaviourFromIndex | ( | int | index | ) |

Get StateBehavior from index.

Parameters

  index | Index

Returns
  StateBehaviour

Object GetBehaviourObjectFromIndex | ( | int | index | ) |

Get Object of StateBehavior from index.

Parameters

  index | Index

Returns
  Object

StateBehaviour [] GetBehaviours | ( | System.Type | type | ) |

Gets the behaviours.

Parameters

  type | Type of you want to get StateBehaviour.

Returns
  Array of found StateBehaviour.

T [] GetBehaviours< T > | ( |  | ) |

Gets the behaviours.

Template Parameters

  T | Type of you want to get StateBehaviour.

Returns
  Array of found StateBehaviour.

Type Constraints

  T | : | StateBehaviour |

override string GetName | ( |  | ) |
| virtual

Get node name.

Returns
  Node name

Reimplemented from Node.

void InsertBehaviour | ( | int | index,
|  | StateBehaviour | behaviour
| ) |  |

Insert the behaviour.

Parameters

  index | Insertion destination index
  behaviour | Insert StateBehaviour

StateBehaviour InsertBehaviour | ( | int | index,
|  | System.Type | type
| ) |  |

Insert the behaviour.

Parameters

  index | Insertion destination index
  type | Type of add StateBehaviour

Returns
  Inserted StateBehaviour

T InsertBehaviour< T > | ( | int | index | ) |

Adds the behaviour.

Template Parameters

  T | Type of insert StateBehaviour

Parameters

  index | Insertion destination index

Returns
  Inserted StateBehaviour

Type Constraints

  T | : | StateBehaviour |

override bool IsContainsBehaviour | ( | NodeBehaviour | behaviour | ) |
| virtual

Check if it contains NodeBehaviour.

Parameters

  behaviour | Check NodeBehaviour

Returns
  Returns true if it contains NodeBehaviour.

Reimplemented from Node.

void LateUpdateBehaviours | ( |  | ) |

For internal.

void MoveBehaviour | ( | int | fromIndex,
|  | int | toIndex
| ) |  |

Move the order of StateBehaviour.

Parameters

  fromIndex | The moving want index.
  toIndex | The destination index.

override void OnGraphChanged | ( |  | ) |
| protected virtual

Called when the NodeGraph to which the Node belongs has changed.

Reimplemented from Node.

void RemoveBehaviour | ( | Object | behaviourObj | ) |

I want to remove the StateBehaviour.

For instance is not deleted, that you use the StateBehaviour.Destroy.

Parameters

  behaviourObj | StateBehaviour you want to remove.

void SendTrigger | ( | string | message | ) |

Send a trigger message.

StateBehaviour.OnStateTrigger is called.

Parameters

  message |

void SetBehaviour | ( | int | index,
|  | StateBehaviour | behaviour
| ) |  |

Set StateBehaviour.

Parameters

  index | Index
  behaviour | StateBehaviour

Note that the original StateBehaviour does not Destroy. If you want to add StateBehaviour, please use AddBehaviour. If you want to do Destroy please use DestroyBehaviour.

void SwapBehaviour | ( | int | fromIndex,
|  | int | toIndex
| ) |  |

Swap the order of StateBehaviour.

Parameters

  fromIndex | The swapping want index.
  toIndex | Exchange destination index.

void UpdateBehaviours | ( |  | ) |

For internal.

## Member Data Documentation

string name = "New State"

The name of the state.

## Property Documentation

int behaviourCount
| get

Get a count of Behavior.

StateBehaviour [] behaviours
| get

Deprecated.

Use behaviourCount and GetBehaviourFromIndex.

bool breakPoint
| get set

Break point.

When this property is true, the editor is in a pause state at the timing of entering the state.

bool resident
| get

Gets a value indicating whether this State is resident.

int stateID
| get

Gets the state identifier.

ArborFSMInternal stateMachine
| get

Gets the state machine.

uint transitionCount
| get set

Transition count.