-- Lua ½ºÅ©¸³Æ® ¾Ïȣȭ function get_module_name() return "on_player_level_up" end function on_player_level_up() --local tx, ty, current_x, island_number local lv = get_value( "level" ) local max_reached_level = gv( "max_reached_level" ) local state_code = get_local_info() --=========================================================================================150 ·¹º§ ÀÌÇÏ ·¹º§ ´Þ¼º º¸»ó local i --function for i = max_reached_level + 1 , lv do if i == 20 then -- Carte Pet Commun (orc etc) give_on_level_up_pet( 0 , 1 , 5 ) --add_item( 900010, 5 ) -- 900010 Economiseur d'Energie (non-A¨Ïchangeable) --add_item( 900018, 5 ) -- Potion Mira add_item(2010454, 5 ) -- EB private_notice( sconv( "@690000140" , "#@index_lv@#", i ) ) elseif i == 50 then give_on_level_up_pet( 0 , 1 , 5 ) add_item(2010454, 5 ) -- EB add_item(2902160, 5 ) -- 2902160 Fiole de Bonheur private_notice( sconv( "@690000140" , "#@index_lv@#", i ) ) elseif i == 100 then give_on_level_up_pet( 0 , 1 , 10 ) private_notice( sconv( "@690000140" , "#@index_lv@#", i ) ) elseif i == 150 then give_on_level_up_pet( 0 , 2 , 5 ) give_on_level_up_pet( 1 , 3 , 1 ) give_on_level_up_pet( 1 , 3 , 1 ) give_on_level_up_pet( 1 , 3 , 1 ) give_on_level_up_pet( 1 , 3 , 1 ) give_on_level_up_pet( 1 , 3 , 1 ) add_item( 900010, 5 ) -- 900010 Economiseur d'Energie (non-A¨Ïchangeable) add_item( 900018, 5 ) -- Potion Mira add_item(2010454, 5 ) -- EB add_item(2902160, 5 ) -- 2902160 Fiole de Bonheur add_item(800000000 , 2 ) -- box conso add_item(800000001 , 2 ) -- box enchant private_notice( sconv( "@690000140" , "#@index_lv@#", i ) ) end end if lv == 5 then -- °¢ 1¹ø ¼¶ÀÇ ÅÚ·¹Æ÷Æ® ÁÂÇ¥ -- tx = 30315 -- ty = 5480 if (gv('rx') == nil or gv('rx') == "") and (gv('ry') == nil or gv('ry') == "") then -- ÇØ¿Ü current_x = get_flag( "rx" ) else -- ±¹³» current_x = gv( "rx" ) end if (gv('rx') == nil or gv('rx') == "") and (gv('ry') == nil or gv('ry') == "") then -- ÇØ¿Ü set_flag( "rx", 172543 + math.random(0,100)) set_flag( "ry", 51847 + math.random(0,100)) else -- ±¹³» sv( "rx", 172543 + math.random(0,100)) sv( "ry", 51847 + math.random(0,100)) end end -- ±¹°¡ ÄÚµå Àоî¿À±â -- get_local_info()ÀÇ ¹Ýȯ°ªµé --LOCAL_INFO_KOREA = 1 --LOCAL_INFO_HONGKONG = 2 --LOCAL_INFO_AMERICA = 4 --LOCAL_INFO_GERMANY = 8 --LOCAL_INFO_JAPAN = 16 --LOCAL_INFO_TAIWAN = 32 --LOCAL_INFO_CHINA = 64 --LOCAL_INFO_FRANCE = 128 --LOCAL_INFO_RUSSIA = 256 local state_code = get_local_info() -- 18·¹º§ ÀÌ»óÀ̳ª ¼ö·ÃÀÚÀÇ ¼¶ ³»¿¡ ÀÖ´Â °æ¿ì Á¾Á· ¸¶À»·Î ±Íȯ ÁöÁ¡ ¼³Á¤ local current_x = gv("x") local current_y = gv("y") local race = get_value( "race" ) -- ¹Ì±¹ÀÌ¸é ¹«Á¶°Ç ¾Èº¸³¿ (Àü ±¹°¡ Àû¿ë ¾ÈÇÔÀ¸·Î º¯°æ 08.07.29) if state_code == 511 then -- ¾Æ¹«Áþµµ ¾ÈÇØ¿ä elseif lv >= 180 then -- ¼ö·ÃÀÚÀÇ ¼¶¿¡ ÀÖ´ÂÁö ¿©ºÎ üũ if current_x >= 161280 and current_x <= 177408 then if current_y >= 48384 and current_y <= 64512 then local return_x local return_y -- ÇöÀç±Íȯ À§Ä¡¸¦ °¡Á®¿È. if (gv('rx') == nil or gv('rx') == "") and (gv('ry') == nil or gv('ry') == "") then -- ÇØ¿Ü return_x = get_flag( "rx" ) return_y = get_flag( "ry" ) else -- ±¹³» return_x = gv( "rx" ) return_y = gv( "ry" ) end -- ¼ö·ÃÀÚÀÇ ¼¶ÀÌ ±ÍȯÀÎÁö üũ if return_x == 173183 and return_y == 52299 then -- ±ÍȯÁö¿ªÀ» ÇØ´ç Á¾Á· ¸¶À»·Î ¼³Á¤ -- µ¥¹ÙÀÏ °æ¿ì if race == 4 then if (gv('rx') == nil or gv('rx') == "") and (gv('ry') == nil or gv('ry') == "") then -- ÇØ¿Ü set_flag( "rx", 6625 + math.random(0,100)) set_flag( "ry", 6980 + math.random(0,100)) else -- ±¹³» sv( "rx", 6625 + math.random(0,100)) sv( "ry", 6980 + math.random(0,100)) end -- ¾Æ¼ö¶óÀÏ °æ¿ì elseif race == 5 then if (gv('rx') == nil or gv('rx') == "") and (gv('ry') == nil or gv('ry') == "") then -- ÇØ¿Ü set_flag( "rx", 116799 + math.random(0,100)) set_flag( "ry", 58205 + math.random(0,100)) else -- ±¹³» sv( "rx", 116799 + math.random(0,100)) sv( "ry", 58205 + math.random(0,100)) end -- °¡À̾ÆÀÏ °æ¿ì else if (gv('rx') == nil or gv('rx') == "") and (gv('ry') == nil or gv('ry') == "") then -- ÇØ¿Ü set_flag( "rx", 153513 + math.random(0,100)) set_flag( "ry", 77203 + math.random(0,100)) else -- ±¹³» set_flag( "rx", 153513 + math.random(0,100)) set_flag( "ry", 77203 + math.random(0,100)) end end -- if race == 4 then -- ¼ö·ÃÀÚÀÇ ¼¶¿¡ ÀÖ°í 18·¹º§ ÀÌ»óÀ̱⠶§¹®¿¡ ÇØ´ç Á¾Á· ¸¶À»·Î °­Á¦ ±Íȯ ¼³Á¤ µÆ´Ù´Â ¸Þ½ÃÁö ³¯¸². message( "@235") end -- if return_x == 173183 and return_y == 52299 end -- if current_y >= 48384 and current_y <= 64512 then end -- if current_x >= 161280 and current_x <= 177408 then end -- if lv >= 18 then kick_auto_to_another_world() local current_x = gv("x") local current_y = gv("y") local race = get_value( "race" ) if current_x >= 161280 and current_x <= 177408 then if current_y >= 48384 and current_y <= 64512 then local is_auto, quest_count quest_count, is_auto = anti_auto_quest_check() if is_auto then if race == 4 then RunTeleport_Auto_TO_City( 6625 , 6980 ) elseif race == 5 then RunTeleport_Auto_TO_City( 116799 , 58205 ) else RunTeleport_Auto_TO_City( 153506 , 77175 ) end end -- if is_auto then end -- if current_y >= 48384 and current_y <= 64512 then end -- if current_x >= 161280 and current_x <= 177408 then on_player_level_joblevel_guide() if lv > max_reached_level then update_title_condition( 9002001, lv ) end end function on_player_level_joblevel_guide() --ÀÛ¾÷Áß local lv = get_value( "level" ) local job_lv = get_value( "job_level" ) local job_dp = get_value( "job_depth" ) if job_dp == 0 and lv >= 10 and job_lv >= 10 then cprint( "@1200" ) --cprint( "@254" ) cprint( "@1201" ) elseif lv == 20 then cprint( "@1202" ) cprint( "@1203" ) -- add_npc(172578, 51937, 600, 5) elseif lv == 50 then cprint( "@1204" ) cprint( "@1205" ) elseif job_dp== 1 and lv >= 50 and job_lv >= 40 then cprint( "@1206" ) cprint( "@1207" ) cprint( "@1208" ) elseif lv == 80 then cprint( "@1209" ) cprint( "@1210" ) elseif lv == 100 then cprint( "@1211" ) cprint( "@1212" ) end end function give_on_level_up_pet( isrdm , rarity , count ) pet={} pet[1]={540002 , 540005 , 540006 , 540011 , 540018 , 540053 , 540057 , 540079,540019} pet[2]={540009 , 540012 , 540052 , 540067 , 540065} pet[3]={540013 , 540059 , 540055 , 540010} pet[4]={540061 , 540036 , 540063 , 540076} pet[5]={540037 , 540069} if isrdm == 0 then for i = 1 , table.getn(pet[rarity]) do add_item(pet[rarity][i] , count ) end else add_item(pet[rarity][math.random(1,table.getn(pet[rarity] ))] , count ) end end