Blueprint Derived classes not respecting bound Delegates
This is a semi follow up to my previous post here: https://answers.unrealengine.com/questions/673832/c-oncomponentendoverlap-never-called.html
I've managed to repo an issue with delegates when they are wrapped with a CDO flag check in the constructor e.g.
If the object is C++ derived the delegates stay bound, however if you create a blueprint derived from the C++ class the same delegates are not bound upon play.
I'm not sure what the root cause of this is but I have attached a test project that I used to reproduce the problem.
Expected Result: "The delegate was called" should appear on the screen.
If I remove the *RF_ClassDefaultObject*check the problem doesn't appear. Is this intentional behaviour? I figured you wouldn't want to bind delegates to the CDO?
If there is anything else you need from me, please do let me know.
asked Aug 29 '17 at 07:44 AM in Bug Reports
As long as the reference is self contained, binding a delegate to a class CDO is perfectly acceptable. If the constructor creates a component, attaches it, and binds something to it, then that should be fine (as you mentioned with removing the if statement). If it's trying to reach something externally, that probably needs to be done in another callback which would be called on the instance.
answered Aug 30 '17 at 07:39 PM
Follow this question
Once you sign in you will be able to subscribe for any updates here