Navigation
API > API/Plugins > API/Plugins/EnhancedInput
Per world input subsystem that allows you to bind input delegates to actors without an owning Player Controller. This should be used when an actor needs to receive input delegates but will never have an owning Player Controller. For example, you can add input delegates to unlock a door when the user has a certain set of keys pressed. Be sure to enable input on the actor, or else the input delegates won't fire!
Note: if you do have an actor with an owning Player Controller use the local player input subsystem instead.
| Name | UEnhancedInputWorldSubsystem |
| Type | class |
| Header File | /Engine/Plugins/EnhancedInput/Source/EnhancedInput/Public/EnhancedInputSubsystems.h |
| Include Path | #include "EnhancedInputSubsystems.h" |
Syntax
UCLASS (MinimalAPI, DisplayName="Enhanced Input World Subsystem (Experimental)")
class UEnhancedInputWorldSubsystem :
public UWorldSubsystem,
public IEnhancedInputSubsystemInterface
Inheritance Hierarchy
- UObjectBase → UObjectBaseUtility → UObject → USubsystem → UWorldSubsystem → UEnhancedInputWorldSubsystem
Implements Interfaces
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void AddActorInputComponent
(
AActor* Actor |
Adds this Actor's input component onto the stack to be processed by this subsystem's tick function | EnhancedInputSubsystems.h |
|
virtual void Deinitialize() |
EnhancedInputSubsystems.h | ||
virtual void Initialize
(
FSubsystemCollectionBase& Collection |
EnhancedInputSubsystems.h | ||
bool RemoveActorInputComponent
(
AActor* Actor |
Removes this Actor's input component from the stack to be processed by this subsystem's tick function | EnhancedInputSubsystems.h |
|
virtual bool ShouldCreateSubsystem
(
UObject* Outer |
EnhancedInputSubsystems.h |
Overridden from IEnhancedInputSubsystemInterface
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual UEnhancedPlayerInput * GetPlayerInput() |
EnhancedInputSubsystems.h | ||
virtual void ShowDebugInfo
(
UCanvas* Canvas |
Debug visualization for enhanced input local player subsystem. | EnhancedInputSubsystems.h |
Protected
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void AddDefaultMappingContexts() |
Adds all the default mapping contexts | EnhancedInputSubsystems.h | |
virtual bool DoesSupportWorldType
(
const EWorldType::Type WorldType |
EnhancedInputSubsystems.h | ||
bool InputKey
(
const FInputKeyEventArgs& Params |
Inputs a key on this subsystem's player input which can then be processed as normal during Tick. | EnhancedInputSubsystems.h | |
void RemoveDefaultMappingContexts() |
Removes all the default mapping contexts | EnhancedInputSubsystems.h | |
void TickPlayerInput
(
float DeltaTime |
Builds the current input stack and ticks the world subsystem's player input. | EnhancedInputSubsystems.h |
Overridden from IEnhancedInputSubsystemInterface
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual TMap< TObjectPtr< const UInputAction >, FInjectedInput > & GetContinuouslyInjectedInputs () |
Pure-virtual getter for the map of inputs that should be injected every frame. | EnhancedInputSubsystems.h |