Skip to main content

Player profile

A player profile is a collection of information about a player's progress, achievements, and preferences within the game. It is essentially a digital identity that represents a player's activities and progress in the game world.

A typical player profile may include the player's username, avatar or character, level, experience points, inventory, and achievements. It may also show the player's stats, such as win-loss ratio, completion percentage, and other metrics that measure progress and performance.

Player profiles can be accessed by other players within the game or by the game developers themselves. They can be used to track player activity and engagement, offer personalized recommendations, and provide rewards or recognition for achievements.

Overall, player profiles in games are important tools for tracking progress, measuring performance, and creating a personalized gaming experience for players.

Players list

Open Liveops tools and select Players on the sidebar(https://liveops.oneb.tech/players)

When the player plays the game and do some progress, the player will be listed here players.png

Player detail

We can view player profiles/data.. and edit data on this page player detail

API

use the command GetPlayerDataCommand("DATA_NAME") to get the player's data

use the command UpdatePlayerDataCommand("DATA_NAME", Data) to create/update the player's data

An Example to get a profile and update the name of the player

import { OneBServicesClient, GetPlayerDataCommand, UpdatePlayerDataCommand, APIType } from "@oneb-sdk/client";
const client = new OneBServicesClient({
gameId: "DEMO",
apiType: APIType.BINARY,
});
//get profile
const playerProfile = await client.send<PlayerProfile>(new GetPlayerDataCommand("Profile"), PlayerProfile);
// update name
const playerProfileUpdate = await client.send<PlayerProfile>(
new UpdatePlayerDataCommand<IPlayerProfileInput>(
"Profile",
{
playerName: "DR.WHO"
},
PlayerProfileInput
),
PlayerProfile
);