小编Tec*_*nut的帖子

I'm having problems with UUserWidgets on UE5

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)

c++ linker unreal-engine5

1
推荐指数
1
解决办法
2389
查看次数

标签 统计

c++ ×1

linker ×1

unreal-engine5 ×1