bodin avatar image
bodin asked

Is it good to run realtime puzzle game server with PlayStream?


I'm Unity developer that very new to the Playfab. after playing with Playfab Server-Client example for a while, I have design my game system, but I'm not sure if this is the proper thing to do.

let say it's a simple OX game (3x3 Tic-Tac-Toe).

to prevent the player cheating, I want to run all the game logic on the server side. client only send the user input to the server.

The picture at the bottom is my design. I already made a server & 2 clients running fine for this. (all of this running on local network)

My questions are:

- Is this the proper way to make a custom game server?

- if I copy EXE package to playfab server and run it there, Will I get a latency problem? (I expect to have the game update immediately after player clicked)

- Does this have enough capacity to support 500-1,000 players running on the same time?
(for example in my game, I need to have array of
Timer(float), Score(int), BoardData(3x3 of byte) for each Player, I afraid it will consume too much memory of the server if I have more players)

Thanks in advance & Best regards


Custom Game ServersPlayStream
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Andy avatar image
Andy answered

Assuming this is a single player game, you could execute the flow you detailed above using Cloud Script. Every arrow pointing from the client to the server is an invocation of ExecuteCloudScript. You'd implement server logic in javascript (soon C# and other .Net languages).

The down side to Cloud Script for this scenario is going to be the call rate. Cloud script would not work for a fast-paced game where you're frequently responding to user input. For a turn-based or puzzle game, though, where you're keeping the calls to once every 5-10 seconds or so, it should be fine.

If you're planning on exploring multiplayer or a faster-paced game, then you'll also want to also take a look at our server hosing tutorials documentation here:

10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

bodin avatar image
bodin answered

Hi @Andy

thank you very much for your reply.

yes, this is single player game, but I need it to be a fast-paced game that respond immediately after the user input. so I think CloudScript is not suit for my game. ( I'm also only able to coding in C#)

I'm checking your link for multiplayer server and got some more question.


There're "Legacy Multiplayer" and "Servers 2.0" on Playfab setting screen. What's the different between this 2 services? (I had read but still have no idea)

I understand that the legacy one is using Amazon EC2, and Servers 2.0 is using Microsoft Service, Am I correct?
And the game server(EXE) that I built from Unity can be run on both services, right?


about the billing detail.
for example, if I uploaded my gameserver.exe to Playfab using "Legacy Multiplayer"

and run the game on Asia server 24 Hours x 31 days = 744 Hours/month.

base on Amazon price (t2.medium on I have to pay 56.84 USD/month. is this correct?


During the game play, I'm using Playstream to send-receive user input & game data between server-client.
Is this a good way to do, or should I use another command instead?

Thanks in advance & Best regards

10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Andy avatar image Andy ♦♦ commented ·

Yes, if your game is going to be fast paced, with many user interactions that you want a quick server response for, your need to go with dedicated server hosting.

1. Yes legacy multiplayer servers are hosted on EC2. Servers 2.0 has quite a few advantages as well. It uses containers, allowing isolated environments for each server instance. It allows remoting into the host VM, easing debugging. It support a local "emulator" which is useful when developing the initial server instance. There are other advantages as well. I would not recommend the legacy server hosting at this point.

2. I didn't check your math or the price sheet, but the basic idea behind legacy servers is that we bill you for 110% of whatever Amazon bills us.

3. You shouldn't be using playstream to communicate between you client and server. You should be making direct network calls on an open port.

1 Like 1 ·
bodin avatar image bodin commented ·

Hi @Andy

thank you for your reply. This is exactly what I want to know.

Best regards,


0 Likes 0 ·
bodin avatar image bodin commented ·

Hi @Andy

sorry to ask you again, but I saw from this link
"A Free PlayFab Custom Game Server"

What is the meaning of "free" in this post?
Is it mean free 20 server hours for testing? os just this post is not update?

0 Likes 0 ·
brendan avatar image brendan bodin commented ·

Yes, that specifically refer to the limited number of free hours of test time we provide.

0 Likes 0 ·
bodin avatar image bodin brendan commented ·

got it.
thank you very much @Brendan

0 Likes 0 ·

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.