All pages
Powered by GitBook
1 of 19

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

KeyCode

Enumeration Member in

The component is listening for a key on the keyboard to be pressed.

KeyCode

Summary

Remarks

This input will only be used if the legacy Input Manager is enabled.

ContinueActionType

continueActionButtonName

Field in

The virtual button that this component is listening for.

public string continueActionButtonName = "Jump";

Summary

Remarks

This value is only used when continueActionType is VirtualButton.

DialogueAdvanceInput

InputSystemAction

Enumeration Member in ContinueActionType

Summary

The component is listening for the action configured in continueAction to be performed.

InputSystemAction

Remarks

This input will only be used if the Input System is installed and enabled.

enableActionOnStart

Field in DialogueAdvanceInput

Summary

Configures whether Action should be enabled on start.

public bool enableActionOnStart = true;

Remarks

If this field is false , the input action specified by Action will not be enabled by default, and will need to be enabled by your game's code.

VirtualButton

Enumeration Member in ContinueActionType

Summary

The component is listening for a virtual button to be pressed.

VirtualButton

Remarks

This input will only be used if the legacy Input Manager is enabled.

Action

Property in DialogueAdvanceInput

Summary

Gets the UnityEngine.InputSystem.InputAction configured by this DialogueAdvanceInput .

public InputAction Action
{
            get; }

Remarks

This methods returns the following potential values:

  • If continueActionType is InputSystemAction, this method returns continueAction.

  • If continueActionType is InputSystemActionFromAsset, this method returns continueActionReference's action.

  • If is or , this method returns null.

DialogueAdvanceInput

Class in Yarn.Unity

Inherits from UnityEngine.MonoBehaviour

Summary

A component that listens for user input, and uses it to notify a dialogue view that the user wishes to advance to the next step in the dialogue.

public class DialogueAdvanceInput : MonoBehaviour

Remarks

This class may be used with the Unity Input System, or the legacy Input Manager. The specific type of input it's looking for is configured via the continueActionType field.

When the configured input occurs, this component calls the UserRequestedViewAdvancement() method on its dialogueView.

Enums

Name
Description
Name
Description
Name
Description

continueActionType

Field in

The type of input that this component is listening for.

  • : The type of input that this component is listening for in order to signal that its dialogue view should advance.

None

Enumeration Member in

The component is listening for no input. This component will not signal to that it should advance.

continueAction

Field in

The UnityEngine.InputSystem.InputAction that this component is listening for.

Use this continue action type when you want this component to use a configurable input action, but don't want to have to set up other actions in your project.

continueActionType
KeyCode
None
public ContinueActionType continueActionType = ContinueActionType.KeyCode;

Summary

See Also

DialogueAdvanceInput
ContinueActionType
None

Summary

ContinueActionType
dialogueView

The type of input that this component is listening for in order to signal that its dialogue view should advance.

The button/keycode action type, should the button be fired on release or press?

The UnityEngine.InputSystem.InputAction that this component is listening for.

The virtual button that this component is listening for.

Gets the UnityEngine.InputSystem.InputAction configured by this .

Fields

Properties

public InputAction continueAction = new InputAction("Skip", InputActionType.Button, CommonUsages.Submit);

Summary

Remarks

This value is only used when is .

DialogueAdvanceInput

continueActionOnButtonRelease

Field in

Should the continue action respond to key being pressed down or released.

continueActionKeyCode

Field in

The keyboard key that this component is listening for.

continueActionReference

Field in

An UnityEngine.InputSystem.InputActionReference that refers to the action that this component is listening for.

Use this continue action type when you want this component to make use of an input action you've configured elsewhere in your project.

dialogueView

Field in

The dialogue view that will be notified when the user performs the advance input (as configured by and related fields.)

When the input is performed, this dialogue view will have its method called.

InputSystemActionFromAsset

Enumeration Member in

The component is listening for the action referred to by to be performed.

The keyboard key that this component is listening for.

continueActionOnButtonRelease

Should the continue action respond to key being pressed down or released.

continueActionReference

An UnityEngine.InputSystem.InputActionReference that refers to the action that this component is listening for.

continueActionType

The type of input that this component is listening for.

dialogueView

The dialogue view that will be notified when the user performs the advance input (as configured by continueActionType and related fields.)

enableActionOnStart

Configures whether Action should be enabled on start.

ContinueActionType
ContinueButtonActionType
continueAction
continueActionButtonName
continueActionKeyCode
Action
DialogueAdvanceInput
continueActionType
InputSystemAction

Summary

Remarks

Defaults to firing the advancement on key released.

This value is only used when continueActionType is KeyCode or VirtualButton.

DialogueAdvanceInput
public KeyCode continueActionKeyCode = KeyCode.Space;

Summary

Remarks

This value is only used when continueActionType is KeyCode.

DialogueAdvanceInput
public InputActionReference continueActionReference = null;

Summary

Remarks

This value is only used when continueActionType is InputSystemActionFromAsset.

DialogueAdvanceInput
public DialogueViewBase dialogueView;

Summary

Remarks

DialogueAdvanceInput
continueActionType
UserRequestedViewAdvancement()
InputSystemActionFromAsset

Summary

Remarks

This input will only be used if the Input System is installed and enabled.

ContinueActionType
continueActionReference
public ContinueButtonActionType continueActionOnButtonRelease = ContinueButtonActionType.Up;

ContinueButtonActionType

Enum in DialogueAdvanceInput

Inherits from System.Enum

Summary

The button/keycode action type, should the button be fired on release or press?

public enum ContinueButtonActionType
{
    Up,
    Down
}

Members

Name
Description

ContinueActionType

Enum in

Inherits from System.Enum

The type of input that this component is listening for in order to signal that its dialogue view should advance.

Name
Description
public enum ContinueActionType
{
    None,
    KeyCode,
    VirtualButton,
    InputSystemAction,
    InputSystemActionFromAsset
}

Summary

Members

DialogueAdvanceInput

Action will fire on key pressed

Action will fire on key release

Down

Up

Enumeration Member in

Action will fire on key release

Up
Up

Summary

ContinueButtonActionType

The component is listening for the action configured in to be performed.

The component is listening for the action referred to by to be performed.

The component is listening for a key on the keyboard to be pressed.

The component is listening for no input. This component will not signal to that it should advance.

The component is listening for a virtual button to be pressed.

InputSystemAction
continueAction
InputSystemActionFromAsset
continueActionReference
KeyCode
None
dialogueView
VirtualButton

Down

Enumeration Member in

Action will fire on key pressed

Down

Summary

ContinueButtonActionType