Is webhook SendState available in PUN and if so, how to send it?

Options
Hello.
Our company is using PUN for our 6vs6 multiplayer fps-like game in late development.
We have a need to use RaiseEvent to fire a GameEvent webhook and send a full room state through, along with some serialized data. I have familiarized myself with both the Photon Realtime and PUN documentations. Although there is no mention of Webhooks in the PUN docs, I have succesfully configured our app account to send one when a GameEvent is fired and received it properly on the endpoint.
I have seen the use of SendState in the Realtime documentation and wanted to ask if it is possible to have similar behaviour in PUN. What I ultimately need are player usernames and possibly their custom properties or at least teams from the room state.

Here's how I achieved it in PUN
{ byte eventCode = 0; RaiseEventOptions options = new RaiseEventOptions(); options.ForwardToWebhook = true; PhotonNetwork.RaiseEvent(eventCode, "Testing webhook", true, options); Debug.Log("Sending event"); }
Hope to hear some advice on the subject and possibly tips on achieving my goal.
Thank you.

Comments

  • JohnTube
    JohnTube ✭✭✭✭✭
    Options
    Hi @Zych,

    Thank you for choosing Photon!

    It is possible to have webflags in PUN yes.
    We decided PUN will not have webflags for now.

    The same logic and code can be copied from Realtime to PUN.
    Refer to this discussion for more details.