[Google Play Games Services] realtime multiplayer game players/participants online status

I try to create realtime multiplayer game, based on sdkbox-sample-gpg; working with RealTimeMultiplayerScene.cpp
I’ve succeed to create the room and to start the match.
How can I ensure if a realtime multiplayer game player/participant is online?
I can use:

  1. for (auto part : _room.Participants()) { part.Player().Valid() // sorry, wtf is this? part.Valid(); part.IsConnectedToRoom(); }
    // two last both return true for all players, even before message sending and after player get notified other player has left the room. I use not the last cocos2d-x-3.15.1

  2. SendReliableMessage(… SendReliableMessageCallback callback); - it doesn’t block the app, but from the callback function I can’t get, for with participant I get a response - if I have more than 3 players, and if I send info to all of them at one cycle/time without waiting response.

  3. MultiplayerStatus SendReliableMessageBlocking( Timeout timeout, …) - it blocks the app, that’s not good.

Questions update: :slight_smile:
Q1: What real-time multiplayer games (using google-play-services) were been created on C++ on Cocos?
Q2: Are there real-time multiplayer games free engines for C++?

Q3: What real-time multiplayer games (using google-play-services) were been created on C++ (in any IDE)?

This is some early sample game using multiplayer service

Hello.
I think I did it (during about a year).
I named it “network multi-player engine” (actually it’s only transport level, no game logic support).

The NMPE helps with some things in GPG multiplayer game:

  1. The engine watches, if all participants=players are online;
  2. The engine quickly sends short unreliable data - up to 1160 bytes; to all or to some participants=players;
  3. The engine delivers data - up to 70 Mega-bytes; to all or to some participants=players;

Link to the sample=demo: SDKBOX GPG testbed for nmpe

The NMP-engine is designed on C++ using GPG.
Now is created the version, based on Cocos2d-x + SDKBOX.

Any ideas/offers, how could I get money for it?

1 Like

Make it open source and add donation :wink:

Google Play Games SDK supports C++ https://developers.google.com/games/services/cpp/GettingStartedNativeClient

What you did in your engine?

Make it open source and add donation

Good idea, but not for me. I think I may try AngelList.

Google Play Games SDK supports C++

This is why my engine based on it. But fully implemented on Cocos2d-x.

What you did in your engine?

I tried two functions SendReliableMessage() and SendUnreliableMessage().
First one stops the app execution (as I remember); the second is unreliable, and has message size limitation - 1168 bytes.
So I have created the engine for my needs - it takes care about transporting you message to all or to some participants; without interrupting the app. Message size may be up to 64 Mb.
In this testbed app sending messages (images) size are limited to 300 Kb.
Also engine checks if all participants are online. After some timeout the engine offers to dismiss the participant, later it dismisses it.