Page cover

Usage of Payload

How to use the Payload obje

Make sure you have read the Implementation Guide before proceeding with any examples for optimal results!

  1. Bind the event SaveScore in BeginPlay():

Add it to your Blueprint
  1. the OnEventCalled() event and add one of the two code examples:

It is recommended to use Interfaces instead of casting!

Quick way with casting, not recommended for large scale (Click on the image for original resolution)

Done! Now you can use CallEvent() everywhere you want and pass a BPO_MyPayload to it like this:

If you cache a reference to a Payload for any reason, make sure to clear the variable as it won't be collected by the Garbage Collector otherwise.

For this example I placed this into the Level Blueprint
Print result

Last updated