Notifying event when other user going in background

Options
Hi,

How to get notifying event immediately when other user appliaction lose focus.
Is there any event which is called immediately when other user appliaction lose focus.

Comments

  • Hi @Yogesh_Dev,

    There is no event called immediately. However there is another approach you can try.

    I think we already have discussed the two Unity callbacks when the application goes in background. I guess you can use them here as well. Inside this callback you can use PhotonNetwork.RaiseEvent to send a custom event to other clients in the room. To see how this works, I recommend you taking a look at the RPCs and RaiseEvent documentation page. After using this function, make sure to call PhotonNetwork.SendOutgoingCommands(); to make sure this message gets sent.