3

I have successfully integrated PubNub into my Unity project. The chat function is working. Now I am looking for a way to receive push notifications when the user is offline.

I am familiar with how GCM works. So basically, I can find the GCM API key and put it in PubNub dashboard. However, on Unity side, I suppose there has to be a plugin for this but I cannot find it anywhere.

Hans1984
  • 796
  • 11
  • 24

1 Answers1

2

To send the GCM push notifications to the device:

To process GCM notifications using unity you need a third party asset like the ones here (Currently our Unity SDK doesn’t have the feature):

Or develop a “service” that will keep running in the background, using Java, to process the notification and pass to the Unity app. You need a service outside Unity because Unity apps are killed when they in background (runInBackground is unreliable on mobile devices).

Community
  • 1
  • 1
Craig Conover
  • 4,710
  • 34
  • 59