getnamo / GlobalEventSystem-Unreal

Loosely coupled internal event system plugin for the Unreal Engine.
MIT License
254 stars 42 forks source link

C++ Emit doesn't fill prop pointers correctly for lambda/delegate listeners #15

Open getnamo opened 3 years ago

getnamo commented 3 years ago

If we use the BP execGESEmitEventOneParam our emit data will already contain the correct prop pointers when the event gets processed.

However if we emit directly from c++ i.e. via FGESHandler::DefaultHandler()->EmitEvent(EmitData); this won't necessarily fill the prop pointer if your receiver is a lambda or delegate.

Needs a fill/conversion step before we handle the emit

getnamo commented 3 years ago

tagged branch: https://github.com/getnamo/global-event-system-ue4/tree/feaute-cpp-lambda-receiver

getnamo commented 3 years ago

Only remaining non-working pair is c++ struct to bp. All other pairs work. Note added in readme, merging current branch until more dev time is found.

https://github.com/getnamo/global-event-system-ue4#current-important-issue

getnamo commented 1 year ago

5.1 changes (https://github.com/getnamo/GlobalEventSystem-Unreal/commit/21c0d12f885d785adf7425e90e76db31fe8f49b8) have not solved this issue yet