I'm following a tutorial on user widgets and after I add TSubclassOf<UUserWidget> widgetClass; it gives me an error I can't figure it out:
MainPlayer.gen.cpp.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) class UClass * __cdecl Z_Construct_UClass_UUserWidget_NoRegister(void)" (__imp_?Z_Construct_UClass_UUserWidget_NoRegister@@YAPEAVUClass@@XZ) referenced in function "void __cdecl `dynamic initializer for 'public: static struct UECodeGen_Private::FClassPropertyParams const Z_Construct_UClass_AMainPlayer_Statics::NewProp_widgetClass''(void)" (??__E?NewProp_widgetClass@Z_Construct_UClass_AMainPlayer_Statics@@2UFClassPropertyParams@UECodeGen_Private@@B@@YAXXZ)"
Run Code Online (Sandbox Code Playgroud)
the img:https://i.stack.imgur.com/VKGZO.png
// Fill out your copyright notice in the Description page of Project Settings.
#pragma once
#include "Camera/CameraComponent.h"
#include "GameFramework/SpringArmComponent.h"
#include "CoreMinimal.h"
#include "GameFramework/Character.h"
#include "Blueprint/UserWidget.h" …Run Code Online (Sandbox Code Playgroud)