I feel like I am missing some fundamental knowledge on how plugins are designed to work in unreal. My ultimate intent is to have a plugin that responds when a level has started. On start it will spawn a few actors and clicking on some will cause effects on the other.
With that in mind my plan for going forward with this was to create a plugin that will manage these interactions between the actors and have direct knowledge of them. This would mean that upon receiving a click event for actor A, the plugin toggles a flag in actor B.
So my short question is, how can I spawn an actor in the IModuleInterface that unreal provides when creating a plugin. I’ve tried directly accessing the engine to do so during the StartupModule
and it is null there. I’ve attempted to leverage the PostLoadCallback
but that function never gets called.
My longer question is, this seems way more difficult than it needs to be so I suspect there is some fundamental that I am missing about plugins. If anyone can either explain or point me to good documentation that explains the intended use of plugins that would be great.
Thanks in advance.