class RuneRb::World::ItemEvent

Public Class Methods

new() click to toggle source
Calls superclass method RuneRb::Engine::Event::new
# File app/world/item_spawns.rb, line 21
def initialize()
  super(1000)
end

Public Instance Methods

execute() click to toggle source
# File app/world/item_spawns.rb, line 25
def execute
  ItemSpawns.items.each {|item|
    item.respawn -= 1 if item.picked_up
    
    if item.picked_up && item.respawn <= 0
      item.spawn
    end
  }
end