27 lines
714 B
TypeScript
27 lines
714 B
TypeScript
// Metro module 4099 (f4100).
|
|
export default function gameServerResponseToInstance(a0) {
|
|
let players_count = a0.players_count;
|
|
if (players_count == null) {
|
|
players_count = 0;
|
|
}
|
|
return {
|
|
id: a0.id,
|
|
name: a0.name,
|
|
regionId: a0.region_id,
|
|
regionName: a0.region_name,
|
|
planId: a0.sku_id,
|
|
planName: a0.plan_name,
|
|
onlineConnectionsCount: players_count,
|
|
maxConnectionsCount: a0.max_players_count,
|
|
serverIP: a0.ip,
|
|
port: a0.port,
|
|
entitlementId: a0.entitlement_id,
|
|
subscriptionId: a0.subscription_id,
|
|
providerType: a0.provider_type,
|
|
gameServerPanelUrl: a0.provider_url,
|
|
status: a0.status,
|
|
gameId: a0.game_id,
|
|
gameConfig: a0.game_config
|
|
};
|
|
};
|