Files
WizardingHub/Source/WizardingCentral/Characters/LumiController.h
T
2025-05-05 22:06:18 -04:00

77 lines
2.1 KiB
C++

// Copyright Sorcerers Shenanigans Central. All Rights Reserved.
#pragma once
#include "CoreMinimal.h"
#include "GameFramework/PlayerController.h"
#include "LumiCharacter.h"
#include "LumiController.generated.h"
class UInputMappingContext;
class UInputAction;
/**
*
*/
UCLASS()
class WIZARDINGCENTRAL_API ALumiController : public APlayerController
{
GENERATED_BODY()
UPROPERTY()
UEnhancedInputComponent* EnhancedInputComponent;
UPROPERTY()
ALumiCharacter* LumiCharacter = nullptr;
public:
UPROPERTY(EditDefaultsOnly, BlueprintReadOnly, Category = "PlayerInput")
TObjectPtr<UInputMappingContext> InputMappingContext;
UPROPERTY(EditDefaultsOnly, BlueprintReadOnly, Category = "PlayerInput")
int32 MappingPriority = 0;
/** Grab Input Action */
UPROPERTY(EditDefaultsOnly, BlueprintReadOnly, Category = "PlayerInput|Character Movement")
TObjectPtr<UInputAction> GrabAction = nullptr;
/** Jump Input Action */
UPROPERTY(EditDefaultsOnly, BlueprintReadOnly, Category = "PlayerInput|Character Movement")
TObjectPtr<UInputAction> JumpAction = nullptr;
/** Move Input Action */
UPROPERTY(EditDefaultsOnly, BlueprintReadOnly, Category = "PlayerInput|Character Movement")
TObjectPtr<UInputAction> MoveAction = nullptr;
/** Look Input Action */
UPROPERTY(EditDefaultsOnly, BlueprintReadOnly, Category = "PlayerInput|Character Movement")
TObjectPtr<UInputAction> LookAction = nullptr;
/** Spell Input Action */
UPROPERTY(EditDefaultsOnly, BlueprintReadOnly, Category = "PlayerInput|Spell System")
TObjectPtr<UInputAction> SpellAction = nullptr;
UPROPERTY(EditDefaultsOnly, BlueprintReadOnly, Category = "PlayerInput|Spell System")
TObjectPtr<UInputAction> SpellPositionAction = nullptr;
UPROPERTY(EditDefaultsOnly, BlueprintReadOnly, Category = "PlayerInput|Spell System")
TObjectPtr<UInputAction> SpellTrainSwitchAction = nullptr;
void
ShowMouseCursor();
void
HideMouseCursor();
void
GetLumiCharacter(ALumiCharacter*& OutLumiCharacter) const;
protected:
virtual void
OnPossess(APawn* InPawn) override;
virtual void
OnUnPossess() override;
private:
void
OnSpellActionStarted();
void
OnSpellActionCompleted();
};