Class: Google::Apis::GamesManagementV1management::Player

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
generated/google/apis/games_management_v1management/classes.rb,
generated/google/apis/games_management_v1management/representations.rb,
generated/google/apis/games_management_v1management/representations.rb

Overview

This is a JSON template for a Player resource.

Defined Under Namespace

Classes: Name

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Core::JsonObjectSupport

#to_json

Methods included from Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ Player

Returns a new instance of Player



377
378
379
# File 'generated/google/apis/games_management_v1management/classes.rb', line 377

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#avatar_image_urlString

The base URL for the image that represents the player. Corresponds to the JSON property avatarImageUrl

Returns:

  • (String)


314
315
316
# File 'generated/google/apis/games_management_v1management/classes.rb', line 314

def avatar_image_url
  @avatar_image_url
end

The url to the landscape mode player banner image. Corresponds to the JSON property bannerUrlLandscape

Returns:

  • (String)


319
320
321
# File 'generated/google/apis/games_management_v1management/classes.rb', line 319

def banner_url_landscape
  @banner_url_landscape
end

The url to the portrait mode player banner image. Corresponds to the JSON property bannerUrlPortrait

Returns:

  • (String)


324
325
326
# File 'generated/google/apis/games_management_v1management/classes.rb', line 324

def banner_url_portrait
  @banner_url_portrait
end

#display_nameString

The name to display for the player. Corresponds to the JSON property displayName

Returns:

  • (String)


329
330
331
# File 'generated/google/apis/games_management_v1management/classes.rb', line 329

def display_name
  @display_name
end

#experience_infoGoogle::Apis::GamesManagementV1management::GamesPlayerExperienceInfoResource

This is a JSON template for 1P/3P metadata about the player's experience. Corresponds to the JSON property experienceInfo



334
335
336
# File 'generated/google/apis/games_management_v1management/classes.rb', line 334

def experience_info
  @experience_info
end

#kindString

Uniquely identifies the type of this resource. Value is always the fixed string gamesManagement#player. Corresponds to the JSON property kind

Returns:

  • (String)


340
341
342
# File 'generated/google/apis/games_management_v1management/classes.rb', line 340

def kind
  @kind
end

#last_played_withGoogle::Apis::GamesManagementV1management::GamesPlayedResource

This is a JSON template for metadata about a player playing a game with the currently authenticated user. Corresponds to the JSON property lastPlayedWith



346
347
348
# File 'generated/google/apis/games_management_v1management/classes.rb', line 346

def last_played_with
  @last_played_with
end

#nameGoogle::Apis::GamesManagementV1management::Player::Name

An object representation of the individual components of the player's name. For some players, these fields may not be present. Corresponds to the JSON property name



352
353
354
# File 'generated/google/apis/games_management_v1management/classes.rb', line 352

def name
  @name
end

#original_player_idString

The player ID that was used for this player the first time they signed into the game in question. This is only populated for calls to player.get for the requesting player, only if the player ID has subsequently changed, and only to clients that support remapping player IDs. Corresponds to the JSON property originalPlayerId

Returns:

  • (String)


360
361
362
# File 'generated/google/apis/games_management_v1management/classes.rb', line 360

def original_player_id
  @original_player_id
end

#player_idString

The ID of the player. Corresponds to the JSON property playerId

Returns:

  • (String)


365
366
367
# File 'generated/google/apis/games_management_v1management/classes.rb', line 365

def player_id
  @player_id
end

#profile_settingsGoogle::Apis::GamesManagementV1management::ProfileSettings

This is a JSON template for profile settings Corresponds to the JSON property profileSettings



370
371
372
# File 'generated/google/apis/games_management_v1management/classes.rb', line 370

def profile_settings
  @profile_settings
end

#titleString

The player's title rewarded for their game activities. Corresponds to the JSON property title

Returns:

  • (String)


375
376
377
# File 'generated/google/apis/games_management_v1management/classes.rb', line 375

def title
  @title
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



382
383
384
385
386
387
388
389
390
391
392
393
394
395
# File 'generated/google/apis/games_management_v1management/classes.rb', line 382

def update!(**args)
  @avatar_image_url = args[:avatar_image_url] if args.key?(:avatar_image_url)
  @banner_url_landscape = args[:banner_url_landscape] if args.key?(:banner_url_landscape)
  @banner_url_portrait = args[:banner_url_portrait] if args.key?(:banner_url_portrait)
  @display_name = args[:display_name] if args.key?(:display_name)
  @experience_info = args[:experience_info] if args.key?(:experience_info)
  @kind = args[:kind] if args.key?(:kind)
  @last_played_with = args[:last_played_with] if args.key?(:last_played_with)
  @name = args[:name] if args.key?(:name)
  @original_player_id = args[:original_player_id] if args.key?(:original_player_id)
  @player_id = args[:player_id] if args.key?(:player_id)
  @profile_settings = args[:profile_settings] if args.key?(:profile_settings)
  @title = args[:title] if args.key?(:title)
end