function get_module_name () return "roaming_harris" end function roaming_special_npc () local name = get_value ("name") dlg_title ("Wanderer Harris") dlg_text ("hello" ..name .. ", are you sure you want to try your luck with me ?!") dlg_menu ("What are you trying?!", "selected_question ()") dlg_menu ("An attempt is worth", "selected_yes ()") dlg_menu ("I do not think so ..", "selected_no ()") dlg_show () end function selected_question () local name = get_value ("name") whisper (gv ("name"), "You can win a very special gift from Harris, but you can also experience your worst nightmare. The choice is yours ...") end function selected_yes () local name = get_value ("name") local random = math.random (1,5) if gv ("level")> 120 then local flag = tonumber (get_flag ("harris_wanderer")) if flag == nil then flag = 0 set_flag ("harris_wanderer", "0") end if flag + 10800 You got" .. number .. "x # @ id @ # from Harris", "# @ id @ #", id) whisper (gv ( "name"), text) end good_item = {920006,2010696,2010900,910077,910078,910079,2011573,2011571,2011572,2011573,305794,427209,437109, 2,011,308.710004} function schenke_gutes_item () local num = math.random (1,15) local number = math.random (1.5) local ss_id = good_item [num] local id = get_item_name_by_code (ss_id) insert_item (ss_id, number) text = sconv ("<# D95310> You got" .. number .. "x # @ id @ # from Harris", "# @ id @ #", id) whisper (gv ( "name"), text) end debuff_add = {201051,6003,201055,201054,5003,5004,5005,5006,5010,5011,5014,5102,201005,5997,320005} function give_debuff () local num = math.random (1,15) local level = math.random (1,20) local time = math.random (20000,720000) local ss_id = debuff_add [num] local id = get_item_name_by_code (ss_id) add_state (ss_id, level, time) text = sconv ("<# D95310> You have a level" ..level .. "Receive debuff from Harris") whisper (gv ( "name"), text) end buff_add = {1302,1003,1005,1007,1009,1011,1012,1501,1502,1503,1504,1505,1506,1507,320006,13210} function schenke_guten_buff () local num = math.random (1,14) local level = math.random (1,20) local time = math.random (20000,360000) local ss_id = buff_add [num] local state_name = get_item_name_by_code (ss_id) add_state (ss_id, level, time) text = sconv ("<# D95310> You have a level" ..level .. "Get buff from Harris") whisper (gv ( "name"), text) end function safer_tod () local name = get_value ("name") warp (184476.138539) add_state (6006,1,6000) add_state (145409,25,12000) add_npc (184476,138539,185001,10) announce ("Congratulations" ..name .. ", you have just been sent to certain death ...") end