- using class level state is generally considered to be dangerous. (@@var type stuff) - OK for this project since it's the only thing using its own code, but if this were a gem where people could pull in your code, imagine what would happen if someone accesses the Conditions/Equipments/Spells
@@allattribute and changes stuff?
- as an alternative, you could create wrapping objects (something like
EquipmentCollection) that exist just to fetch and hold all of the items, and your CLI would talk to those Collection objects to present the lists of all of the items.
- consider using a gemfile/gemspec (gemspec if this could be a gem) to declare your dependencies
- declaring an array and shoveling items into it is redundant in ruby:
things = [] doodads.each { |dd| things << "based god say: #{dd}" } # is equivalent to: