indexing description: "Remove Action" author: "Adrian Rabenseifner, radrian@student.ethz.ch" date: "$Date$" revision: "$Revision$" class REMOVE inherit ACTION redefine perform end create make feature {NONE} -- Initialization make(pitem: ITEM) is -- Initialize `Current'. do init_condition_lists item := pitem end feature -- Access item: ITEM perform(e: EVENT; g: GAME) is -- perform action on given game Object do -- remove item to repository (move to trash) g.repository.remove_item(item) g.trash.add_item(item) -- item automatically disaperas from scene during next "get_current_scene" call -- visibility check is performed just in time (see ENGINE, ITEM) -- only need to force redraw of items in scene (no need to repaint whole scene) g.items_have_been_changed -- debug output -- io.put_string("action performed: remove item") -- io.put_new_line end set_item(pitem: ITEM) is -- set item do item := pitem end end -- class REMOVE