Hex Terrains Framework
Search Results for

    Show / Hide Table of Contents

    Class UserToolsStateMachine

    Inheritance
    object
    SmState
    SmStateMachine
    UserToolsStateMachine
    Implements
    ISmState
    IStateMachine
    IDisposable
    Inherited Members
    SmStateMachine.States
    SmStateMachine.SortedStates
    SmStateMachine.CurrentState
    SmStateMachine.AddState<TState>(TState)
    SmStateMachine.SetState<TState>(int, TState, bool)
    SmStateMachine.SwitchState<TState>()
    SmStateMachine.SwitchState<TState, TContext>(TContext)
    SmStateMachine.SwitchState(int)
    SmStateMachine.SwitchState<TState, TContext>(TState, TContext)
    SmStateMachine.SwitchState(ISmState)
    SmStateMachine.GetState<TState>(Type)
    SmStateMachine.GetState(int)
    SmStateMachine.GetState(Type)
    SmStateMachine.Tick()
    SmStateMachine.PrepareToRun()
    SmStateMachine.PrepareToStop()
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: Fwt.HexTerrains.UserTools.SM
    Assembly: fwt.hexterrains.dll
    Syntax
    public class UserToolsStateMachine : SmStateMachine, ISmState, IStateMachine, IDisposable

    Constructors

    UserToolsStateMachine()

    Declaration
    public UserToolsStateMachine()

    UserToolsStateMachine(IHexTerrainAPI)

    Declaration
    protected UserToolsStateMachine(IHexTerrainAPI terrainAPI)
    Parameters
    Type Name Description
    IHexTerrainAPI terrainAPI

    Fields

    StatesByType

    Declaration
    protected Dictionary<int, UserToolStateBase> StatesByType
    Field Value
    Type Description
    Dictionary<int, UserToolStateBase>

    Methods

    AddState(ISmState)

    Adds the specified state to the state machine's collection of states.

    Declaration
    public override void AddState(ISmState state)
    Parameters
    Type Name Description
    ISmState state

    The state to add. Cannot be null.

    Overrides
    SmStateMachine.AddState(ISmState)
    Remarks

    If the state is not null, it is also added to the sorted state collection, keyed by its type. This allows for efficient retrieval of states by type.

    ClearStates()

    Destroys all states and clears the States collection.

    Declaration
    public virtual void ClearStates()

    CreateUserToolState<TInitArgs>(TInitArgs)

    Declaration
    public virtual UserToolStateBase CreateUserToolState<TInitArgs>(TInitArgs args) where TInitArgs : IUserToolStateConfig
    Parameters
    Type Name Description
    TInitArgs args
    Returns
    Type Description
    UserToolStateBase
    Type Parameters
    Name Description
    TInitArgs

    Dispose()

    Declaration
    public void Dispose()

    GetStateByUserToolType(int)

    Declaration
    public UserToolStateBase GetStateByUserToolType(int userToolType)
    Parameters
    Type Name Description
    int userToolType
    Returns
    Type Description
    UserToolStateBase

    GetState<TState>(int)

    Declaration
    public TState GetState<TState>(int userToolType) where TState : UserToolStateBase
    Parameters
    Type Name Description
    int userToolType
    Returns
    Type Description
    TState
    Type Parameters
    Name Description
    TState

    Init(IHexTerrainAPI)

    Declaration
    public virtual void Init(IHexTerrainAPI terrainAPI)
    Parameters
    Type Name Description
    IHexTerrainAPI terrainAPI

    InitState<TInitArgs>(UserToolStateBase, TInitArgs)

    Declaration
    public virtual void InitState<TInitArgs>(UserToolStateBase state, TInitArgs initArgs)
    Parameters
    Type Name Description
    UserToolStateBase state
    TInitArgs initArgs
    Type Parameters
    Name Description
    TInitArgs

    InitStates(IHexTerrainAPI)

    Declaration
    public virtual void InitStates(IHexTerrainAPI terrainAPI)
    Parameters
    Type Name Description
    IHexTerrainAPI terrainAPI

    InitStates<TInitArgs>(IEnumerable<TInitArgs>)

    Declaration
    public virtual void InitStates<TInitArgs>(IEnumerable<TInitArgs> requests) where TInitArgs : IUserToolStateConfig
    Parameters
    Type Name Description
    IEnumerable<TInitArgs> requests
    Type Parameters
    Name Description
    TInitArgs

    Init<TInitArgs>(IEnumerable<TInitArgs>)

    Declaration
    public virtual void Init<TInitArgs>(IEnumerable<TInitArgs> requests) where TInitArgs : IUserToolStateConfig
    Parameters
    Type Name Description
    IEnumerable<TInitArgs> requests
    Type Parameters
    Name Description
    TInitArgs

    Init<TInitArgs>(IEnumerable<TInitArgs>, IHexTerrainAPI)

    Declaration
    public virtual void Init<TInitArgs>(IEnumerable<TInitArgs> requests, IHexTerrainAPI terrainAPI) where TInitArgs : IUserToolStateConfig
    Parameters
    Type Name Description
    IEnumerable<TInitArgs> requests
    IHexTerrainAPI terrainAPI
    Type Parameters
    Name Description
    TInitArgs

    SwitchStateByUserToolType(int)

    Declaration
    public UserToolStateBase SwitchStateByUserToolType(int userToolType)
    Parameters
    Type Name Description
    int userToolType
    Returns
    Type Description
    UserToolStateBase

    SwitchState<TState>(int)

    Declaration
    public TState SwitchState<TState>(int userToolType) where TState : UserToolStateBase
    Parameters
    Type Name Description
    int userToolType
    Returns
    Type Description
    TState
    Type Parameters
    Name Description
    TState

    Implements

    ISmState
    IStateMachine
    IDisposable

    Extension Methods

    HashExtensions.GetHashCode_RefType<TValue>(TValue, int)
    Extensions_UnityObject.SmartDestroy(object)
    Extensions_UnityObject.SmartGetComponent<TComponent>(object)
    Extensions_UnityObject.SmartGetGameGameObject(object)
    In this article
    Back to top Generated by DocFX