Push Events
Last updated
Last updated
The YOM SDK allows you to push your own custom events to the browser, allowing communication between the Unreal client and the pixel streamer /web browser. This guide explains how to set up, determine their event scope, and use them.
To use Push Events, first access the YOMPlayer. Via standard Unreal method:
Get the PlayerController
Cast it to YOMPlayer
Store the result if needed
Or, using GetYomPlayer function directly:
Once you have the YOMPlayer, use the PushYomEvent function:
Use the "PushYomEvent" function with these parameters:
PEventScope: Determines where the event will go
PFunction: Name of the function to call
PVariable Names: Array of variable names
PVariable Values: Array of variable values
PDataLayer: Boolean to determine whether the event should be automatically pushed forwards to the DataLayer, used by marketing and data services Google Analytics.
By following these steps, you can push communication from your Unreal Engine project to the pixelstreamer/web browser.