211 lines
30 KiB
Lua
211 lines
30 KiB
Lua
|
|
function fast_equip_selling_rank_type()
|
|
|
|
local array
|
|
local gold = gv("gold")
|
|
array = {323701,102101,103100,103101,103102,103103,104101,104102,104103,105101,105102,106100,106101,106102,107101,108101,109101,111101,111102,112100,112101,301101,301102,101102,101101,101100,220100,220101,220102,220109,230100,230101,230102,230103,230109,240100,240101,240102,240109,250001,250002,250003,250004,250005,250006,250007,250008,250009,302101,302102,302103,302229,303101,303102,304101,304102,3000049,3000062,3000075,3000092,3000096,101201,101202,101203,101204,101221,101222,101223,101224,102201,102202,102203,102221,102222,102223,103201,103202,103203,103221,103222,103223,104201,104202,104203,104221,104222,104223,105201,105202,105203,105221,105222,105223,106201,106202,106203,106221,106222,106223,107201,107202,107221,107222,108201,108202,108203,108221,108222,109201,109221,110201,110202,110221,110222,111201,111202,111203,111221,111222,111223,112201,112221,301201,301202,2000021,2000022,221201,305201,221202,221203,221204,222201,222202,222203,223201,223202,223203,223204,224201,224202,224203,224204,231201,231202,232201,232202,233201,233202,234201,234202,241201,241202,242201,243201,243202,244201,244202,302201,302205,302206,302207,302209,302211,303201,303202,303203,304201,304202,304203,412100,412201,412202,422101,422102,422103,422104,422201,422202,422203,422204,422205,422206,422207,422208,422601,422602,422603,422604,432101,432102,432103,432104,432105,432106,432107,432108,432109,432110,432201,432202,432203,432204,432205,432206,432207,432208,432209,432210,432601,432602,432603,432604,432605,432606,432607,432608,432609,432610,432611,101301,101302,101303,101321,101322,101323,102301,102302,102321,102322,103301,103302,103321,103322,104301,104302,104303,104321,104322,104323,105301,105302,105303,105321,105322,105323,106301,106302,106303,106321,106322,106323,107301,107302,107303,107321,107322,107323,108301,108302,108303,108304,108321,108322,108323,108324,109301,109302,109321,109322,110301,110302,110321,110322,111301,111302,111303,111321,111322,111323,112301,112321,301301,301302,301303 ,221301,305301,221302,222301,222302,223301,223302,224301,224302,231301,231302,232301,232302,233301,233302,234301,234302,241301,241302,242301,242302,243301,243302,244301,244302,261303,262303,263303,264303,302301,302302,302307,303301,303302,303303,303304,304301,304302,304303,304304,413100,413201,413202,423101,423102,423103,423104,423201,423202,423203,423204,423205,423206,423207,423208,423601,423602,423603,423604,433101,433102,433103,433104,433105,433106,433107,433108,433109,433110,433201,433202,433203,433204,433205,433206,433207,433208,433209,433210,433601,433602,433603,433604,433605,433606,433607,433608,433609,433610,101401,101402,101403,101404,101421,101422,101423,102401,102402,102403,102404,102421,102422,102423,102424,103401,103402,103403,103421,103422,103423,104401,104402,104403,104421,104422,104423,105401,105402,105421,105422,106401,106402,106403,106421,106422,106423,107401,107402,107421,107422,108401,108402,108421,108422,109401,109402,109421,109422,110401,110402,110403,110421,110422,110423,111401,111402,111421,111422,112401,112402,112403,112421,112422,112423,301401,301402,221401,305401,222401,223401,224401,231401,232401,233401,234401,241401,242401,243401,244401,261402,262402,263402,264402,302401,302402,302407,303401,303402,303403,304401,304402,304403,414100,414201,414202,424101,424102,424103,424104,424201,424202,424203,424204,424205,424206,424207,424208,424601,424602,424603,424604,434101,434102,434103,434104,434105,434106,434107,434108,434109,434110,434201,434202,434203,434204,434205,434206,434207,434208,434209,434210,434601,434602,434603,434604,434605,434606,434607,434608,434609,434610,101501,101502,101503,101521,101522,101523,101524,102501,102502,102521,102522,102523,103501,103502,103521,103522,103523,104501,104502,104503,104521,104522,104523,104524,105501,105502,105521,105522,105523,106501,106521,106522,107501,107502,107503,107521,107522,107523,107524,108501,108502,108521,108522,108523,109501,109502,109521,109522,109523,110501,110502,110521,110522,110523,111501,111521,111522,111523,112501,112502,112521,112522,112523,301501,301502,301503,221501,302501,305501,222501,223501,224501,231501,232501,233501,234501,261501,261502,262501,262502,263501,263502,264501,264502,302502,303501,304501 ,415100,415101,415102,425001,425002,425003,425004,425201,425202,425203,425204,425205,425206,425207,425208,435001,435002,435003,435004,435005,435006,435007,101601,101602,101603,101621,101622,101623,101624,102601,102602,102621,102622,102623,103601,103602,103621,103622,103623,104601,104602,104621,104622,104623,105601,105602,105621,105622,105623,106601,106602,106621,106622,106623,107601,107602,107621,107622,107623,108601,108602,108621,108622,108623,109601,109602,109621,109622,109623,110601,110602,110621,110622,110623,111601,111602,111621,111622,111623,111624,112601,112602,112621,112622,112623,301601,301602,301603,221601,305601,222601,223601,224601,231601,232601,233601,234601,261601,262601,263601,264601,274727,302601,303601,304601,416100,416101,416102,426001,426002,426003,426004,426201,426202,426203,426204,426205,426206,426207,426208,436001,436002,436003,436004,436005,436006,436007,101701,101702,101703,101705,101721,101722,101723,101724,102701,102702,102703,102705,102721,102722,102723,102724,103701,103702,103703,103705,103721,103722,103723,103724,3100009,104701,104702,104703,104705,104721,104722,104723,104724,105701,105702,105703,105705,105721,105722,105723,105724,106701,106702,106703,106705,106721,106722,106723,106724,107701,107702,107703,107705,107721,107722,107723,107724,108701,108702,108703,108705,108721,108722,108723,108724,3100005,109701,109702,109703,109705,109721,109722,109723,109724,110701,110702,110703,110705,110721,110722,110723,110724,111701,111702,111703,111706,111721,111722,111723,111724,111725,112701,112702,112703,112705,112721,112722,112723,112724,301702,301703,301704,301705,301706,301707,301708,301709,301710,261701,305701,305702,305703,262701,263701,264701,271701,271702,271703,271704,272701,272702,272703,272704,273701,273702,273703,273704,274701,274702,274703,274704,302749,302750,302751,302752,303701,303702,303703,303704,304701,304702,304703,304704,417100,417101,417102,417201,427001,427002,427003,427004,427201,427202,427203,427204,427205,427206,427207,427208,427209,427210,427301,437001,437002,437003,437004,437005,437006,437007,437103,437104,437109,437110,437201,437202,313705,313706,313707,313708,313725,313726,313727,313728,314705,314706,314707,314708,314725,314726,314727,314728,313701,313702,313703,313704,313721,313722,313723,313724,314701,314702,314703,314704,314721,314722,314723,314724,303701,303702,303703,303704,303721,303722,303723,303724,304701,304702,304703,304704,304721,304722,304723,304724}
|
|
|
|
|
|
local found = false
|
|
|
|
for i = 1, table.getn(array) do
|
|
|
|
if find_item(array[i]) >= 1 then
|
|
found = true
|
|
selling_test(array[i])
|
|
end
|
|
|
|
end
|
|
|
|
if found == true then
|
|
-- fast_equip_selling_rank()
|
|
end
|
|
|
|
local gold2 = gv("gold")
|
|
|
|
if gold2 - gold > 0 then
|
|
|
|
private_notice("Total : " .. format_num((gold2 - gold),0) .."R")
|
|
|
|
end
|
|
|
|
|
|
end
|
|
|
|
function selling_test(id)
|
|
|
|
if find_item(id) >= 1 then
|
|
local handle_array = get_item_handle_list(id)
|
|
|
|
for i = 1, table.getn(handle_array) do
|
|
|
|
local handle = handle_array[i]
|
|
local basic_price = get_item_price( handle ) / 4
|
|
local level = get_item_level(handle)
|
|
local enhance = get_item_enhance(handle)
|
|
|
|
if is_erasable_item(handle) == 1 and level == 1 and enhance == 0 then
|
|
remove_item(handle,1)
|
|
sv("gold",gv("gold")+basic_price)
|
|
end
|
|
|
|
end
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
function fast_equip_donate_rank_type()
|
|
|
|
local array
|
|
local immo = gv("immoral") * -1
|
|
|
|
|
|
array = {323701,102101,103100,103101,103102,103103,104101,104102,104103,105101,105102,106100,106101,106102,107101,108101,109101,111101,111102,112100,112101,301101,301102,101102,101101,101100,220100,220101,220102,220109,230100,230101,230102,230103,230109,240100,240101,240102,240109,250001,250002,250003,250004,250005,250006,250007,250008,250009,302101,302102,302103,302229,303101,303102,304101,304102,3000049,3000062,3000075,3000092,3000096,101201,101202,101203,101204,101221,101222,101223,101224,102201,102202,102203,102221,102222,102223,103201,103202,103203,103221,103222,103223,104201,104202,104203,104221,104222,104223,105201,105202,105203,105221,105222,105223,106201,106202,106203,106221,106222,106223,107201,107202,107221,107222,108201,108202,108203,108221,108222,109201,109221,110201,110202,110221,110222,111201,111202,111203,111221,111222,111223,112201,112221,301201,301202,2000021,2000022,221201,305201,221202,221203,221204,222201,222202,222203,223201,223202,223203,223204,224201,224202,224203,224204,231201,231202,232201,232202,233201,233202,234201,234202,241201,241202,242201,243201,243202,244201,244202,302201,302205,302206,302207,302209,302211,303201,303202,303203,304201,304202,304203,412100,412201,412202,422101,422102,422103,422104,422201,422202,422203,422204,422205,422206,422207,422208,422601,422602,422603,422604,432101,432102,432103,432104,432105,432106,432107,432108,432109,432110,432201,432202,432203,432204,432205,432206,432207,432208,432209,432210,432601,432602,432603,432604,432605,432606,432607,432608,432609,432610,432611,101301,101302,101303,101321,101322,101323,102301,102302,102321,102322,103301,103302,103321,103322,104301,104302,104303,104321,104322,104323,105301,105302,105303,105321,105322,105323,106301,106302,106303,106321,106322,106323,107301,107302,107303,107321,107322,107323,108301,108302,108303,108304,108321,108322,108323,108324,109301,109302,109321,109322,110301,110302,110321,110322,111301,111302,111303,111321,111322,111323,112301,112321,301301,301302,301303 ,221301,305301,221302,222301,222302,223301,223302,224301,224302,231301,231302,232301,232302,233301,233302,234301,234302,241301,241302,242301,242302,243301,243302,244301,244302,261303,262303,263303,264303,302301,302302,302307,303301,303302,303303,303304,304301,304302,304303,304304,413100,413201,413202,423101,423102,423103,423104,423201,423202,423203,423204,423205,423206,423207,423208,423601,423602,423603,423604,433101,433102,433103,433104,433105,433106,433107,433108,433109,433110,433201,433202,433203,433204,433205,433206,433207,433208,433209,433210,433601,433602,433603,433604,433605,433606,433607,433608,433609,433610,101401,101402,101403,101404,101421,101422,101423,102401,102402,102403,102404,102421,102422,102423,102424,103401,103402,103403,103421,103422,103423,104401,104402,104403,104421,104422,104423,105401,105402,105421,105422,106401,106402,106403,106421,106422,106423,107401,107402,107421,107422,108401,108402,108421,108422,109401,109402,109421,109422,110401,110402,110403,110421,110422,110423,111401,111402,111421,111422,112401,112402,112403,112421,112422,112423,301401,301402,221401,305401,222401,223401,224401,231401,232401,233401,234401,241401,242401,243401,244401,261402,262402,263402,264402,302401,302402,302407,303401,303402,303403,304401,304402,304403,414100,414201,414202,424101,424102,424103,424104,424201,424202,424203,424204,424205,424206,424207,424208,424601,424602,424603,424604,434101,434102,434103,434104,434105,434106,434107,434108,434109,434110,434201,434202,434203,434204,434205,434206,434207,434208,434209,434210,434601,434602,434603,434604,434605,434606,434607,434608,434609,434610,101501,101502,101503,101521,101522,101523,101524,102501,102502,102521,102522,102523,103501,103502,103521,103522,103523,104501,104502,104503,104521,104522,104523,104524,105501,105502,105521,105522,105523,106501,106521,106522,107501,107502,107503,107521,107522,107523,107524,108501,108502,108521,108522,108523,109501,109502,109521,109522,109523,110501,110502,110521,110522,110523,111501,111521,111522,111523,112501,112502,112521,112522,112523,301501,301502,301503,221501,302501,305501,222501,223501,224501,231501,232501,233501,234501,261501,261502,262501,262502,263501,263502,264501,264502,302502,303501,304501 ,415100,415101,415102,425001,425002,425003,425004,425201,425202,425203,425204,425205,425206,425207,425208,435001,435002,435003,435004,435005,435006,435007,101601,101602,101603,101621,101622,101623,101624,102601,102602,102621,102622,102623,103601,103602,103621,103622,103623,104601,104602,104621,104622,104623,105601,105602,105621,105622,105623,106601,106602,106621,106622,106623,107601,107602,107621,107622,107623,108601,108602,108621,108622,108623,109601,109602,109621,109622,109623,110601,110602,110621,110622,110623,111601,111602,111621,111622,111623,111624,112601,112602,112621,112622,112623,301601,301602,301603,221601,305601,222601,223601,224601,231601,232601,233601,234601,261601,262601,263601,264601,274727,302601,303601,304601,416100,416101,416102,426001,426002,426003,426004,426201,426202,426203,426204,426205,426206,426207,426208,436001,436002,436003,436004,436005,436006,436007,101701,101702,101703,101705,101721,101722,101723,101724,102701,102702,102703,102705,102721,102722,102723,102724,103701,103702,103703,103705,103721,103722,103723,103724,3100009,104701,104702,104703,104705,104721,104722,104723,104724,105701,105702,105703,105705,105721,105722,105723,105724,106701,106702,106703,106705,106721,106722,106723,106724,107701,107702,107703,107705,107721,107722,107723,107724,108701,108702,108703,108705,108721,108722,108723,108724,3100005,109701,109702,109703,109705,109721,109722,109723,109724,110701,110702,110703,110705,110721,110722,110723,110724,111701,111702,111703,111706,111721,111722,111723,111724,111725,112701,112702,112703,112705,112721,112722,112723,112724,301702,301703,301704,301705,301706,301707,301708,301709,301710,261701,305701,305702,305703,262701,263701,264701,271701,271702,271703,271704,272701,272702,272703,272704,273701,273702,273703,273704,274701,274702,274703,274704,302749,302750,302751,302752,303701,303702,303703,303704,304701,304702,304703,304704,417100,417101,417102,417201,427001,427002,427003,427004,427201,427202,427203,427204,427205,427206,427207,427208,427209,427210,427301,437001,437002,437003,437004,437005,437006,437007,437103,437104,437109,437110,437201,437202,313705,313706,313707,313708,313725,313726,313727,313728,314705,314706,314707,314708,314725,314726,314727,314728,313701,313702,313703,313704,313721,313722,313723,313724,314701,314702,314703,314704,314721,314722,314723,314724,303701,303702,303703,303704,303721,303722,303723,303724,304701,304702,304703,304704,304721,304722,304723,304724}
|
|
|
|
cprint("in fast_equip_donate_rank_type")
|
|
local found = false
|
|
|
|
for i = 1, table.getn(array) do
|
|
|
|
if find_item(array[i]) >= 1 then
|
|
found = true
|
|
donate_test(array[i])
|
|
end
|
|
|
|
end
|
|
|
|
if found == true then
|
|
-- fast_equip_selling_rank()
|
|
end
|
|
|
|
local immo2 = gv("immoral") *-1
|
|
|
|
if immo2 - immo > 0 then
|
|
|
|
private_notice("Total : " .. format_num((immo2 - immo),0) .. " moral_points")
|
|
|
|
end
|
|
|
|
end
|
|
|
|
function donate_test(id)
|
|
|
|
if find_item(id) >= 1 then
|
|
local handle_array = get_item_handle_list(id)
|
|
|
|
for i = 1, table.getn(handle_array) do
|
|
|
|
local handle = handle_array[i]
|
|
local basic_price = get_item_price( handle ) / 4
|
|
local level = get_item_level(handle)
|
|
local enhance = get_item_enhance(handle)
|
|
|
|
if is_erasable_item(handle) == 1 and level == 1 and enhance == 0 then
|
|
donate_item(handle,1)
|
|
end
|
|
|
|
end
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
function fast_equip_dismantle_rank_type()
|
|
|
|
local array = {2011835,2011836,2011837,2011838,2011839,2011840,2011841,2011842,2011843,2011844,2011845,2011846,2011847,2011848,2011849,2011850,2011851,2011852,2011853,2011854,2011855,2011856,2011857,2011858,2011859,2011860,2011861,2011862,2011863,2011864,2011865,2011866,2011867,2011868,2011869,2011870,2011931,2011932,2011933,2011934,2011935,2011936,2011937,2011938,2011939,2011940,2011941,2011942,2011943,2011944,2011945,2011946,2011947,2011948,2011949,2011950,2011951,2011952,2011953,2011954,2011955,2011956,2011957,2011958,2011959,2011960,2011961,2011962,2011963,2011964,2011965,2011966,2012324,2012325,2012326,2012327,2012328,2012329,2012330,2012331,2012332,2012333,2012334,2012335,2012396,2012397,2012398,2012399,2012400,2012401,2012402,2012403,2012404,2012405,2012406,2012407,101710101,101710102,101710103,101710104,101710105,101710106,101710107,101710108,101710109,101710110,101710111,101710201,101710202,101710203,101710204,101710205,101710206,101710207,101710208,101710209,101710210,101710211,101710301,101710302,101710303,101710304,101710305,101710306,101710307,101710308,101710309,101710310,101710311,101710401,101710402,101710403,101710404,101710405,101710406,101710407,101710408,101710409,101710410,101710411,102710101,102710102,102710103,102710104,102710105,102710106,102710107,102710108,102710109,102710110,102710111,102710201,102710202,102710203,102710204,102710205,102710206,102710207,102710208,102710209,102710210,102710211,102710301,102710302,102710303,102710304,102710305,102710306,102710307,102710308,102710309,102710310,102710311,102710401,102710402,102710403,102710404,102710405,102710406,102710407,102710408,102710409,102710410,102710411,103710101,103710102,103710103,103710104,103710105,103710106,103710107,103710108,103710109,103710110,103710111,103710201,103710202,103710203,103710204,103710205,103710206,103710207,103710208,103710209,103710210,103710211,103710301,103710302,103710303,103710304,103710305,103710306,103710307,103710308,103710309,103710310,103710311,103710401,103710402,103710403,103710404,103710405,103710406,103710407,103710408,103710409,103710410,103710411,104710101,104710102,104710103,104710104,104710105,104710106,104710107,104710108,104710109,104710110,104710111,104710201,104710202,104710203,104710204,104710205,104710206,104710207,104710208,104710209,104710210,104710211,104710301,104710302,104710303,104710304,104710305,104710306,104710307,104710308,104710309,104710310,104710311,104710401,104710402,104710403,104710404,104710405,104710406,104710407,104710408,104710409,104710410,104710411,105710101,105710102,105710103,105710104,105710105,105710106,105710107,105710108,105710109,105710110,105710111,105710201,105710202,105710203,105710204,105710205,105710206,105710207,105710208,105710209,105710210,105710211,105710301,105710302,105710303,105710304,105710305,105710306,105710307,105710308,105710309,105710310,105710311,105710401,105710402,105710403,105710404,105710405,105710406,105710407,105710408,105710409,105710410,105710411,106710101,106710102,106710103,106710104,106710105,106710106,106710107,106710108,106710109,106710110,106710111,106710201,106710202,106710203,106710204,106710205,106710206,106710207,106710208,106710209,106710210,106710211,106710301,106710302,106710303,106710304,106710305,106710306,106710307,106710308,106710309,106710310,106710311,106710401,106710402,106710403,106710404,106710405,106710406,106710407,106710408,106710409,106710410,106710411,107710101,107710102,107710103,107710104,107710105,107710106,107710107,107710108,107710109,107710110,107710111,107710201,107710202,107710203,107710204,107710205,107710206,107710207,107710208,107710209,107710210,107710211,107710301,107710302,107710303,107710304,107710305,107710306,107710307,107710308,107710309,107710310,107710311,107710401,107710402,107710403,107710404,107710405,107710406,107710407,107710408,107710409,107710410,107710411,108710101,108710102,108710103,108710104,108710105,108710106,108710107,108710108,108710109,108710110,108710111,108710201,108710202,108710203,108710204,108710205,108710206,108710207,108710208,108710209,108710210,108710211,108710301,108710302,108710303,108710304,108710305,108710306,108710307,108710308,108710309,108710310,108710311,108710401,108710402,108710403,108710404,108710405,108710406,108710407,108710408,108710409,108710410,108710411,110710101,110710102,110710103,110710104,110710105,110710106,110710107,110710108,110710109,110710110,110710111,110710201,110710202,110710203,110710204,110710205,110710206,110710207,110710208,110710209,110710210,110710211,110710301,110710302,110710303,110710304,110710305,110710306,110710307,110710308,110710309,110710310,110710311,110710401,110710402,110710403,110710404,110710405,110710406,110710407,110710408,110710409,110710410,110710411,111710101,111710102,111710103,111710104,111710105,111710106,111710107,111710108,111710109,111710110,111710111,111710201,111710202,111710203,111710204,111710205,111710206,111710207,111710208,111710209,111710210,111710211,111710301,111710302,111710303,111710304,111710305,111710306,111710307,111710308,111710309,111710310,111710311,111710401,111710402,111710403,111710404,111710405,111710406,111710407,111710408,111710409,111710410,111710411,112710101,112710102,112710103,112710104,112710105,112710106,112710107,112710108,112710109,112710110,112710111,112710201,112710202,112710203,112710204,112710205,112710206,112710207,112710208,112710209,112710210,112710211,112710301,112710302,112710303,112710304,112710305,112710306,112710307,112710308,112710309,112710310,112710311,112710401,112710402,112710403,112710404,112710405,112710406,112710407,112710408,112710409,112710410,112710411,113710101,113710102,113710103,113710104,113710105,113710106,113710107,113710108,113710109,113710110,113710111,113710201,113710202,113710203,113710204,113710205,113710206,113710207,113710208,113710209,113710210,113710211,113710301,113710302,113710303,113710304,113710305,113710306,113710307,113710308,113710309,113710310,113710311,113710401,113710402,113710403,113710404,113710405,113710406,113710407,113710408,113710409,113710410,113710411,201710101,201710102,201710103,201710104,201710105,201710106,201710107,201710108,201710109,201710110,201710111,201710501,201710502,201710503,201710504,201710505,201710506,201710507,201710508,201710509,201710510,201710511,201710901,201710902,201710903,201710904,201710905,201710906,201710907,201710908,201710909,201710910,201710911,202710201,202710202,202710203,202710204,202710205,202710206,202710207,202710208,202710209,202710210,202710211,202710601,202710602,202710603,202710604,202710605,202710606,202710607,202710608,202710609,202710610,202710611,202711001,202711002,202711003,202711004,202711005,202711006,202711007,202711008,202711009,202711010,202711011,203710301,203710302,203710303,203710304,203710305,203710306,203710307,203710308,203710309,203710310,203710311,203710701,203710702,203710703,203710704,203710705,203710706,203710707,203710708,203710709,203710710,203710711,203711101,203711102,203711103,203711104,203711105,203711106,203711107,203711108,203711109,203711110,203711111,204710401,204710402,204710403,204710404,204710405,204710406,204710407,204710408,204710409,204710410,204710411,204710801,204710802,204710803,204710804,204710805,204710806,204710807,204710808,204710809,204710810,204710811,204711201,204711202,204711203,204711204,204711205,204711206,204711207,204711208,204711209,204711210,204711211,210710101,210710102,210710103,210710104,210710105,210710106,210710107,210710108,210710109,210710110,210710111,210710201,210710202,210710203,210710204,210710205,210710206,210710207,210710208,210710209,210710210,210710211,210710301,210710302,210710303,210710304,210710305,210710306,210710307,210710308,210710309,210710310,210710311,210710401,210710402,210710403,210710404,210710405,210710406,210710407,210710408,210710409,210710410,210710411,210710501,210710502,210710503,210710504,210710505,210710506,210710507,210710508,210710509,210710510,210710511,210710601,210710602,210710603,210710604,210710605,210710606,210710607,210710608,210710609,210710610,210710611,220710101,220710102,220710103,220710104,220710105,220710106,220710107,220710108,220710109,220710110,220710111,220710201,220710202,220710203,220710204,220710205,220710206,220710207,220710208,220710209,220710210,220710211,220710301,220710302,220710303,220710304,220710305,220710306,220710307,220710308,220710309,220710310,220710311,230710101,230710102,230710103,230710104,230710105,230710106,230710107,230710108,230710109,230710110,230710111,230710201,230710202,230710203,230710204,230710205,230710206,230710207,230710208,230710209,230710210,230710211,230710301,230710302,230710303,230710304,230710305,230710306,230710307,230710308,230710309,230710310,230710311,230710401,230710402,230710403,230710404,230710405,230710406,230710407,230710408,230710409,230710410,230710411,230710501,230710502,230710503,230710504,230710505,230710506,230710507,230710508,230710509,230710510,230710511,230710601,230710602,230710603,230710604,230710605,230710606,230710607,230710608,230710609,230710610,230710611,230710701,230710702,230710703,230710704,230710705,230710706,230710707,230710708,230710709,230710710,230710711,230710801,230710802,230710803,230710804,230710805,230710806,230710807,230710808,230710809,230710810,230710811,230710901,230710902,230710903,230710904,230710905,230710906,230710907,230710908,230710909,230710910,230710911,230711001,230711002,230711003,230711004,230711005,230711006,230711007,230711008,230711009,230711010,230711011,230711101,230711102,230711103,230711104,230711105,230711106,230711107,230711108,230711109,230711110,230711111,230711201,230711202,230711203,230711204,230711205,230711206,230711207,230711208,230711209,230711210,230711211,240710101,240710102,240710103,240710104,240710105,240710106,240710107,240710108,240710109,240710110,240710111,240710201,240710202,240710203,240710204,240710205,240710206,240710207,240710208,240710209,240710210,240710211,240710301,240710302,240710303,240710304,240710305,240710306,240710307,240710308,240710309,240710310,240710311,240710401,240710402,240710403,240710404,240710405,240710406,240710407,240710408,240710409,240710410,240710411,240710501,240710502,240710503,240710504,240710505,240710506,240710507,240710508,240710509,240710510,240710511,240710601,240710602,240710603,240710604,240710605,240710606,240710607,240710608,240710609,240710610,240710611,240710701,240710702,240710703,240710704,240710705,240710706,240710707,240710708,240710709,240710710,240710711,240710801,240710802,240710803,240710804,240710805,240710806,240710807,240710808,240710809,240710810,240710811,240710901,240710902,240710903,240710904,240710905,240710906,240710907,240710908,240710909,240710910,240710911,240711001,240711002,240711003,240711004,240711005,240711006,240711007,240711008,240711009,240711010,240711011,240711101,240711102,240711103,240711104,240711105,240711106,240711107,240711108,240711109,240711110,240711111,240711201,240711202,240711203,240711204,240711205,240711206,240711207,240711208,240711209,240711210,240711211,250710101,250710102,250710103,250710104,250710105,250710106,250710107,250710108,250710109,250710110,250710111,250710201,250710202,250710203,250710204,250710205,250710206,250710207,250710208,250710209,250710210,250710211,250710301,250710302,250710303,250710304,250710305,250710306,250710307,250710308,250710309,250710310,250710311,301710103,301710104,301710105,301710106,301710107,301710108,301710109,301710110,301710111,301710112,301710113,301710203,301710204,301710205,301710206,301710207,301710208,301710209,301710210,301710211,301710212,301710213,301710303,301710304,301710305,301710306,301710307,301710308,301710309,301710310,301710311,301710312,301710313,301710403,301710404,301710405,301710406,301710407,301710408,301710409,301710410,301710411,301710412,301710413,301710503,301710504,301710505,301710506,301710507,301710508,301710509,301710510,301710511,301710512,301710513,301710603,301710604,301710605,301710606,301710607,301710608,301710609,301710610,301710611,301710612,301710613,301710703,301710704,301710705,301710706,301710707,301710708,301710709,301710710,301710711,301710712,301710713,302710101,302710102,302710103,302710104,302710105,302710106,302710107,302710108,302710109,302710110,302710111,302710201,302710202,302710203,302710204,302710205,302710206,302710207,302710208,302710209,302710210,302710211,302710301,302710302,302710303,302710304,302710305,302710306,302710307,302710308,302710309,302710310,302710311,302710401,302710402,302710403,302710404,302710405,302710406,302710407,302710408,302710409,302710410,302710411,303710101,303710102,303710103,303710104,303710105,303710106,303710107,303710108,303710109,303710110,303710111,303710201,303710202,303710203,303710204,303710205,303710206,303710207,303710208,303710209,303710210,303710211,303710301,303710302,303710303,303710304,303710305,303710306,303710307,303710308,303710309,303710310,303710311,700000641,700000642,700000643,700000644,700000645,700000646,700000647,700000648,700000649,700000650,700000651,700000652,700000747,700000748,700000749,700000750,700000751,700000752,700000753,700000754,700000755,700000756,700000757,700000758,700000759,700000760,700000761,700000762,700000763,700000764,700000765,700000766,700000767,700000768,700000769,700000770,700000771,700000772,700000773,700000774,700000775,700000776,700000777,700000778,700000779,700000780,700000781,700000782,700000783,700000784,700000785,700000786,700000787,700000788}
|
|
local player_item_list = get_item_list()
|
|
|
|
|
|
cprint("in fast_equip_dismantle_rank_type")
|
|
|
|
local found = 0
|
|
|
|
for i = 1, table.getn(player_item_list) do
|
|
|
|
item_handle = player_item_list[i]
|
|
item_code = get_item_code(item_handle)
|
|
|
|
|
|
is_in = is_in_table(array , item_code ) or false
|
|
if is_in then
|
|
found = found + dismantle_test( item_handle )
|
|
end
|
|
|
|
end
|
|
|
|
if found > 0 then
|
|
-- fast_equip_selling_rank()
|
|
-- -3000942 drop group demantelement
|
|
--[[
|
|
701001 Morceau de Cube de Force
|
|
701002 Morceau de Cube de Force Amélioré
|
|
701003 Morceau de Cube de Force Béni
|
|
702001 Morceau de Cube de Défense
|
|
702002 Morceau de Cube de Défense Amélioré
|
|
702003 Morceau de Cube de Défense Béni
|
|
1100101 Acier Oxydé<combination metariel>
|
|
1100102 Acier Désoxydé<combination metariel>
|
|
1100114 Pierre Magique de Maître ]]--
|
|
|
|
item = {701001,701002,701003,702001,702002,702003,1100101,1100102,1100114}
|
|
item_player_count = {}
|
|
|
|
for i = 1 , table.getn(item) do
|
|
item_player_count[i] = find_item(item[i])
|
|
end
|
|
|
|
|
|
|
|
for i = 1 , found do
|
|
for b = 1 , math.random(8,16) do
|
|
insert_item(-3000942,1)
|
|
end
|
|
end
|
|
|
|
for i = 1 , table.getn(item) do
|
|
if item_player_count[i] < find_item(item[i]) then
|
|
cprint(rip("<#58ACFA><b>") .. rip("@930218") .. rip(" " .. find_item(item[i]) - item_player_count[i] .." ") .. rip("@" .. get_item_name_id ( item[i] ) ) .. rip(" " .. text1 .. text2 .."") .. rip_end())
|
|
end
|
|
end
|
|
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
function dismantle_test(handle)
|
|
|
|
gold = gv("gold")
|
|
|
|
return_sell = 0
|
|
|
|
if (gold - 5100) >= 0 then
|
|
|
|
local basic_price = get_item_price( handle ) / 4
|
|
local level = get_item_level(handle)
|
|
local enhance = get_item_enhance(handle)
|
|
|
|
if is_erasable_item(handle) == 1 and level == 1 and enhance == 0 then
|
|
sv("gold", gold - 5100 )
|
|
delete_item(handle,1)
|
|
return_sell = 1
|
|
end
|
|
|
|
end
|
|
|
|
return return_sell
|
|
|
|
end
|
|
|