50 lines
1.1 KiB
C++
50 lines
1.1 KiB
C++
// Fill out your copyright notice in the Description page of Project Settings.
|
|
|
|
#pragma once
|
|
|
|
#include "CoreMinimal.h"
|
|
#include "GameFramework/Character.h"
|
|
#include "Blueprint/UserWidget.h"
|
|
#include "TempCharacter.generated.h"
|
|
|
|
UCLASS()
|
|
class THE_TWILIGHT_ABYSS_API ATempCharacter : public ACharacter
|
|
{
|
|
GENERATED_BODY()
|
|
|
|
public:
|
|
// Sets default values for this character's properties
|
|
ATempCharacter();
|
|
|
|
protected:
|
|
// Called when the game starts or when spawned
|
|
virtual void BeginPlay() override;
|
|
|
|
void ForwardInput(float Axis);
|
|
void RightMoveInput(float Axis);
|
|
|
|
TSubclassOf<UUserWidget> WidgetClass; //defining the widget class
|
|
|
|
public:
|
|
// Called every frame
|
|
virtual void Tick(float DeltaTime) override;
|
|
|
|
// Called to bind functionality to input
|
|
virtual void SetupPlayerInputComponent(class UInputComponent* PlayerInputComponent) override;
|
|
|
|
void KeyPressed();
|
|
|
|
UPROPERTY(EditAnyWhere)
|
|
float TraceDistance = 200;
|
|
|
|
void LineTraceLogic();
|
|
|
|
UPROPERTY(EditBlueprintReadWrite, meta = (BindWidget))
|
|
UUserWidget* WidgetRef;
|
|
|
|
//private:
|
|
|
|
//UPROPERTY(EditDefaultsOnly)
|
|
//TSubclassOf<UUserWidget> WidgetClass;
|
|
};
|