question

brendan avatar image
brendan asked

Do not quite get match making and game servers

kwlam
started a topic on Wed, 20 August 2014 at 3:31 AM

Hi, am new to PlayFab and I hope that you guys can help. I was looking at the client matchmaking apis and read the StartGame api. I noticed that it can return IP and port. What do we use to connect to this? What do we use to interact with this lobby? I cannot seem to find any details on this. Many thanks for any answers given!

10 |1200

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

1 Answer

·
brendan avatar image
brendan answered

Best Answer
gwertzman said on Mon, 25 August 2014 at 12:25 AM

I'm afraid our multiplayer server hosting functionality isn't documented very well yet. Here's a brief summary for how it works, but we will try to get better documentation posted to our site shortly. Also know that under our new partnership with Exit Games and their Photon Server technology a lot of what I am about to describe below is going to change -- we are going to make it much easier to set up a multiplayer server using Photon and that will force changes in how we handle matchmaking and server hosting.

To take advantage of our multiplayer hosting and matchmaking, you have to first create your multiplayer game server in such a way that it can accept certain command line parameters when run to create a new game instance. Your game server can use our "server API" to connect to our PlayFab services to do things like look up player properties, hand out virtual items or currency, etc. Today we only support game servers that run on windows.

You then upload your server to our system, into an Amazon S3 bucket.

You then use the Game Manager tool to manage the new build that you just uploaded and assign it to one or more regions around the world where you want it hosted. (we are working out right now how we want to handle this for developers who are still in testing -- once you go live you would work with us to figure out how many servers you need and where)

We have a game "demon" that sits on those game servers, and responds to incoming requests from our matchmaking system. When appropriate, this demon will startup an instance of your game server, and tell it which port number to use for incoming requests. Your game server will then start running and listening for requests on that port.

Finally, the client matchmaking API tells your game which IP address and port number to find the instance of your game server. Your client connects to the server using that info, and from that point on it's your client talking directly to your game server.

All of the above needs careful documentation -- it's in our short list of things to do. If you have specific urgent needs around this you can email us at "devrel@playfab.com"


1 Comment
gwertzman said on Mon, 25 August 2014 at 12:25 AM

I'm afraid our multiplayer server hosting functionality isn't documented very well yet. Here's a brief summary for how it works, but we will try to get better documentation posted to our site shortly. Also know that under our new partnership with Exit Games and their Photon Server technology a lot of what I am about to describe below is going to change -- we are going to make it much easier to set up a multiplayer server using Photon and that will force changes in how we handle matchmaking and server hosting.

To take advantage of our multiplayer hosting and matchmaking, you have to first create your multiplayer game server in such a way that it can accept certain command line parameters when run to create a new game instance. Your game server can use our "server API" to connect to our PlayFab services to do things like look up player properties, hand out virtual items or currency, etc. Today we only support game servers that run on windows.

You then upload your server to our system, into an Amazon S3 bucket.

You then use the Game Manager tool to manage the new build that you just uploaded and assign it to one or more regions around the world where you want it hosted. (we are working out right now how we want to handle this for developers who are still in testing -- once you go live you would work with us to figure out how many servers you need and where)

We have a game "demon" that sits on those game servers, and responds to incoming requests from our matchmaking system. When appropriate, this demon will startup an instance of your game server, and tell it which port number to use for incoming requests. Your game server will then start running and listening for requests on that port.

Finally, the client matchmaking API tells your game which IP address and port number to find the instance of your game server. Your client connects to the server using that info, and from that point on it's your client talking directly to your game server.

All of the above needs careful documentation -- it's in our short list of things to do. If you have specific urgent needs around this you can email us at "devrel@playfab.com"

10 |1200

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

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.