So, I wrote my first code, as follows:
// Fill out your copyright notice in the Description page of Project Settings.
#pragma once
#include "CoreMinimal.h"
#include "GameFramework/Actor.h"
#include "MyActor.generated.h"
UCLASS()
class MYPROJECT_API AMyActor : public AActor
{
GENERATED_BODY()
public:
// Sets default values for this actor's properties
AMyActor();
protected:
// Called when the game starts or when spawned
virtual void BeginPlay() override;
public:
// Called every frame
virtual void Tick(float DeltaTime) override;
UPROPERTY(EditAnywhere)
UStaticMeshComponent* Mesh;
};
and i got the following errors:
Error Member variable declaration: Missing variable type MyProject C:\Users\Sniper\Documents\Unreal Projects\MyProject\Source\MyProject\MyActor.h 26
Error MSB3075 The command “E:\UE_4.19\Engine\Build\BatchFiles\Build.bat MyProjectEditor Win64 Development “C:\Users\Sniper\Documents\Unreal Projects\MyProject\MyProject.uproject” -WaitMutex -FromMsBuild” exited with code 5. Please verify that you have sufficient rights to run this command. MyProject C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\Common7\IDE\VC\VCTargets\Microsoft.MakeFile.Targets 44
Error UnrealHeaderTool failed for target ‘MyProjectEditor’ (platform: Win64, module info: C:\Users\Sniper\Documents\Unreal Projects\MyProject\Intermediate\Build\Win64\MyProjectEditor\Development\MyProjectEditor.uhtmanifest, exit code: OtherCompilationError (5)). MyProject C:\Users\Sniper\Documents\Unreal Projects\MyProject\Intermediate\ProjectFiles\EXEC 1
I have no ideea what i am doing wrong , can someone explain to me what is wrong with the code