c++ - Mac 上的 UE4 4.26:未定义符号 Z_Construct_UClass_UPhysicalMaterial
问题描述
试图让我的项目在 macos big sur 上启动并运行,但我遇到了链接错误(此处完整粘贴:https ://pastebin.com/raw/qt7qkjYu ):
[10/13] Link UE4Editor-LastRenegade.dylib
Undefined symbols for architecture x86_64:
"Z_Construct_UClass_UPhysicalMaterial()", referenced from:
Z_Construct_UClass_ULRNBasePhysicalMaterial_Statics::DependentSingletons in LRNBasePhysicalMaterial.gen.cpp.o
"UPhysicalMaterial::GetPrivateStaticClass()", referenced from:
[...]
ld: symbol(s) not found for architecture x86_64
我正在覆盖物理材质以从光线投射中获取有用的信息:
UCLASS()
class LASTRENEGADE_API ULRNBasePhysicalMaterial : public UPhysicalMaterial
{
GENERATED_BODY()
public:
ULRNBasePhysicalMaterial(); (defined in a cpp file)
public:
UPROPERTY(EditAnywhere, BlueprintReadOnly)
class USoundBase* ImpactSFX;
UPROPERTY(EditAnywhere, BlueprintReadOnly)
class UParticleSystem* ImpactVFX;
UPROPERTY(EditAnywhere, BlueprintReadOnly)
class UMaterialInterface* ImpactDecal;
};
解决方案
好的,在 4.26 中:你需要添加PhysicsCore
到你的 MyGame.Build.cs
推荐阅读
- kubernetes - 在没有云提供商负载均衡器的情况下,将 kubernetes 集群暴露给“世界”
- python - Pygame collidepoint()无法正常工作
- c# - Nuget 问题:接口一直引用旧版本
- javascript - NavLink:悬停和活动时的 CSS 动画
- java - 类符号 FirebaseInstanceIdService [FCM android]
- javascript - Sweet Alert 未显示,但响应消息显示但在新浏览器中打开。我该如何解决这个问题?
- javascript - 在 ajax 中调用(来自 json php 文件)时,无法获取 obj 属性以显示在 html 页面上
- javascript - 我想使用 vuejs 在文本更改上更改我的 div 的类
- angular - Karma - NullInjectorError:没有 HttpClient 的提供者
- python-3.x - 在机器之间迁移谷歌生成的 API 令牌