Class: Google::Apis::GamesV1::QuestCriterion

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 Criterion 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) ⇒ QuestCriterion

Returns a new instance of QuestCriterion



2972
2973
2974
# File 'generated/google/apis/games_v1/classes.rb', line 2972

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

Instance Attribute Details

#completion_contributionGoogle::Apis::GamesV1::QuestContribution

This is a JSON template for a Quest Criterion Contribution resource. Corresponds to the JSON property completionContribution



2949
2950
2951
# File 'generated/google/apis/games_v1/classes.rb', line 2949

def completion_contribution
  @completion_contribution
end

#current_contributionGoogle::Apis::GamesV1::QuestContribution

This is a JSON template for a Quest Criterion Contribution resource. Corresponds to the JSON property currentContribution



2954
2955
2956
# File 'generated/google/apis/games_v1/classes.rb', line 2954

def current_contribution
  @current_contribution
end

#event_idString

The ID of the event the criterion corresponds to. Corresponds to the JSON property eventId

Returns:

  • (String)


2959
2960
2961
# File 'generated/google/apis/games_v1/classes.rb', line 2959

def event_id
  @event_id
end

#initial_player_progressGoogle::Apis::GamesV1::QuestContribution

This is a JSON template for a Quest Criterion Contribution resource. Corresponds to the JSON property initialPlayerProgress



2964
2965
2966
# File 'generated/google/apis/games_v1/classes.rb', line 2964

def initial_player_progress
  @initial_player_progress
end

#kindString

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

Returns:

  • (String)


2970
2971
2972
# File 'generated/google/apis/games_v1/classes.rb', line 2970

def kind
  @kind
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



2977
2978
2979
2980
2981
2982
2983
# File 'generated/google/apis/games_v1/classes.rb', line 2977

def update!(**args)
  @completion_contribution = args[:completion_contribution] if args.key?(:completion_contribution)
  @current_contribution = args[:current_contribution] if args.key?(:current_contribution)
  @event_id = args[:event_id] if args.key?(:event_id)
  @initial_player_progress = args[:initial_player_progress] if args.key?(:initial_player_progress)
  @kind = args[:kind] if args.key?(:kind)
end