diff options
| -rw-r--r-- | dragon/args.rb | 18 |
1 files changed, 13 insertions, 5 deletions
diff --git a/dragon/args.rb b/dragon/args.rb index 0f39ede..0b9a2eb 100644 --- a/dragon/args.rb +++ b/dragon/args.rb @@ -163,10 +163,18 @@ module GTK @runtime end + # @return [OpenEntity] returns `OpenEntity` object that allows for storing state between ticks + # @example Storing a value in a state + # args.state.player_score = 0 + # args.state.current_time = Time.now def state @state end + # @param value [OpenEntity] the new state object to use + # @return [OpenEntity] the new state object + # @example Overwriting the state object + # args.state = OpenEntity.new def state= value @state = value end @@ -198,7 +206,7 @@ module GTK @render_targets[name] end - # @return [GTK::OutputsArray] The array of solids to render during current tick + # @return [GTK::OutputsArray] the array of solids to render during current tick def solids @outputs.solids end @@ -207,7 +215,7 @@ module GTK @outputs.static_solids end - # @return [GTK::OutputsArray] The array of sprites to render during current tick + # @return [GTK::OutputsArray] the array of sprites to render during current tick def sprites @outputs.sprites end @@ -216,7 +224,7 @@ module GTK @outputs.static_sprites end - # @return [GTK::OutputsArray] The array of labels to render during current tick + # @return [GTK::OutputsArray] the array of labels to render during current tick def labels @outputs.labels end @@ -225,7 +233,7 @@ module GTK @outputs.static_labels end - # @return [GTK::OutputsArray] The array of lines to render during current tick + # @return [GTK::OutputsArray] the array of lines to render during current tick def lines @outputs.lines end @@ -234,7 +242,7 @@ module GTK @outputs.static_lines end - # @return [GTK::OutputsArray] The array of borders to render during current tick + # @return [GTK::OutputsArray] the array of borders to render during current tick def borders @outputs.borders end |
