Garbage Collecter and Non-UCLASS pointers

Hi,

I am currently implementing an external c++ framework that makes heavy use of templates.
Basically what happens is, I instantiate one of the framework classes (using new) and the garbage collector eats it before I can make use of it. I can’t decorate it as UPROPERTY() because it’s not a UCLASS.

I really need a pointer to a Non-UCLASS, but I can’t seem to find a way to wrap it into a UCLASS, since UCLASSes don’t like templates.

Any suggestions?

I spent some time reading up on garbage collection and it turns out that the garbage collector does not even collect non-uobjects. I created an instance in construction script and it wasn’t there when I played in editor. To fix this, I just needed to create a new instance on BeginPlay()