Click or drag to resize

InputActionPress Method

This will simulate pressing the specified action.

The strength can be used for non-boolean actions, it's ranged between 0 and 1 representing the intensity of the given action.

Note: This method will not cause any _Input(InputEvent) calls. It is intended to be used with IsActionPressed(String) and IsActionJustPressed(String). If you want to simulate _input, use ParseInputEvent(InputEvent) instead.

Namespace:  Godot
Assembly:  GodotSharp (in GodotSharp.dll) Version: 1.0.0
Syntax
C#
public static void ActionPress(
	string action,
	float strength = 1f
)

Parameters

action
Type: SystemString

[Missing <param name="action"/> documentation for "M:Godot.Input.ActionPress(System.String,System.Single)"]

strength (Optional)
Type: SystemSingle

[Missing <param name="strength"/> documentation for "M:Godot.Input.ActionPress(System.String,System.Single)"]

See Also