[Solved] CollisionConversions unresolved symbols

I am getting an unresolved external symbols linking error to some of the functions in CollisionConversions which I am using in my code. CollisionConversions lives in: Engine/Private/Collisions My understanding was that I would need the Engine module since this is a subset of engine. I am using ConvertQueryImpactHit.

error LNK2019: unresolved external symbol "enum EConvertQueryResult __cdecl ConvertQueryImpactHit(class UWorld const *,struct physx::PxLocationHit const &,struct FHitResult &,float,struct physx::PxFilterData const &,struct FVector const &,struct FVector const &,class physx::PxGeometry const * const,class physx::PxTransform const &,bool,bool)" (?ConvertQueryImpactHit@@YA?AW4EConvertQueryResult@@PEBVUWorld@@AEBUPxLocationHit@physx@@AEAUFHitResult@@MAEBUPxFilterData@4@AEBUFVector@@4QEBVPxGeometry@4@AEBVPxTransform@4@_N7@Z) 

I have Core, PhysX, and APEX in PublicDependencyModuleNames and Engine and CoreUObject in PrivateDependencyModuleNames.

I am including the relevant headers:

#include "PhysXIncludes.h"
#include "PhysicsPublic.h"
#include "PhysXPublic.h"
#include "Runtime/Engine/Private/PhysicsEngine/PhysXSupport.h"
#include "Runtime/Engine/Private/Collision/PhysXCollision.h"
#include "Runtime/Engine/Private/Collision/CollisionConversions.h"

What am I doing wrong here and/or misunderstanding about the module system? Linking error goes away if I remove the ConvertQueryImpactHit function but obviously I am wanting to use this convenient function and will likely run into errors like these again in the future in UE4 if I don’t fix my understanding.

Those functions in that file are not being exposed in the engine module. That’s what is being indicated by the fact that the header file is in the Private folder. They exist in the engine libraries but their symbols are not publicly accessible. If you wanted to expose them you’d have to change the engine and build it from source.

Thanks, I figured as much earlier and worked around it. Surprised so many useful things are not publicly exposed.