Class: DiamondLang::Helpers::FallingSand

Inherits:
Entity show all
Defined in:
lib/diamond-lang/helpers/falling_sand.rb

Instance Attribute Summary

Attributes inherited from Entity

#data, #id

Instance Method Summary collapse

Methods inherited from Entity

#passengers, #passengers=, #selector, #summon, #to_h

Constructor Details

#initialize(block = Block.new('sand'), time = 1) ⇒ FallingSand

Returns a new instance of FallingSand.



4
5
6
7
8
9
10
# File 'lib/diamond-lang/helpers/falling_sand.rb', line 4

def initialize(block=Block.new('sand'), time=1)
  super 'FallingSand', {
    Block: block.id,
    Time: time,
    Data: block.data_value
  }
end