Class: Cyberpunks::Spritesheet
- Inherits:
-
Object
- Object
- Cyberpunks::Spritesheet
- Defined in:
- lib/cyberpunks.rb
Class Method Summary collapse
- .builtin ⇒ Object
-
.find_by(name:) ⇒ Object
note: for now class used for “namespace” only.
Class Method Details
.builtin ⇒ Object
17 18 19 20 21 22 |
# File 'lib/cyberpunks.rb', line 17 def self.builtin @builtin ||= Pixelart::Spritesheet.read( "#{Cyberpunks.root}/config/spritesheet.png", "#{Cyberpunks.root}/config/spritesheet.csv", width: 32, height: 32 ) end |
.find_by(name:) ⇒ Object
note: for now class used for “namespace” only
24 25 26 27 |
# File 'lib/cyberpunks.rb', line 24 def self.find_by( name: ) ## return archetype/attribute image by name # note: pass along name as q (query string) builtin.find_by( name: name ) end |