Not exactly sure where to find the error logs of unity, there’s no errors the IDE finds in my code
This is the first component I ever tried to make in unreal thats causing the trouble
Also I installed Rider instead and deleted int/saved (dont have binary) and they auto re-populated when i opened the uproject with rider.
Thank you for all of your help so far, sincerely!
My SprintComponent.cpp is left default since it was created
My SprintComponent.h file below:
// Fill out your copyright notice in the Description page of Project Settings.
#pragma once
#include "CoreMinimal.h"
#include "Components/ActorComponent.h"
#include "Sprintcomponent.generated.h"
UCLASS( ClassGroup=(Custom), meta=(BlueprintSpawnableComponent) )
class MYPROJECT_API USprintcomponent : public UActorComponent
{
GENERATED_BODY()
public:
// Sets default values for this component's properties
USprintcomponent();
virtual void TickComponent(float DeltaTime, ELevelTick TickType, FActorComponentTickFunction* ThisTickFunction) override;
UProperty(EditAnywhere, BlueprintReadWrite, Category = "Sprint")
float DefaultMaxEnergy = 100.0f;
UProperty(EditAnywhere, BlueprintReadWrite, Category = "Sprint")
float DefaultEnergyRegenRate = 1.0f;
UProperty(EditAnywhere, BlueprintReadWrite, Category = "Sprint")
float DefaultEnergyDrainRate = 1.0f;
UProperty(VisibleAnywhere, BlueprintReadOnly, Category = "Sprint")
float CurrentEnergy;
UProperty(EditAnywhere, BlueprintReadWrite, Category = "Sprint")
float SprintEnergyCost = 10.0f;
UProperty(VisibleAnywhere, BlueprintReadOnly, Category = "Sprint")
bool IsSprinting;
protected:
// Called when the game starts
virtual void BeginPlay() override;
private:
class ACharacter * OwnerCharacter;
float DefaultWalkSpeed;
void StartSprint();
void StopSprint();
};