Method: Area#initialize

Defined in:
lib/Olib/area.rb

#initializeArea



9
10
11
12
13
14
15
16
17
18
# File 'lib/Olib/area.rb', line 9

def initialize
  @contents = []
  @room     = Room.current
  @objects  = [ GameObj.loot, GameObj.room_desc ]
    .flatten
    .compact
    .map { |thing| thing.id }
    .uniq # sometimes objects exist in both loot & room_desc
    .map { |id| Olib::Container.new id }
end