Hi new compiler error

error
missing semiclon in open door line 37

code
// Fill out your copyright notice in the Description page of Project Settings.

#pragma once

#include "CoreMinimal.h"

#include "Components/ActorComponent.h"

#include "OpenDoor.generated.h"

UCLASS( ClassGroup=(Custom), meta=(BlueprintSpawnableComponent) )

class ESCAPEREMAKE2_API UOpenDoor : public UActorComponent

{

    GENERATED_BODY()

public: 

    // Sets default values for this component's properties

    UOpenDoor();

protected:

    // Called when the game starts

    virtual void BeginPlay() override;

public: 

    // Called every frame

    virtual void TickComponent(float DeltaTime, ELevelTick TickType, FActorComponentTickFunction* ThisTickFunction) override;

private:

    float Initial Yaw;

    float CurrentYaw = 90.f;

    float TargetYaw;

}

is this an error in visual studio or does it fail the compile every time? I don’t see an error besides the float variable which should be all in one without spaces, however the compiler ignores whitespace anyway so it should still work.

Initial Yaw should be one word and you don’t have a semicolon at the end of your class declaration.

class Thing
{
}; //here

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.

Privacy & Terms