Search Results for

    Show / Hide Table of Contents

    Class InputEvent

    Virtual input action binding. Helps with listening for a selected input event.

    Inheritance
    System.Object
    InputEvent
    Implements
    System.IComparable
    System.IComparable<InputEvent>
    Namespace: FlaxEngine
    Assembly: FlaxEngine.CSharp.dll
    Syntax
    public class InputEvent : Object, IComparable, IComparable<InputEvent>

    Constructors

    InputEvent()

    Initializes a new instance of the InputEvent class.

    Declaration
    public InputEvent()

    InputEvent(String)

    Initializes a new instance of the InputEvent class.

    Declaration
    public InputEvent(string name)
    Parameters
    System.String name

    The action name.

    Fields

    Name

    The name of the action to use. See ActionMappings.

    Declaration
    [Tooltip("The name of the action to use.")]
    public string Name
    Field Value
    System.String

    Properties

    Active

    Returns true if the event has been triggered during the current frame (e.g. user pressed a key). Use Pressed to catch events without active waiting.

    Declaration
    public bool Active { get; }
    Property Value
    System.Boolean

    State

    Returns the event state. Use Pressed, Pressing, Released to catch events without active waiting.

    Declaration
    public InputActionState State { get; }
    Property Value
    InputActionState

    Methods

    CompareTo(InputEvent)

    Declaration
    public int CompareTo(InputEvent other)
    Parameters
    InputEvent other

    Returns
    System.Int32

    CompareTo(Object)

    Declaration
    public int CompareTo(object obj)
    Parameters
    System.Object obj

    Returns
    System.Int32

    Dispose()

    Releases this object.

    Declaration
    public void Dispose()

    Equals(Object)

    Declaration
    public override bool Equals(object obj)
    Parameters
    System.Object obj

    Returns
    System.Boolean

    Finalize()

    Finalizes an instance of the InputEvent class.

    Declaration
    protected override void Finalize()

    GetHashCode()

    Declaration
    public override int GetHashCode()
    Returns
    System.Int32

    ToString()

    Declaration
    public override string ToString()
    Returns
    System.String

    Events

    Pressed

    Occurs when event is pressed (e.g. user pressed a key). Called before scripts update.

    Declaration
    public event Action Pressed
    Event Type
    System.Action

    Pressing

    Occurs when event is being pressing (e.g. user pressing a key). Called before scripts update.

    Declaration
    public event Action Pressing
    Event Type
    System.Action

    Released

    Occurs when event is released (e.g. user releases a key). Called before scripts update.

    Declaration
    public event Action Released
    Event Type
    System.Action

    Triggered

    Occurs when event is triggered (e.g. user pressed a key). Called before scripts update.

    Declaration
    public event Action Triggered
    Event Type
    System.Action

    Extension Methods

    Extensions.ReflectiveCompare<T>(T, T)
    Extensions.DeepClone<T>(T)
    Extensions.RawClone<T>(T)
    In This Article
    Back to top Copyright © 2012-2024 Wojciech Figat