Albert José 0 #1 Posted December 29, 2008 (edited) Padrão de Postagem: Nome: Enchant System Versão: [8.40+] Tipo do script: Action Servidor Testado: ... Autor: richiadicct Muitos ja devem ter o sistema de encantamento em seu ot, que é encantar gemas em altares do tipo fire/poison/ice/energy e este faz o mesmo só que é atualizado e conta com a possibilidade de encantar o Rainbow Shield. Rainbow Shield Notas: Encantável (cada encanto dura 20 minutos). Com os encantos você pode conseguir: Sparking Rainbow Shield aumenta sua velocidade em 10 levels e possui defesa 36. Fiery Rainbow Shield aumenta seu shielding skill em 3 e possui defesa 36. Icy Rainbow Shield possui defesa 39. Terran Rainbow Shield aumenta sua velocidade de regeneração e possui defesa 37. Chega de explicações qualquer duvida ou erro é só reportar! Vamos la: :soudado: enchant.lua --by Richi~ -- function onUse(cid, item, frompos, item2, topos) local gems = {2146, 2147, 2149, 2150} local egems = {7759, 7760, 7761, 7762} local altars = {{7508, 7509, 7510, 7511}, {7504, 7505, 7506, 7507}, {7516, 7517, 7518, 7519}, {7512, 7513, 7514, 7515}} local weapons = {2383, 7384, 7389, 7406, 7402, 2429, 2430, 2435, 7380, 2454, 2423, 2445, 7415, 7392, 2391, 2544, 8905} local eweapons = {{7763, 7744, 7854, 7869}, {7765, 7746, 7856, 7871}, {7770, 7751, 7861, 7876}, {7766, 7747, 7857, 7872}, {7767, 7748, 7858, 7873}, {7768, 7749, 7859, 7874}, {7769, 7750, 7860, 7875}, {7770, 7751, 7861, 7876}, {7771, 7752, 7862, 7877}, {7772, 7753, 7863, 7878}, {7773, 7754, 7864, 7879}, {7774, 7755, 7865, 7880}, {7775, 7756, 7866, 7881}, {7776, 7757, 7867, 7882}, {7777, 7758, 7868, 7883}, {7839, 7840, 7838, 7850}, {8907, 8906, 8909, 8908}} local type = item.type if type == 0 then type = 1 end local mana = 300 * type local soul = 2 * type if isInArray(gems, item.itemid)== TRUE then for aa=1, #gems do if item.itemid == gems[aa] then a=aa end end if isInArray(altars[a], item2.itemid)== TRUE then if getPlayerMana(cid) >= mana and getPlayerSoul(cid) >= soul then doTransformItem(item.uid,egems[a]) doPlayerAddMana(cid,-mana) doPlayerAddSoul(cid,-soul) doSendMagicEffect(frompos,39) else doPlayerSendCancel(cid,"You dont have mana or soul points.") end else return 2 end elseif isInArray(egems, item.itemid)== TRUE then for bb=1, #egems do if item.itemid == egems[bb] then b=bb end end if isInArray(weapons, item2.itemid)== TRUE then for cc=1, #weapons do if item2.itemid == weapons[cc] then c=cc end end doTransformItem(item2.uid,eweapons[c][b],1000) doSendMagicEffect(frompos,39) doRemoveItem(item.uid,1) else doPlayerSendCancel(cid,"You can't enchanted this.") end else return 0 end return 1 end actions.xml <action itemid="2146" script="enchant.lua" /> <action itemid="2147" script="enchant.lua" /> <action itemid="2150" script="enchant.lua" /> <action itemid="2149" script="enchant.lua" /> <action itemid="7759" script="enchant.lua" /> <action itemid="7760" script="enchant.lua" /> <action itemid="7761" script="enchant.lua" /> <action itemid="7762" script="enchant.lua" /> Espero que gostem!!! Creditos: richiadicct Edited December 29, 2008 by Albert José Share this post Link to post
celinhoxp 0 #3 Posted January 2, 2009 Belo post man! Realmente acho o shield bem feito, so acho que deveria estender mais o seu tempo no RL... Porém, adorei o script! Abraços(Y) Share this post Link to post
541320 0 #4 Posted January 5, 2009 Muito interessante e util o script... pena q nao funciona em 8.1 "/ Share this post Link to post
fauxtaum 0 #5 Posted January 6, 2009 Muuuito bom, já vi este sistema em um OT ae, styller yourots 8.4 Roox pra caramba =D Share this post Link to post
thlmage 0 #7 Posted January 20, 2009 Nossa cara.. script MUITO bom.. tava precisando.. valeu mesmo x)~ Share this post Link to post
gnomow157 0 #9 Posted February 5, 2009 Fala ae como faz pra aumentar o tempo dele... Share this post Link to post
verme_ 0 #10 Posted February 6, 2009 Muito bom esse script, me ajudou muito. valeu ae ^^ Share this post Link to post
gnomow157 0 #11 Posted February 6, 2009 (edited) Já descobri, pra aumentar o tempo dele tem que ir na pasta items e abrir o items.xml ae procura pelos shield la e aumenta o tempo de duraçao _________________________________ Pra colocar pra mais vocs pode usar, tem q ir no movements.xml e procura pelo id do shield. Edited February 6, 2009 by gnomow157 Share this post Link to post
BhronX 0 #12 Posted August 5, 2009 Muito bom o script , Obrigado .. já ta no meu SV =] Share this post Link to post
Sparken 0 #13 Posted August 6, 2009 Pena Que meu Rainbow E Os Outros Ja Estao Sendo Utilizados Como Escudos Editados No Meu OT... Mas Realmente Esse Encantamento Eh Melhor DO Que O Comum QUe Ja Vem No OT.. Valeu! Share this post Link to post