I would like to use UModel in a custom component to generate a custom mesh (to create something similar to UBrushComponent for ProBuilder).
On OS X it compiles fine, but on windows I get link error as soon as I use functions of my UModel:
// PBMC.h
UCLASS(Blueprintable)
class UPBMC : public UPrimitiveComponent
{
GENERATED_UCLASS_BODY()
UPROPERTY()
class UPBModel* Model;
[...]
}
// PBMC.cpp
[...]
void UPBMC::UpdateVertices()
{
if (Model != NULL)
{
Model->PBBuildVertexBuffers(); // link error on windows
Model->PBUpdateVertices(); // link error on windows
}
}
The error:
error LNK2019: unresolved external symbol "public: void __cdecl UModel::UpdateVertices(void)" (?UpdateVertices@UModel@@QEAAXXZ) referenced in function "public: void __cdecl UPBMC::UpdateVertices(void)" (?UpdateVertices@UPBMC@@QEAAXXZ)