diff options
| author | Tom Black <[email protected]> | 2018-09-28 13:23:43 -0700 |
|---|---|---|
| committer | Tom Black <[email protected]> | 2018-09-28 13:23:43 -0700 |
| commit | aecb756b33510378d91d9737930d97a381cc9403 (patch) | |
| tree | 4787990150f31f1211b987c4c3cd4a766f80e453 /lib | |
| parent | 9b51a3b4718b082301ff70b706ac53bec8668ac9 (diff) | |
| download | ruby2d-aecb756b33510378d91d9737930d97a381cc9403.tar.gz ruby2d-aecb756b33510378d91d9737930d97a381cc9403.zip | |
Style, docs, and consistency
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/ruby2d/renderable.rb | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/ruby2d/renderable.rb b/lib/ruby2d/renderable.rb index 18c7a78..0e5da50 100644 --- a/lib/ruby2d/renderable.rb +++ b/lib/ruby2d/renderable.rb @@ -5,18 +5,21 @@ module Ruby2D attr_reader :z + # Set the z position (depth) of the object def z=(z) remove @z = z add end + # Add the object to the window def add if Module.const_defined? :DSL Window.add(self) end end + # Remove the object from the window def remove if Module.const_defined? :DSL Window.remove(self) |
