quest kill_spawn_mob begin state start begin when login or levelup begin set_state( goto_spawn_mob ) end end state goto_spawn_mob begin when letter begin send_letter(" Убейте диких собак ") end when button or info begin say("") say_reward(" Убейте 3 диких собак ") say("") local v=mob.spawn(101, pc.get_local_x(), pc.get_local_y(), 1, 1, 1) target.npc("mob1", v) local v=mob.spawn(101, pc.get_local_x(), pc.get_local_y(), 1, 1, 1) target.npc("mob2", v) local v=mob.spawn(101, pc.get_local_x(), pc.get_local_y(), 1, 1, 1) target.npc("mob3", v) set_state( goto_kill_mob ) end end state goto_kill_mob begin when login begin local i = 3 - pc.getqf("101_count") send_letter(i.." Убейте диких собак ") end when button or info begin local i = 3 - pc.getqf("101_count") say("") say_reward(" Осталось убить "..i.." диких собак! ") say("") end when 101.kill begin if pc.getqf("101_count") == 0 then pc.setqf("101_count", 1) elseif pc.getqf("101_count") == 1 then pc.setqf("101_count", 2) elseif pc.getqf("101_count") == 2 then pc.setqf("101_count", 2) target.delete("mob1") target.delete("mob2") target.delete("mob3") set_state( goto_complete ) end end end state goto_complete begin when letter begin send_letter(" Квест выполнен ") end when button or info begin say("") say_reward(" Чудно, вы убили злобных собак ") say("") pc.delqf("count") -- тута можно запилить награду>_< set_state( complete ) end end state complete begin end end
Ну вот вроде все Удачи вам в создании серверов MMOG Metin2 >_<