RealDocs

UKismetInputLibrary::EqualEqual_KeyKey

function Engine Blueprint Since unknown
#include "Kismet/KismetInputLibrary.h"
Access: public Specifiers: staticBlueprintPure

Description

Tests whether two FKey values represent the same key. Backs the "==" comparison node for Key pins in the Blueprint graph editor.

Caveats & Gotchas

  • In C++ this is just FKey's own operator==; calling this static wrapper directly is only useful when working generically through the Kismet library API.
  • FKey equality compares the key's name, so gamepad-specific keys (e.g. Gamepad_FaceButton_Bottom) never equal their keyboard/mouse counterparts even if bound to the same physical action.

Signature

static bool EqualEqual_KeyKey(FKey A, FKey B);

Parameters

Name Type Description Default
A FKey The key to compare against.
B FKey The key to compare.

Return Type

bool

Example

Compare two keys C++
bool bSame = UKismetInputLibrary::EqualEqual_KeyKey(EKeys::SpaceBar, EKeys::SpaceBar);
// bSame == true

Version History

Introduced in: unknown

Version Status Notes
5.6 stable

Feedback

Was this helpful?

Suggest an edit

Select a field above to begin editing.