Class: Gamefic::Sdk::Diagram::Position
- Inherits:
-
Object
- Object
- Gamefic::Sdk::Diagram::Position
- Defined in:
- lib/gamefic-sdk/diagram.rb
Instance Attribute Summary collapse
-
#x ⇒ Object
Returns the value of attribute x.
-
#y ⇒ Object
Returns the value of attribute y.
Instance Method Summary collapse
-
#initialize(x = 0, y = 0) ⇒ Position
constructor
A new instance of Position.
- #move(x, y) ⇒ Object
Constructor Details
#initialize(x = 0, y = 0) ⇒ Position
Returns a new instance of Position.
11 12 13 14 15 |
# File 'lib/gamefic-sdk/diagram.rb', line 11 def initialize x = 0, y = 0 @x = x @y = y freeze end |
Instance Attribute Details
#x ⇒ Object
Returns the value of attribute x.
9 10 11 |
# File 'lib/gamefic-sdk/diagram.rb', line 9 def x @x end |
#y ⇒ Object
Returns the value of attribute y.
9 10 11 |
# File 'lib/gamefic-sdk/diagram.rb', line 9 def y @y end |