server/gamefiles/locale/english/quest/pre_qc/flame_dungeon.quest

718 lines
26 KiB
Plaintext
Raw Normal View History

quest flame_dungeon begin
state start begin
--when 20394.click with pc.get_level() >= 90 begin
--pc.give_item2(71175, 1)
--set_state(run)
--end
--end
--state run begin
function setting()
return
{
["bossroom_entry_pos"] = {8109,6867},
["boss_pos"] = {686,637},
["doors_pos"] = {
{320,394},
{293,359},
{333,321},
{378,320},
{400,355},
{394,401}
},
["idoors_pos"] = {
{268,447},
{234,359},
{300,264},
{454,217},
{470,355},
{467,469}
},
["doors_dir"] = {135,90,210,152,90,223},
["idoors_dir"] = {135,90,210,135,90,239},
["dungeon_entry_pos"] = {7762, 6739},-- <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ó<><C3B3> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><>
["DUNGEON_MAN_bpos"] = {690,722},
["DUNGEON_MAN_pos"] = {354,362},
["LEVEL2_STONE_pos"] = {195,352},
["LEVEL4_TARGET_pos"] = {470,175},
["LEVEL5_STONE_pos"] = {
{486, 345},
{511, 336},
{525, 349},
{521, 365},
{503, 372},
{486, 365},
{500, 354}
},
["LEVEL6_TARGET_pos"] = {511,480},
["outside_entry_pos"] = {6142,7068}, --<2D><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ִ¾<D6B4> <20><><EFBFBD>ִ<EFBFBD> <20><>
["YAK_pos"] = {376, 397} -- <20><>ȯ <20><><EFBFBD><EFBFBD>
}
end
function is_flamed(idx) -- <20><><EFBFBD><EFBFBD><E6BCBA> <20>ִ<EFBFBD><D6B4><EFBFBD> Ȯ<><C8AE>
return idx >= 351 * 10000 and idx < (351 + 1) *10000
end
function make_dungeon() -- <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
local setting = flame_dungeon.setting()
d.new_jump_party(351, setting.dungeon_entry_pos[1], setting.dungeon_entry_pos[2])
-- d.spawn_mob_ac_dir(20385, setting.DUNGEON_MAN_pos[1], setting.DUNGEON_MAN_pos[2],0)
-- d.spawn_mob(YAK,setting.YAK_pos[1],setting.YAK_pos[2])
d.regen_file("data/dungeon/flame_dungeon/npc.txt")
d.setf("level",0)
for i=1,6 do
d.set_unique("door"..i, d.spawn_mob_ac_dir(20387, setting.doors_pos[i][1], setting.doors_pos[i][2],setting.doors_dir[i]))
end
for i=1,6 do
d.set_unique("idoor"..i, d.spawn_mob_ac_dir(20388, setting.idoors_pos[i][1], setting.idoors_pos[i][2],setting.idoors_dir[i]))
end
d.setf("clear_count",0)
d.setf("started",0)
d.setf("dungeon_enter",0) -- <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>ߴ<EFBFBD><DFB4><EFBFBD>? // <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> : 0 <20><><EFBFBD><EFBFBD> : 1 // ƨ<><C6A8><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ѽð<D1BD><C3B0><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
end
function go_boss() -- <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
local setting = flame_dungeon.setting()
if pc.get_level() < 104 then --<2D><><EFBFBD><EFBFBD>Ȯ<EFBFBD><C8AE>
-- syschat(gameforge.flame_dungeon._580_notice)
say(gameforge.flame_dungeon._580_notice)
return
else
--if pc.getf("main_quest_flame_lv103", "__status")==main_quest_flame_lv103.__COMPLETE__ then -- <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ʈ Ȯ<><C8AE>
-- -- say_title(gameforge.flame_dungeon._010_say)
say(gameforge.flame_dungeon._010_say)
local warp = select(gameforge.flame_dungeon._020_select,gameforge.flame_dungeon._030_select)
if warp == 1 then
d.setf("level",17)
d.jump_all(setting.bossroom_entry_pos[1],setting.bossroom_entry_pos[2])
d.set_regen_file ("data/dungeon/flame_dungeon/".."fd_fild_boss.txt")
-- d.spawn_mob(20385,setting.DUNGEON_MAN_bpos[1],setting.DUNGEON_MAN_bpos[2])
d.spawn_mob(6091,setting.boss_pos[1],setting.boss_pos[2])
end
-- else
-- -- syschat(gameforge.flame_dungeon._040_notice)
-- say(gameforge.flame_dungeon._040_notice)
-- return
-- end
end
end
function level_clear() -- <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>, <20><><EFBFBD><EFBFBD>Ŭ<EFBFBD><C5AC><EFBFBD><EFBFBD>, <20><><EFBFBD><EFBFBD>Ŭ<EFBFBD><C5AC><EFBFBD><EFBFBD>
d.setf("level",0)
d.clear_regen()
d.purge_area(750000,620000,817400,689400) -- <20><><EFBFBD><EFBFBD>ü -- d.purge() <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
end
function clear_timer(inx) -- Ÿ<≯<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
clear_server_timer ("flame_dungeon_0m_left_timer", inx)
clear_server_timer ("flame_dungeon_1m_left_timer", inx)
clear_server_timer ("flame_dungeon_5m_left_timer", inx)
clear_server_timer ("flame_dungeon_10m_left_timer", inx)
clear_server_timer ("flame_dungeon_15m_left_timer", inx)
clear_server_timer ("flame_dungeon_30m_left_timer", inx)
clear_server_timer ("flame_dungeon_45m_left_timer", inx)
clear_server_timer ("killed_A_1", inx)
clear_server_timer ("killed_A_2", inx)
clear_server_timer ("flame_dungeon_ticket_remove", inx)
end
when login begin
local idx = pc.get_map_index()
local setting = flame_dungeon.setting()
if idx == 351 then
pc.warp(setting.outside_entry_pos[1]*100, setting.outside_entry_pos[2] * 100, 62)
elseif flame_dungeon.is_flamed(idx) then -- <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>, <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
------------------------------------------------------------------------------------------------------------------------------------------------------
--<2D>Ʒ<EFBFBD><C6B7><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>ϸ<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>ٽ<EFBFBD> <20><><EFBFBD><EFBFBD> <20><>ġ<EFBFBD><C4A1> <20><><EFBFBD>ƿ´<C6BF>. <20>Ʒ<EFBFBD><C6B7><EFBFBD><EFBFBD><EFBFBD> Ȱ<><C8B0>ȭ <20>ϸ<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>ȴ<EFBFBD>.
--<2D><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20>ٽ<EFBFBD> <20><><EFBFBD><EFBFBD> <20><>ġ<EFBFBD><C4A1> <20><><EFBFBD>ƿ<EFBFBD> <20><><EFBFBD><EFBFBD>, <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>ϱ<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><E6BCBA><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>ɼ<EFBFBD><C9BC><EFBFBD> Ȱ<><C8B0>ȭ <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>Ѵ<EFBFBD>.
------------------------------------------------------------------------------------------------------------------------------------------------------
-- pc.set_warp_location(0, 0 , 0) --ƨ<><C6A8><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>ٽ<EFBFBD> <20><><EFBFBD>ƿ<EFBFBD><C6BF><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>ִ<EFBFBD> <20>κ<EFBFBD>
pc.set_warp_location(62, setting.outside_entry_pos[1] , setting.outside_entry_pos[2]) -- <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ƨ<><C6A8><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
local ticketGroup = {71095, 1, 71130, 1}
if d.getf("dungeon_enter") == 0 then -- <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>ƴϸ<C6B4>
local canPass = false
for i=1, table.getn(ticketGroup),2 do
if pc.count_item(ticketGroup[i]) >= ticketGroup[i+1] then
canPass = true
break
end
end
if get_global_time() - pc.getf("flame_dungeon","exit_time") < 30 * 60 then -- <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ѽð<D1BD><C3B0><EFBFBD> <20>ɷ<EFBFBD><C9B7><EFBFBD><EFBFBD><EFBFBD>
notice_multiline(gameforge.flame_dungeon._050_notice,d.notice)
say(gameforge.flame_dungeon._060_say)
timer("flame_dungeon_warp_timer", 5)
elseif not canPass then
notice_multiline(gameforge.flame_dungeon._070_notice,d.notice)
say(gameforge.flame_dungeon._080_say)
timer("flame_dungeon_warp_timer", 5)
elseif pc.get_level() < 100 then
notice_multiline(gameforge.flame_dungeon._090_notice,d.notice)
say(gameforge.flame_dungeon._100_say)
timer("flame_dungeon_warp_timer", 5)
end
elseif pc.getf("flame_dungeon","ticket_delete") == 0 then -- <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ε<EFBFBD> Ƽ<><C6BC><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
for i=1, table.getn(ticketGroup),2 do
if pc.count_item(ticketGroup[i]) >= ticketGroup[i+1] then
pc.remove_item(ticketGroup[i], ticketGroup[i+1])
break
end
end
pc.setf("flame_dungeon","ticket_delete",1)
end
else
pc.setf("flame_dungeon","ticket_delete",0)
end
end
when flame_dungeon_warp_timer.timer begin
local setting = flame_dungeon.setting()
pc.warp(setting.outside_entry_pos[1]*100, setting.outside_entry_pos[2] * 100, 62)
end
when logout begin
local idx = pc.get_map_index()
if flame_dungeon.is_flamed(idx) then
if d.getf("dungeon_enter") == 1 then -- <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><> <20>α׾ƿ<D7BE>
pc.setf("flame_dungeon","exit_time",get_global_time()) -- <20>ν<EFBFBD><CEBD>Ͻ<EFBFBD> <20>ȿ<EFBFBD><C8BF><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>ð<EFBFBD><C3B0><EFBFBD> <20><><EFBFBD><EFBFBD>, <20>ٵ<EFBFBD> <20>ð<EFBFBD><C3B0><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> or <20>׳<EFBFBD> ƨ<><C6A8><EFBFBD>Ÿ<EFBFBD> <20>ȱ<EFBFBD><C8B1><EFBFBD>
end
end
end
when 20394.chat.gameforge.flame_dungeon._110_npcChat begin
local setting = flame_dungeon.setting()
if party.is_party() then
-- <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>ϵ<EFBFBD><CFB5><EFBFBD>
local party_check = 0
if d.find(party.getf("dungeon_index")) then
party_check = (d.getf_from_map_index("party_leader_pid", party.getf("dungeon_index")) == party.get_leader_pid())
end
if d.find(party.getf("dungeon_index")) and party_check then
if get_global_time() - pc.getf("flame_dungeon","exit_time") < 5 * 60 then -- <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> 5<><35> <20><>?
local dungeon_level = d.getf_from_map_index("level", party.getf("dungeon_index"))
if dungeon_level == 17 then -- <20><><EFBFBD><EFBFBD>
pc.warp(setting.bossroom_entry_pos[1] * 100, setting.bossroom_entry_pos[2] * 100, party.getf("dungeon_index"))
else
pc.warp(setting.dungeon_entry_pos[1] * 100, setting.dungeon_entry_pos[2] * 100, party.getf("dungeon_index"))
end
else -- 5<><35> <20>ʰ<EFBFBD><CAB0>Ͽ<EFBFBD> <20><> <20><><EFBFBD><EFBFBD> <20>Ұ<EFBFBD>
say_title(mob_name(20394))
say(gameforge.flame_dungeon._590_say)
end
else
local pids = {party.get_member_pids()}
local noTicketMembers = {}
local notEnoughLevelMembers = {}
local ticketCheck = true
local levelCheck = true
local ticketGroup = {71095, 1, 71130, 1}
for i, pid in next, pids, nil do
q.begin_other_pc_block(pid)
local canPass = false
for idx=1, table.getn(ticketGroup),2 do
if pc.count_item(ticketGroup[idx]) >= ticketGroup[idx+1] then
canPass = true
break
end
end
if not canPass then
table.insert(noTicketMembers, pc.get_name())
ticketCheck = false
end
if pc.level < 100 then
table.insert(notEnoughLevelMembers, pc.get_name())
levelCheck = false
end
q.end_other_pc_block()
end
if not ticketCheck then
say_title(mob_name(20394))
say(gameforge.flame_dungeon._610_say)
for i, name in next, noTicketMembers, nil do
say(color(1,1,0), " "..name)
end
if levelCheck then
return
else
wait()
end
end
if not levelCheck then
say_title(mob_name(20394))
say(gameforge.flame_dungeon._630_say)
for i, name in next, notEnoughLevelMembers, nil do
say(color(1,1,0), " "..name)
end
return
end
if party.is_leader() then
say(gameforge.flame_dungeon._120_say)
local warp = select(gameforge.flame_dungeon._130_select,gameforge.flame_dungeon._140_select)
if warp == 1 then
if party.is_map_member_flag_lt("exit_time", get_global_time() - 30 * 60 ) then
flame_dungeon.make_dungeon()
else
--say("test : <20><>Ƽ<EFBFBD><C6BC><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD>ѽð<D1BD><C3B0><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>ʾҽ<CABE><D2BD>ϴ<EFBFBD>.")
say(gameforge.flame_dungeon._600_say)
end
end
party.setf("flame_dungeon_boss_kill_count", 0)
else
say(gameforge.flame_dungeon._150_say)
end
end
else
say(gameforge.flame_dungeon._160_say)
end
end
-- when 20394.chat."Test : <20><><EFBFBD>ҽ<EFBFBD>Ȯ<EFBFBD><C8AE>" with is_test_server() begin -- <20>׽<EFBFBD>Ʈ<EFBFBD><C6AE>
-- local setting = flame_dungeon.setting()
-- pc.setf("flame_dungeon","fdRtest",1)
-- pc.warp( setting.dungeon_entry_pos[1]*100, setting.dungeon_entry_pos[2]*100, 351)
-- end
when 20394.chat."TEST : Init time limit init" with is_test_server() begin -- <20>׽<EFBFBD>Ʈ<EFBFBD><C6AE>
pc.setf("flame_dungeon","exit_time",get_global_time()-1800)
say("Done")
end
-- when 20385.chat."Test : <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>" with is_test_server() begin -- <20>׽<EFBFBD>Ʈ<EFBFBD><C6AE>
-- say("<22><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> : "..d.count_monster())
-- say("level : "..d.getf("level"))
-- say("Dmap index : "..d.get_map_index())
-- say("Pmap index : "..pc.get_map_index())
-- say("access limit : "..pc.getf("flame_dungeon","exit_time"))
-- say("global time : "..get_global_time())
-- if flame_dungeon.is_flamed(d.get_map_index()) then
-- say("in dungeon") -- is_flamed <20>Լ<EFBFBD> üũ
-- end
-- if d.is_unique_dead("stone1") then
-- say("stone1 is dead")
-- else
-- say("stone1 is not dead")
-- end
-- end
-- when 20385.chat."ó<><C3B3><EFBFBD><EFBFBD><EFBFBD><EFBFBD>" begin -- <20>׽<EFBFBD>Ʈ<EFBFBD><C6AE>
-- say("<22>ʱ<EFBFBD>ȭ <20>մϴ<D5B4>")
-- flame_dungeon.clear_timer(d.get_map_index())
-- flame_dungeon.make_dungeon()
-- end
when 20385.chat."Test : Boss Room" with is_test_server() begin -- <20>׽<EFBFBD>Ʈ<EFBFBD><C6AE>
flame_dungeon.go_boss()
end
-- < <20>ð<EFBFBD> <20><><EFBFBD><EFBFBD> Ÿ<≯<EFBFBD>>
-- when 20385.chat."<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>" begin -- <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ƨ<><C6A8><EFBFBD><EFBFBD> <20>ʰ<EFBFBD> <20><> <20><><EFBFBD><EFBFBD> Ȱ<><C8B0>ȭ
-- local setting = flame_dungeon.setting()
-- say("<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>ðڽ<C3B0><DABD>ϱ<EFBFBD>?")
-- local warp = select("Ȯ<><C8AE>","<22><><EFBFBD><EFBFBD>")
-- if warp == 1 then
-- pc.warp(setting.outside_entry_pos[1]*100, setting.outside_entry_pos[2] * 100, 62)
-- end
-- end
when flame_dungeon_45m_left_timer.server_timer begin
if d.select(get_server_timer_arg()) then
notice_multiline(string.format(gameforge.flame_dungeon._180_notice, 45),d.notice)
notice_multiline(gameforge.flame_dungeon._170_notice,d.notice)
server_timer('flame_dungeon_30m_left_timer', 15*60, get_server_timer_arg())
end
end
when flame_dungeon_30m_left_timer.server_timer begin
if d.select(get_server_timer_arg()) then
notice_multiline(string.format(gameforge.flame_dungeon._180_notice, 30),d.notice)
notice_multiline(gameforge.flame_dungeon._170_notice,d.notice)
server_timer('flame_dungeon_15m_left_timer', 15*60, get_server_timer_arg())
end
end
when flame_dungeon_15m_left_timer.server_timer begin
if d.select(get_server_timer_arg()) then
notice_multiline(string.format(gameforge.flame_dungeon._180_notice, 15),d.notice)
notice_multiline(gameforge.flame_dungeon._170_notice,d.notice)
server_timer('flame_dungeon_5m_left_timer', 10*60, get_server_timer_arg())
end
end
when flame_dungeon_5m_left_timer.server_timer begin
if d.select(get_server_timer_arg()) then
notice_multiline(string.format(gameforge.flame_dungeon._180_notice, 5),d.notice)
notice_multiline(gameforge.flame_dungeon._170_notice,d.notice)
server_timer('flame_dungeon_1m_left_timer', 4*60, get_server_timer_arg())
end
end
when flame_dungeon_1m_left_timer.server_timer begin
if d.select(get_server_timer_arg()) then
notice_multiline(string.format(gameforge.flame_dungeon._180_notice, 1),d.notice)
notice_multiline(gameforge.flame_dungeon._170_notice,d.notice)
server_timer ("flame_dungeon_0m_left_timer", 60, get_server_timer_arg())
end
end
when flame_dungeon_0m_left_timer.server_timer begin
local setting = flame_dungeon.setting()
if d.select(get_server_timer_arg()) then
notice_multiline(gameforge.flame_dungeon._190_notice,d.notice)
notice_multiline(gameforge.flame_dungeon._200_notice,d.notice)
server_timer("dungeon_end_timer",10,d.get_map_index())
end
end
-- <<<< <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>>>>> --
when 20385.chat.gameforge.flame_dungeon._210_npcChat with npc.lock() begin -- '0x'<27><> x<><78>° <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>Ʈ <20><><EFBFBD><EFBFBD> <20><> <20>ִ<EFBFBD> <20><><EFBFBD><EFBFBD> , '1x'<27><> x<><78>° <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>Ʈ <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
local setting = flame_dungeon.setting()
if d.getf("started") == 0 then
say(gameforge.flame_dungeon._230_say)
say(gameforge.flame_dungeon._240_say)
wait()
d.setf("started",1)
-- <20><>Ƽ<EFBFBD><C6BC><EFBFBD><EFBFBD> ƨ<>ܹ<EFBFBD><DCB9>ȴµ<C8B4> <20>ڱ⸸ <20><><EFBFBD>Ƽ<EFBFBD> exit timer<65><72> <20><><EFBFBD>µǸ<C2B5> <20>ȵǴϱ<C7B4> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>Ҷ<EFBFBD><D2B6><EFBFBD> <20><>
server_timer ("flame_dungeon_45m_left_timer",15*60, d.get_map_index())
notice_multiline(gameforge.flame_dungeon._250_notice,d.notice)
notice_multiline(gameforge.flame_dungeon._170_notice,d.notice)
-- <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD>õ<EFBFBD> ó<><C3B3>
-- <20><><EFBFBD><EFBFBD> <20>Ŀ<EFBFBD> Ƽ<><C6BC><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ƨ<>ܳ<EFBFBD><DCB3><EFBFBD> <20><><EFBFBD>ؼ<EFBFBD> Ÿ<≯Ӹ<CCB8> <20>̿<EFBFBD><CCBF><EFBFBD> Ƽ<><C6BC><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>Ѵ<EFBFBD>.
local pids = {party.get_member_pids()}
local ticketGroup = {71095, 1, 71130, 1}
for i, pid in next, pids, nil do
q.begin_other_pc_block(pid)
local canPass = false
for idx=1, table.getn(ticketGroup),2 do
if pc.count_item(ticketGroup[idx]) >= ticketGroup[idx+1] then
canPass = true
pc.remove_item(ticketGroup[idx], ticketGroup[idx+1])
break
end
end
if not canPass then
pc.warp(setting.outside_entry_pos[1]*100, setting.outside_entry_pos[2] * 100, 62)
end
q.end_other_pc_block()
end
d.setqf2("flame_dungeon","ticket_delete",1)
d.setf("dungeon_enter",1)
-- <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><>Ƽ<EFBFBD><C6BC> <20><><EFBFBD>ο<EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>Ѵ<EFBFBD>.
party.setf("dungeon_index", d.get_map_index())
d.setf("party_leader_pid", party.get_leader_pid())
end
if d.getf("level") < 7 then --<2D><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>ƴϸ<C6B4>
if d.getf("clear_count") == 6 then -- <20><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
d.setf("level",7)
else
local rand = number(1,6)--<2D><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>湮üũ<C3BC><C5A9> <20><><EFBFBD><EFBFBD> <20><EFBFBD><E8BFAD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>ִ<EFBFBD><D6B4><EFBFBD><EFBFBD><EFBFBD> üũ<C3BC><C5A9>
local setlev = 0
d.setf("level",7) -- Ȥ<><C8A4> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>ص<EFBFBD>
for i=1,50 do
setlev = setlev + 1
if setlev > 6 then
setlev = 1
end
if not d.is_unique_dead("door"..setlev) then
rand = rand - 1
if rand == 0 then
d.setf("level",setlev)
d.setf("clear_count",d.getf("clear_count")+1)
break
end
end
end
end
end
if d.getf("level") == 1 then
say(gameforge.flame_dungeon._260_say)
notice_multiline(gameforge.flame_dungeon._260_say,d.notice)
d.kill_unique("door1")
d.kill_unique("idoor1")
d.setf("level",11)
d.regen_file ("data/dungeon/flame_dungeon/".."fd_a.txt")
server_timer ("killed_A_1", 12, d.get_map_index())
elseif d.getf("level") == 11 then
say(gameforge.flame_dungeon._270_say)
say_title(gameforge.flame_dungeon._280_sayTitle .. d.count_monster())
elseif d.getf("level") == 2 then
say(gameforge.flame_dungeon._290_say)
say(gameforge.flame_dungeon._300_say)
notice_multiline(gameforge.flame_dungeon._290_say,d.notice)
notice_multiline(gameforge.flame_dungeon._300_say,d.notice)
d.spawn_mob(20386, setting.LEVEL2_STONE_pos[1], setting.LEVEL2_STONE_pos[2]) -- <20><><EFBFBD>μ<EFBFBD> <20><>ȯ
d.kill_unique("door2")
d.kill_unique("idoor2")
d.set_regen_file ("data/dungeon/flame_dungeon/".."fd_b.txt")
d.setf("level",12)
elseif d.getf("level") == 12 then
say(gameforge.flame_dungeon._310_say)
elseif d.getf("level") == 3 then
say(gameforge.flame_dungeon._260_say)
notice_multiline(gameforge.flame_dungeon._260_say,d.notice)
d.kill_unique("door3")
d.kill_unique("idoor3")
d.setf("level",13)
d.regen_file ("data/dungeon/flame_dungeon/".."fd_c.txt")
server_timer ("killed_A_1", 12, d.get_map_index())
elseif d.getf("level") == 13 then
say(gameforge.flame_dungeon._270_say)
say_title(gameforge.flame_dungeon._280_sayTitle..d.count_monster())
elseif d.getf("level") == 4 then -- 474 178
say(gameforge.flame_dungeon._320_notice)
notice_multiline(gameforge.flame_dungeon._320_notice,d.notice)
d.setf("level",14)
d.kill_unique("door4")
d.kill_unique("idoor4")
d.set_regen_file ("data/dungeon/flame_dungeon/".."fd_d.txt")
d.spawn_mob(6051,setting.LEVEL4_TARGET_pos[1],setting.LEVEL4_TARGET_pos[2] ) -- Ÿ<>ٸ<EFBFBD><D9B8><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
elseif d.getf("level") == 14 then
say(gameforge.flame_dungeon._330_say)
say(gameforge.flame_dungeon._340_say)
elseif d.getf("level") == 5 then -- 510 355
say(gameforge.flame_dungeon._350_say)
say(gameforge.flame_dungeon._360_say)
notice_multiline(gameforge.flame_dungeon._350_say,d.notice)
notice_multiline(gameforge.flame_dungeon._360_say,d.notice)
d.kill_unique("door5")
d.kill_unique("idoor5")
d.setf("level",15)
d.set_regen_file ("data/dungeon/flame_dungeon/".."fd_e.txt")
local vis = { 0,0,0,0,0,0,0}
for i=1,7 do
vis[i] = 0
end
for i = 1, 7 do -- <20><><EFBFBD><EFBFBD><EFBFBD>ϰ<EFBFBD> <20><><EFBFBD><EFBFBD>ȯ
local ran = number(1,7)
local st = 0
for j = 1, 50 do
st = st + 1
if st > 7 then
st = 1
end
if vis[st] == 0 then
ran = ran - 1
if ran == 0 then
vis[st] = 1
d.set_unique("stone5_"..st, d.spawn_mob(20386, setting.LEVEL5_STONE_pos[i][1], setting.LEVEL5_STONE_pos[i][2]))
break
end
end
end
end
elseif d.getf("level") == 15 then
say(gameforge.flame_dungeon._370_say)
elseif d.getf("level") == 6 then -- 507 490
say(gameforge.flame_dungeon._380_say)
notice_multiline(gameforge.flame_dungeon._380_say,d.notice)
d.setf("level",16)
d.kill_unique("door6")
d.kill_unique("idoor6")
d.set_regen_file ("data/dungeon/flame_dungeon/".."fd_f.txt")
d.spawn_mob(8057, setting.LEVEL6_TARGET_pos[1],setting.LEVEL6_TARGET_pos[2]) -- Ÿ<>ٿ<EFBFBD><D9BF><EFBFBD><EFBFBD><EFBFBD>Ʈ <20><>ȯ
elseif d.getf("level") == 16 then
say(gameforge.flame_dungeon._390_say)
say(gameforge.flame_dungeon._400_say)
elseif d.getf("level") == 7 then
-- setskin(NOWINDOW)
flame_dungeon.go_boss()
else
say(gameforge.flame_dungeon._410_say)
end
npc.unlock()
end
when dungeon_end_timer.server_timer begin -- <20><><EFBFBD><EFBFBD> Ÿ<≯<EFBFBD> (<28><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>°<EFBFBD>)
local setting = flame_dungeon.setting()
if d.select(get_server_timer_arg()) then
flame_dungeon.clear_timer(d.get_map_index())
d.set_warp_location(62, setting.outside_entry_pos[1] , setting.outside_entry_pos[2])
d.exit_all()
d.setf("party_leader_pid", 0)
end
end
when killed_A_1.server_timer begin -- Ÿ<≯<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>1 (level1,level3)
if d.select(get_server_timer_arg()) then
if d.count_monster() <= 0 then -- 1<><31><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
if d.getf("level") == 11 then
notice_multiline(gameforge.flame_dungeon._420_notice,d.notice)
notice_multiline(gameforge.flame_dungeon._430_notice,d.notice)
else
notice_multiline(gameforge.flame_dungeon._420_notice,d.notice)
notice_multiline(gameforge.flame_dungeon._430_notice,d.notice)
end
d.setf("level",0)
else
server_timer ("killed_A_1", 6, get_server_timer_arg())
end
end
end
when killed_A_2.server_timer begin -- Ÿ<≯<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>2 (1<><31> 2 <20><><EFBFBD><EFBFBD><EFBFBD>ư<EFBFBD><C6B0><20><><EFBFBD>ư<EFBFBD>)
if d.select(get_server_timer_arg()) then
if d.count_monster() <= 0 then -- 1<><31><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
if d.getf("level") == 11 then
notice_multiline(gameforge.flame_dungeon._420_notice,d.notice)
notice_multiline(gameforge.flame_dungeon._430_notice,d.notice)
else
notice_multiline(gameforge.flame_dungeon._420_notice,d.notice)
notice_multiline(gameforge.flame_dungeon._430_notice,d.notice)
end
d.setf("level",0)
else
server_timer ("killed_A_2", 6, get_server_timer_arg())
end
end
end
when kill with flame_dungeon.is_flamed(pc.get_map_index()) and d.getf("level") == 12 begin -- 2<><32><EFBFBD><EFBFBD> <20><><EFBFBD>μ<EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
local i = number(1, 100) -- 100<30><30><EFBFBD><EFBFBD> 1 Ȯ<><C8AE><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
if i == 1 then
game.drop_item (30329, 1)
end
end
when 20386.take with flame_dungeon.is_flamed(pc.get_map_index()) and item.vnum == 30329 and d.getf("level") == 12 begin -- 2<><32><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20>Ծ<EFBFBD><D4BE><EFBFBD><EFBFBD><EFBFBD>
local i = number(1, 5) -- 5<><35><EFBFBD><EFBFBD> 1 Ȯ<><C8AE><EFBFBD><EFBFBD> <20><>¥ <20><><EFBFBD><EFBFBD>
if i == 1 then
npc.purge()
item.remove()
notice_multiline(gameforge.flame_dungeon._440_notice,d.notice)
notice_multiline(gameforge.flame_dungeon._430_notice,d.notice)
flame_dungeon.level_clear()
else
item.remove()
say(gameforge.flame_dungeon._450_say)
end
end
when 6051.kill with flame_dungeon.is_flamed(pc.get_map_index()) and d.getf("level") == 14 begin
notice_multiline(gameforge.flame_dungeon._460_notice,d.notice)
notice_multiline(gameforge.flame_dungeon._430_notice,d.notice)
flame_dungeon.level_clear()
end
when kill with flame_dungeon.is_flamed(pc.get_map_index()) and d.getf("level") == 15 begin -- 5<><35><EFBFBD><EFBFBD> <20><><EFBFBD>μ<EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
local i = number(1, 30) -- 30<33><30><EFBFBD><EFBFBD> 1 Ȯ<><C8AE><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
if i == 1 then
game.drop_item (30330, 1)
end
end
when 20386.take with flame_dungeon.is_flamed(d.get_map_index()) and item.vnum == 30330 and d.getf("level") == 15 begin -- 5<><35><EFBFBD><EFBFBD> <20><>¥<EFBFBD><C2A5><EFBFBD><EFBFBD> <20>Ծ<EFBFBD><D4BE><EFBFBD><EFBFBD><EFBFBD>
local setting = flame_dungeon.setting()
if npc.get_vid() == d.get_unique_vid("stone5_1") then -- ù<><C3B9>° <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>Ǿ<EFBFBD><C7BE><EFBFBD> <20><> <20><><EFBFBD><EFBFBD> <20>ʿ<EFBFBD><CABF><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ã<>ڸ<EFBFBD><DAB8><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
npc.purge()
item.remove()
say(gameforge.flame_dungeon._470_say)
d.setf("stonekill",2) -- 2<><32> <20><><EFBFBD><EFBFBD> <20>׿<EFBFBD><D7BF><EFBFBD>
if d.count_monster() < 100 then
d.regen_file ("data/dungeon/flame_dungeon/".."fd_e.txt")
end
elseif npc.get_vid() == d.get_unique_vid("stone5_2") then
if d.getf("stonekill") == 2 then -- 2<><32><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD>˵<EFBFBD> 2<><32><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><20>Կ<EFBFBD><D4BF><EFBFBD> <20><>
npc.purge()
item.remove()
say(gameforge.flame_dungeon._480_say)
d.setf("stonekill",3)
if d.count_monster() < 100 then
d.regen_file ("data/dungeon/flame_dungeon/".."fd_e.txt")
end
else
item.remove()
say(gameforge.flame_dungeon._490_say)
-- say("2<><32>")
end
elseif npc.get_vid() == d.get_unique_vid("stone5_3") then
if d.getf("stonekill") == 3 then
npc.purge()
item.remove()
say(gameforge.flame_dungeon._500_say)
d.setf("stonekill",4)
if d.count_monster() < 100 then
d.regen_file ("data/dungeon/flame_dungeon/".."fd_e.txt")
end
else
item.remove()
say(gameforge.flame_dungeon._490_say)
-- say("3<><33>")
end
elseif npc.get_vid() == d.get_unique_vid("stone5_4") then
if d.getf("stonekill") == 4 then
npc.purge()
item.remove()
say(gameforge.flame_dungeon._510_say)
d.setf("stonekill",5)
if d.count_monster() < 100 then
d.regen_file ("data/dungeon/flame_dungeon/".."fd_e.txt")
end
else
item.remove()
say(gameforge.flame_dungeon._490_say)
-- say("4<><34>")
end
elseif npc.get_vid() == d.get_unique_vid("stone5_5") then
if d.getf("stonekill") == 5 then
npc.purge()
item.remove()
say(gameforge.flame_dungeon._520_say)
d.setf("stonekill",6)
if d.count_monster() < 100 then
d.regen_file ("data/dungeon/flame_dungeon/".."fd_e.txt")
end
else
item.remove()
say(gameforge.flame_dungeon._490_say)
-- say("5<><35>")
end
elseif npc.get_vid() == d.get_unique_vid("stone5_6") then
if d.getf("stonekill") == 6 then
npc.purge()
item.remove()
say(gameforge.flame_dungeon._530_say)
d.setf("stonekill",7)
if d.count_monster() < 100 then
d.regen_file ("data/dungeon/flame_dungeon/".."fd_e.txt")
end
else
item.remove()
say(gameforge.flame_dungeon._490_say)
-- say("6<><36>")
end
else
if d.getf("stonekill") == 7 then
npc.purge()
item.remove()
notice_multiline(gameforge.flame_dungeon._440_notice,d.notice)
notice_multiline(gameforge.flame_dungeon._430_notice,d.notice)
flame_dungeon.level_clear()
else
item.remove()
say(gameforge.flame_dungeon._490_say)
-- say("7<><37>")
end
end
end
when 8057.kill with flame_dungeon.is_flamed(d.get_map_index()) and d.getf("level") ==16 begin -- <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>ı<EFBFBD><C4B1><EFBFBD><EFBFBD><EFBFBD> <20><>
notice_multiline(gameforge.flame_dungeon._540_notice,d.notice)
notice_multiline(gameforge.flame_dungeon._430_notice,d.notice)
flame_dungeon.level_clear()
end
when 6091.kill with flame_dungeon.is_flamed(d.get_map_index()) and d.getf("level") ==17 begin -- <20><><EFBFBD><EFBFBD> <20>׿<EFBFBD><D7BF><EFBFBD><EFBFBD><EFBFBD>
notice_multiline(gameforge.flame_dungeon._550_notice,d.notice)
notice_multiline(gameforge.flame_dungeon._560_notice,d.notice)
server_timer("dungeon_end_timer", 60,d.get_map_index())
flame_dungeon.level_clear()
-- <20><>Ƽ<EFBFBD><C6BC> <20><>, <20>߸<EFBFBD>õ <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>Ʈ(104<30><34>, 105<30><35> <20><><EFBFBD><EFBFBD>Ʈ) <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>Ʈ Ŭ<><C5AC><EFBFBD><EFBFBD> <20>ǵ<EFBFBD><C7B5><EFBFBD>.
if party.is_party() then
party.setf("flame_dungeon_boss_kill_count", 1)
end
end
end
end