Module: Conjuration

Defined in:
lib/conjuration/concerns/attributes.rb,
lib/conjuration.rb,
lib/conjuration/game.rb,
lib/conjuration/scene.rb,
lib/conjuration/ui/text.rb,
lib/conjuration/version.rb,
lib/conjuration/ui/button.rb,
lib/conjuration/game_object.rb,
lib/conjuration/managers/asset_manager.rb,
lib/conjuration/managers/debug_manager.rb,
lib/conjuration/managers/input_manager.rb,
lib/conjuration/managers/scene_manager.rb

Overview

Attributes

This module provides a way to define inspectable attributes for a class. It provides readers and writers for each attribute, and an inspect method that displays only defined attributes.

Instance variables are not added to the inspect output.

Usage:

class Person
  include Attributes

  attribute :name
  attribute :age
end

person = Person.new person.name = “Alice” person.age = 30 person.inspect # => “<Person name: "Alice", age: 30>”

Defined Under Namespace

Modules: Attributes Classes: AssetManager, Button, DebugManager, Error, Game, GameObject, InputManager, Scene, SceneManager, Text

Constant Summary collapse

VERSION =
"0.2.0"