Class: Google::Apis::GamesV1::QuestMilestone

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

Overview

This is a JSON template for a Quest Milestone resource.

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) ⇒ QuestMilestone

Returns a new instance of QuestMilestone



3057
3058
3059
# File 'generated/google/apis/games_v1/classes.rb', line 3057

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

Instance Attribute Details

#completion_reward_dataString

The completion reward data of the milestone, represented as a Base64-encoded string. This is a developer-specified binary blob with size between 0 and 2 KB before encoding. Corresponds to the JSON property completionRewardData NOTE: Values are automatically base64 encoded/decoded in the client library.

Returns:

  • (String)


3028
3029
3030
# File 'generated/google/apis/games_v1/classes.rb', line 3028

def completion_reward_data
  @completion_reward_data
end

#criteriaArray<Google::Apis::GamesV1::QuestCriterion>

The criteria of the milestone. Corresponds to the JSON property criteria



3033
3034
3035
# File 'generated/google/apis/games_v1/classes.rb', line 3033

def criteria
  @criteria
end

#idString

The milestone ID. Corresponds to the JSON property id

Returns:

  • (String)


3038
3039
3040
# File 'generated/google/apis/games_v1/classes.rb', line 3038

def id
  @id
end

#kindString

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

Returns:

  • (String)


3044
3045
3046
# File 'generated/google/apis/games_v1/classes.rb', line 3044

def kind
  @kind
end

#stateString

The current state of the milestone. Possible values are:

  • "COMPLETED_NOT_CLAIMED" - The milestone is complete, but has not yet been claimed.
  • "CLAIMED" - The milestone is complete and has been claimed.
  • "NOT_COMPLETED" - The milestone has not yet been completed.
  • "NOT_STARTED" - The milestone is for a quest that has not yet been accepted. Corresponds to the JSON property state

Returns:

  • (String)


3055
3056
3057
# File 'generated/google/apis/games_v1/classes.rb', line 3055

def state
  @state
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



3062
3063
3064
3065
3066
3067
3068
# File 'generated/google/apis/games_v1/classes.rb', line 3062

def update!(**args)
  @completion_reward_data = args[:completion_reward_data] if args.key?(:completion_reward_data)
  @criteria = args[:criteria] if args.key?(:criteria)
  @id = args[:id] if args.key?(:id)
  @kind = args[:kind] if args.key?(:kind)
  @state = args[:state] if args.key?(:state)
end