--******************************************************************* function actor_binder:on_item_take (obj) level_tasks.proceed(self.object) --game_stats.update_take_item (obj, self.object) if (isWeapon(obj)) then local sec = obj:section() local ini = system_ini() -- Check system ini if section with the postfix "_actor" exists if (ini:section_exist(sec.."_actor")) then alife():release( alife():object(obj:id()),true ) alife():create(sec.."_actor",db.actor:position(),0,0,0) end end end function actor_binder:on_item_drop (obj) level_tasks.proceed(self.object) --game_stats.update_drop_item (obj, self.object) if (isWeapon(obj) and string.find(obj:section(),"_actor")) then local sec = string.gsub(obj:section(),"_actor","") alife():release( alife():object(obj:id()),true ) alife():create(sec,db.actor:position(),db.actor:level_vertex_id(),db.actor:game_vertex_id()) end if _z.item_drop_is_intentional(obj, self.object) then if _z.on_item_drop(obj, self.object) then return end -- true = used item if use_sleeping_bag and abc_sleep and obj:section()=="sleep_bag" then if not has_alife_info("ui_inventory") then return end if _dev then _dev.queue_delayed_event({delay=1200,event="abc_sleep.show_sleep_dialog()"}) else dbglog("sleep_bag needs valid _dev.script") end end end end --*******************************************************************