Receiving in-game notifications for invites, allows, and other events from a live multiplayer game is essential. The tricky part is providing a unified experience across multiple platforms with potentially different hardware requirements. Nodecraft Studio’s Notifications are simple and easy to use, so you can add notifications without the worry of potentially problematic user-created content, chat, or voice-coms being platform-specific.

Getting Started

To get near-real-time notifications, we’ve created a simple system that helps you poll for new notifications, while also balancing any data you may have missed.

First Notifications Request

When sending the first Long Poll for notifications, don't send the since date string parameter in the data payload. This ensures the Player gets a copy of all pending notifications that may have been missed.

Prevent Duplicate Notifications

Each following request should include a since timestamp set for the date the last response was given to the game client. This will ensure that you only receive new notifications, prevent duplication, and ensure that the notification request is quick.

Long Poll For Notifications

It’s recommended that each game request notification is between 8-15 second intervals. Notifications cannot be requested any more frequently without triggering rate-limiting and risking a degraded user experience.

This Long Poll is also used to track player status and keep their authentication fresh. If you do not implement this feature, the player session will expire based on the Player Token expiration date and other features may see this Player as offline or idle.

What’s Next