Skip to main content

IPlayerStateTransition

An interface in Root.Township, Alta.PlayerStates.Transitions.

A possible move from one player state to another. While active it listens for its trigger, then asks the transitions manager to switch states.

Properties​

MemberWhat it is
PlayerStateType DestinationStateType { get; }The state this transition leads to.
bool IsActive { get; set; }Whether the transition is listening for its trigger. Setting it adds or removes the listeners.
IPlayerState SourceState { set; }The state this transition leads away from. Setting it also picks up that state's player and manager.
IStateTransitionsManager StateTransitionsManager { get; set; }The manager that performs the switch.

Methods​

MemberWhat it is
void Clear()Clears the source state.
void TransitionToDestinationStateExternal()Switches to the destination state now, from outside the transition.

Used in​

Members of other types that take, return or hold a IPlayerStateTransition: