Перейти к контенту

Правка свойств ГГ: Промежуток времени между сном

в amk_mod.script в разделе SLEEP_AMK
function test_for_need_sleep_matras(oid)
if alife():object(oid)==nil then
local enemy=false
for a=0,65534 do
local obj=level.object_by_id(a)
if obj then
if (( IsStalker(obj) and amk.get_npc_relation(obj,db.actor)=="enemy" ) or
IsMonster(obj)) and obj:position():distance_to(db.actor:position())<40
and obj:see(db.actor) then
enemy=true
break
end
end
end
if enemy==true then
amk.send_tip(game.translate_string("not_need_sleep_enemy"),nil,nil,5)
else
if amk.load_variable("blowout",-1)>-1 and amk.load_variable("blowout",-1)<5 then
amk.send_tip(game.translate_string("blowout_not_sleep"),nil,nil,5)
else
if amk.load_variable("block_sleep_menu",0)==0 then
-- if amk.load_variable("gg_need_sleep",0)>10 then
local spwn=ui_cheat.cheat(get_hud())
level.start_stop_menu(spwn,true)
-- else
-- amk.send_tip(game.translate_string("not_need_sleep"),nil,nil,5)
-- end
else
amk.send_tip(game.translate_string("not_need_sleep_nrg"),nil,nil,5)
end
end
end
amk.spawn_item_in_inv("matras")
end
end

Категории

AMK-Team.ru

×
×
  • Создать...