Skip to main content

Classes

ULCKBaseButton

ULCKBaseButton
class
Base class for all UI button components.Parent: USceneComponentInterfaces: ILCKButtonable, ILCKShowable, ILCKVisuallyDebuggableModule: LCKUI

ULCKToggle

ULCKToggle
class
Toggle button with on/off states.Parent: ULCKBaseButton

ULCKStepper

ULCKStepper
class
Increment/decrement control.Parent: ULCKBaseButton

ULCKPad2D

ULCKPad2D
class
2D directional pad control.Parent: ULCKBaseButton

ULCKDisplay

ULCKDisplay
class
Render target display surface.Parent: USceneComponent

ULCKRecordButton

ULCKRecordButton
class
Record button with time display.Parent: ULCKBaseButtonInterfaces: ILCKRecordable

ULCKShowablesGroup

ULCKShowablesGroup
class
Container for managing showable groups.Parent: UObjectInterfaces: ILCKShowable

Structures

FLCKTapData

USTRUCT()
struct LCKUI_API FLCKTapData
{
    GENERATED_BODY()

    UPROPERTY()
    FVector ButtonLocation = FVector::ZeroVector;

    UPROPERTY()
    FVector ButtonRightVector = FVector::ZeroVector;

    UPROPERTY()
    FVector ButtonForwardVector = FVector::ZeroVector;

    UPROPERTY()
    FVector TapLocation = FVector::ZeroVector;

    UPROPERTY()
    bool IsPressed = false;
};

FLCKConstants

USTRUCT(BlueprintType)
struct LCKUI_API FLCKConstants
{
    // Timing
    static constexpr float CoolDownTime = 0.25f;

    // Collision
    inline static const FName UICollisionProfileName = TEXT("OverlapOnlyPawn");

    // UV Steps
    inline static const FVector2D SquareButtonUVStep = FVector2D(0.1f, 0.1f);
    inline static const FVector2D RectButtonUVStep = FVector2D(0.25f, 0.1f);
    inline static const FVector2D TabButtonUVStep = FVector2D(0.183333f, 0.1f);

    // Box Extents
    inline static const FVector SquareButtonBoxExtent = FVector(0.4f, 2.4f, 2.4f);
    inline static const FVector RectButtonBoxExtent = FVector(0.4f, 6.0f, 2.4f);
    inline static const FVector TabButtonBoxExtent = FVector(0.4f, 4.4f, 2.4f);
};

FLCKColor

USTRUCT()
struct LCKUI_API FLCKColor
{
    static constexpr FColor Primary         {8, 8, 8};
    static constexpr FColor PrimaryText     {220, 220, 220};
    static constexpr FColor Secondary       {16, 16, 16};
    static constexpr FColor Disabled        {96, 96, 96};
    static constexpr FColor ButtonDefault   {40, 40, 40};
    static constexpr FColor ButtonIconDefault {220, 220, 220};
    static constexpr FColor ButtonActive    {94, 69, 255};
    static constexpr FColor Debug           {255, 0, 255};
    static constexpr FColor Alert           {255, 42, 42};
    static constexpr FColor Success         {32, 196, 64};
    static constexpr FColor White           {255, 255, 255};
    static constexpr FColor Black           {0, 0, 0};
};

Enumerations

ELCKButtonType

UENUM(BlueprintType)
enum class ELCKButtonType : uint8
{
    Square      UMETA(DisplayName = "Square"),
    Rectangle   UMETA(DisplayName = "Rectangle"),
    Tab         UMETA(DisplayName = "Tab"),
    Selector    UMETA(DisplayName = "Selector")
};

ELCKRecordingState

UENUM(BlueprintType)
enum class ELCKRecordingState : uint8
{
    Idle        UMETA(DisplayName = "Idle"),
    Recording   UMETA(DisplayName = "Recording"),
    Saving      UMETA(DisplayName = "Saving"),
    Processing  UMETA(DisplayName = "Processing"),
    Error       UMETA(DisplayName = "Error"),
    Paused      UMETA(DisplayName = "Paused")
};

ELCKVideoQuality

UENUM(BlueprintType)
enum class ELCKVideoQuality : uint8
{
    SD      UMETA(DisplayName = "SD"),      // 1280x720
    HD      UMETA(DisplayName = "HD"),      // 1920x1080
    TWO_K   UMETA(DisplayName = "2K"),      // 2560x1440
    FOUR_K  UMETA(DisplayName = "4K"),      // 3840x2160
    MAX     UMETA(Hidden)
};

ELCKScreenOrientation

UENUM(BlueprintType)
enum class ELCKScreenOrientation : uint8
{
    Landscape   UMETA(DisplayName = "Landscape"),
    Portrait    UMETA(DisplayName = "Portrait")
};

ELCKCameraFacing

UENUM(BlueprintType)
enum class ELCKCameraFacing : uint8
{
    Front   UMETA(DisplayName = "Front"),
    Rear    UMETA(DisplayName = "Rear")
};

ELCKButtonInteractionDirection

UENUM(BlueprintType)
enum class ELCKButtonInteractionDirection : uint8
{
    Forward     UMETA(DisplayName = "Forward"),
    Up          UMETA(DisplayName = "Up")
};

Interfaces

ILCKButtonable

UINTERFACE(MinimalAPI)
class ULCKButtonable : public UInterface
{
    GENERATED_BODY()
};

class ILCKButtonable
{
    GENERATED_BODY()
    // Marker interface for button-like objects
};

ILCKShowable

class ILCKShowable
{
    GENERATED_BODY()

public:
    virtual void Show() = 0;
    virtual void Hide() = 0;
};

ILCKRecordable

class ILCKRecordable
{
    GENERATED_BODY()

public:
    virtual void SetTime(float NewTime) = 0;
    virtual void UpdateVisuals(const ELCKRecordingState NewState) = 0;
};

ILCKUISystemable

class ILCKUISystemable
{
    GENERATED_BODY()

public:
    virtual void SetCurrentOperatingButton(ILCKButtonable* InButtonable) = 0;
    virtual void PlayUIFeedback(bool InIsOnPressed, FVector NewTouchLocation) = 0;
    virtual bool IsCurrentOperatingButtonNull() = 0;
    virtual bool IsValidInteractor(UPrimitiveComponent* InInteractorComp) = 0;
    virtual bool CanBePressed(ILCKButtonable* InButtonable) = 0;
};

Delegates

FOnTapStarted

DECLARE_DYNAMIC_MULTICAST_DELEGATE(FOnTapStarted);

FOnStepperValueChanged

DECLARE_DYNAMIC_MULTICAST_DELEGATE_OneParam(FOnStepperValueChanged, int8, NewValue);

FOnPad2DChanged

DECLARE_DYNAMIC_MULTICAST_DELEGATE_OneParam(FOnPad2DChanged, FIntPoint, NewValue);

FOnRecordButtonPressed

DECLARE_MULTICAST_DELEGATE_OneParam(FOnRecordButtonPressed, ILCKRecordable*);

Utility Classes

LCKHelper

Asset loading helper class.
class LCKUI_API LCKHelper
{
public:
    template<typename T>
    static T* FindAsset(const TCHAR* Path);
};

// Usage
UStaticMesh* Mesh = LCKHelper::FindAsset<UStaticMesh>(
    TEXT("/LCKUI/UI/Meshes/LCKButtonSquare.LCKButtonSquare")
);

Log Category

DECLARE_LOG_CATEGORY_EXTERN(LogLCKUI, Log, All);