Main Rebase #5

Merged
Keeper317 merged 16 commits from main into MenusAndStuffpt2 2026-01-03 06:25:24 +00:00
4 changed files with 95 additions and 0 deletions
Showing only changes of commit da46541a07 - Show all commits

Binary file not shown.

Binary file not shown.

View File

@@ -0,0 +1,34 @@
// Fill out your copyright notice in the Description page of Project Settings.
#include "ProjectileBase.h"
// Sets default values
AProjectileBase::AProjectileBase()
{
// Set this actor to call Tick() every frame. You can turn this off to improve performance if you don't need it.
PrimaryActorTick.bCanEverTick = true;
collision = CreateDefaultSubobject<USphereComponent>("Collision");
RootComponent = collision;
projectileMesh = CreateDefaultSubobject<UStaticMeshComponent>("ProjectileMesh");
projectileMesh->SetupAttachment(collision);
projectileMotion = CreateDefaultSubobject<UProjectileMovementComponent>("ProjectileMovementComponent");
}
// Called when the game starts or when spawned
void AProjectileBase::BeginPlay()
{
Super::BeginPlay();
}
// Called every frame
void AProjectileBase::Tick(float DeltaTime)
{
Super::Tick(DeltaTime);
}

View File

@@ -0,0 +1,61 @@
// Fill out your copyright notice in the Description page of Project Settings.
#pragma once
#include "CoreMinimal.h"
#include "Components/SphereComponent.h"
#include "GameFramework/Actor.h"
#include "GameFramework/ProjectileMovementComponent.h"
#include "ProjectileBase.generated.h"
UCLASS()
class OPENCONFLICT_API AProjectileBase : public AActor
{
GENERATED_BODY()
/*UPROPERTY and UFUNCTION declarations*/
private:
/*Properties*/
/*Functions*/
protected:
/*Properties*/
/*Functions*/
public:
/*Properties*/
UPROPERTY(EditDefaultsOnly, BlueprintReadOnly, Category = "Projectile")
UStaticMeshComponent* projectileMesh;
UPROPERTY(EditDefaultsOnly, BlueprintReadOnly, Category = "Projectile")
USphereComponent* collision;
UPROPERTY(EditDefaultsOnly, BlueprintReadOnly, Category = "Projectile")
UProjectileMovementComponent* projectileMotion;
/*Functions*/
/*C++ only declarations*/
private:
/*Properties*/
/*Functions*/
protected:
/*Properties*/
/*Functions*/
// Called when the game starts
virtual void BeginPlay() override;
public:
/*Properties*/
/*Functions*/
// Called every frame
virtual void Tick(float DeltaTime) override;
// Sets default values for this actor's properties
AProjectileBase();
};