Class: McBlocky::DSL::Block

Inherits:
Object
  • Object
show all
Defined in:
lib/mcblocky/dsl/block.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(x, y, z, kind, data = 0, nbt = {}) ⇒ Block

Returns a new instance of Block.



4
5
6
7
8
9
10
11
# File 'lib/mcblocky/dsl/block.rb', line 4

def initialize(x, y, z, kind, data=0, nbt={})
  @x = x
  @y = y
  @z = z
  @block_kind = kind
  @block_data = data
  @nbt = nbt
end

Instance Attribute Details

#block_dataObject (readonly)

Returns the value of attribute block_data.



3
4
5
# File 'lib/mcblocky/dsl/block.rb', line 3

def block_data
  @block_data
end

#block_kindObject (readonly)

Returns the value of attribute block_kind.



3
4
5
# File 'lib/mcblocky/dsl/block.rb', line 3

def block_kind
  @block_kind
end

#nbtObject (readonly)

Returns the value of attribute nbt.



3
4
5
# File 'lib/mcblocky/dsl/block.rb', line 3

def nbt
  @nbt
end

#xObject (readonly)

Returns the value of attribute x.



3
4
5
# File 'lib/mcblocky/dsl/block.rb', line 3

def x
  @x
end

#yObject (readonly)

Returns the value of attribute y.



3
4
5
# File 'lib/mcblocky/dsl/block.rb', line 3

def y
  @y
end

#zObject (readonly)

Returns the value of attribute z.



3
4
5
# File 'lib/mcblocky/dsl/block.rb', line 3

def z
  @z
end