question

skywolfgamestudios avatar image
skywolfgamestudios asked

Set up a Player as Admin?

Can someone advise or point me in the right direction as to how I can Authenticate a specific (1) Player as an Admin in the game? I think this should be possible but I'm kinda new to Playfab and Multiplayer Servers so I wanna make sure I go about it the right way if hopefully possible here.


apisPlayer DataAuthenticationmultiplayer
2 comments
10 |1200

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

Seth Du avatar image Seth Du ♦ commented ·

To help us provide a better solution for your issue, we may need more details about your requirement. May I ask what does this "Admin" player do in your game? Is it like a GM? Does it need to manage and perform administrative actions for all players in the title? How is this Admin player involved with multiplayer gaming?

0 Likes 0 ·
skywolfgamestudios avatar image skywolfgamestudios Seth Du ♦ commented ·

Yes pretty much sort of like a GM on the Level with the ability to:

1. show/hide/add/remove a mesh on the map
2. adjust purchases, but if im not mistaken I think that might be only doable in playfab/xsolla so I might have to add the user that way outside the game

0 Likes 0 ·

1 Answer

·
Seth Du avatar image
Seth Du answered

It will be fine if the player is like a GM (normally there will be few GMs for each server). To be clear, client API calls have an upper bound of 100 calls per 2 minutes per IP, while server API won’t have this specific limit. You may implement GM functionalities on Cloud Script/Azure Function (CSAF)

It is easy to realize some features for GM to modify PlayFab player data/items and you may add Server API calls in specific CSAF functions. To authenticate GM account to ensure the CSAF execution API call is valid, you need to store a global static dictionary or a list in CSAF and when API is called, the caller information can be read from “context”, so that the function can compare with the static value you have defined.

You may also fine to store the credentials in Player Internal Data, or store GM PlayFab ID list in Title Data, which cannot be modified by players.

Meanwhile for your questions:

  1. it seems to be an issue in online multiplayer games. will the GM connect to the multiplayer server?
  2. Adjust virtual currency and items is easy. In terms of real money purchase, what GM can do is only adjusting items.
2 comments
10 |1200

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

skywolfgamestudios avatar image skywolfgamestudios commented ·

Hi Seth, thank you kindly for the advice and clarification.

  1. it seems to be an issue in online multiplayer games. will the GM connect to the multiplayer server?
    I think that would probably be yes as I don't see another way around it since the GM would need to be able to modify meshes and textures. I think Minecraft sort of does something similar I believe, just trying to understand it all further.
  2. Adjust virtual currency and items is easy. In terms of real money purchase, what GM can do is only adjusting items.
    Alright, thank you for the info.
0 Likes 0 ·
Seth Du avatar image Seth Du ♦ skywolfgamestudios commented ·

1. Besides of VC & items adjustment, modifying meshes and textures is simply server behavior, where PlayFab cannot directly involve. You may implement authentication steps to grant admin player permission on the server.

  • Store a list of admin player PlayFab ID or title player acount ID on PlayFab (refer to my previous replies)
  • Verify the player and let them submit session ticket to the server so that server can call AuthenticateSessionTicket API for verification.
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.