74 lines
1.8 KiB
C++
74 lines
1.8 KiB
C++
// Fill out your copyright notice in the Description page of Project Settings.
|
|
|
|
#pragma once
|
|
|
|
#include "CoreMinimal.h"
|
|
#include "EnhancedInputComponent.h"
|
|
#include "EnhancedInputSubsystems.h"
|
|
#include "GameFramework/PlayerController.h"
|
|
#include "DDIPlayerController.generated.h"
|
|
|
|
/**
|
|
*
|
|
*/
|
|
UCLASS()
|
|
class OPENCONFLICT_API ADDIPlayerController : public APlayerController
|
|
{
|
|
GENERATED_BODY()
|
|
/*UPROPERTY and UFUNCTION declarations*/
|
|
private:
|
|
/*Properties*/
|
|
|
|
/*Functions*/
|
|
|
|
protected:
|
|
/*Properties*/
|
|
UPROPERTY(EditDefaultsOnly, BlueprintReadOnly, Category = "INPUT", meta = (AllowPrivateAccess = "true"))
|
|
TArray<class UInputMappingContext*> MappingContexts;
|
|
|
|
UPROPERTY(EditDefaultsOnly, BlueprintReadOnly, Category = "INPUT", meta = (AllowPrivateAccess = "true"))
|
|
UInputAction* JumpAction;
|
|
UPROPERTY(EditDefaultsOnly, BlueprintReadOnly, Category = "INPUT", meta = (AllowPrivateAccess = "true"))
|
|
UInputAction* MoveAction;
|
|
UPROPERTY(EditDefaultsOnly, BlueprintReadOnly, Category = "INPUT", meta = (AllowPrivateAccess = "true"))
|
|
UInputAction* LookAction;
|
|
|
|
UPROPERTY(EditAnywhere, Category="Shooter")
|
|
FName PlayerPawnTag = FName("Player");
|
|
|
|
/**/
|
|
|
|
/*Functions*/
|
|
|
|
|
|
public:
|
|
/*Properties*/
|
|
UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = "Game Settings")
|
|
float mouseSensitivity;
|
|
/*Functions*/
|
|
|
|
/*C++ only declarations*/
|
|
private:
|
|
/*Properties*/
|
|
|
|
/*Functions*/
|
|
|
|
protected:
|
|
/*Properties*/
|
|
|
|
/*Functions*/
|
|
virtual void SetupInputComponent() override;
|
|
virtual void BeginPlay() override;
|
|
virtual void OnPossess(APawn *InPawn) override;
|
|
void Move(const FInputActionValue& Value);
|
|
void Look(const FInputActionValue& Value);
|
|
void Jump(const FInputActionValue& Value);
|
|
void JumpEnd(const FInputActionValue& Value);
|
|
|
|
public:
|
|
/*Properties*/
|
|
|
|
/*Functions*/
|
|
ADDIPlayerController();
|
|
};
|