Postado Junho 11, 2014 10 anos Primeiro vou testar o dela mesmo... mas vc sabe ond fica isso? <action itemid="12289" event="script"><![CDATA[ delA mano? AUHEAUEHAUEAHEAEA zoeira... Este action itemid="12289" fica no script único e ai você colocara o ID do item que irá usar.
Postado Junho 12, 2014 10 anos Autor Tava dando erro por nao ter a tag inicial.. ai fiz umas alterções e ficou assim <?xml version="1.0" encoding="UTF-8"?> <mod name="PotionExp" version="1.0" author="The Forgotten Server" contact="otland.net" enabled="yes"> <action itemid="13204" event="script"><![CDATA[ configs = { time = 1440, ---- TIME IN MINUTES needpa = TRUE, needlvl = {TRUE, level = 1}, costmana = {FALSE, mana = 1000}, addrate = 100, -- Exp que vai adicionar em % removeonuse = TRUE } function getTime(s) local n = math.floor(s / 60) s = s - (60 * n) return n, s end CreatureEventChecker = function(event, ...) -- Colex if isCreature(arg[1]) then event(unpack(arg)) end end creatureEvent = function(event, delay, ...) -- Colex addEvent(CreatureEventChecker, delay, event, unpack(arg)) end function getPlayerExtraExpRate(cid) -- By MatheusMkalo return (getPlayerRates(cid)[8]-1)*100 end ]]> domodlib('PotionExpConfigs') if getPlayerStorageValue(cid, 62164) >= 1 then return doPlayerSendCancel(cid, "You are already taking effect from this item.") end if configs.needpa and not isPremium(cid) then return doPlayerSendCancel(cid, "You need to be a premmium account to use this item.") end if configs.needlvl[1] and getPlayerLevel(cid) < configs.needlvl.level then return doPlayerSendCancel(cid, "You need to be level " .. configs.needlvl.level .. " to use this item.") end if configs.costmana[1] then if getCreatureMana(cid) < configs.costmana.mana then return doPlayerSendCancel(cid, "You need " .. configs.costmana.mana .. " mana to use this item.") else doCreatureAddMana(cid, -configs.costmana.mana) end end if configs.removeonuse then doRemoveItem(item.uid, 1) end for i = configs.time*60, 1, -1 do local a = math.floor(i/60) .. ":" .. i - (60 * math.floor(i/60)) if #a < 4 then a = string.sub(a,1,2) .. "0" .. string.sub(a, 3) end if i == configs.time*60 then creatureEvent(doPlayerSendCancel, configs.time*60*1000, cid, "The effect of the exp parchment end.") setPlayerStorageValue(cid, 62164, 0) end creatureEvent(doPlayerSendCancel, (configs.time*60-i)*1000, cid, "2x de experiencia!, o efeito acabara em "..a..".") end doPlayerSetExperienceRate(cid, (1+(configs.addrate/100))+(getPlayerExtraExpRate(cid)/100)) creatureEvent(doPlayerSetExperienceRate, configs.time *60*1000, cid, 1+(getPlayerExtraExpRate(cid)/100-(configs.addrate/100))) doPlayerSendTextMessage(cid, 22, "Agora voce ira receber mais exp por matar os mosntros.") setPlayerStorageValue(cid, 62164, os.time()) creatureEvent(setPlayerStorageValue, configs.time *60*1000, cid, 62164, 0) return TRUE ]]> domodlib('PotionExpConfigs') local time = configs.time if os.time()-getPlayerStorageValue(cid, 62164) < time *60 then doPlayerSetExperienceRate(cid, (1+(configs.addrate/100))+(getPlayerExtraExpRate(cid)/100)) creatureEvent(doPlayerSetExperienceRate, (time*60-(os.time()-getPlayerStorageValue(cid, 62164))) * 1000, cid, 1+(getPlayerExtraExpRate(cid)/100-(configs.addrate/100))) creatureEvent(setPlayerStorageValue, (time*60-(os.time()-getPlayerStorageValue(cid, 62164))) * 1000 , cid, 62164, 0) for i = (time*60-(os.time()-getPlayerStorageValue(cid, 62164))), 1, -1 do local a = math.floor(i/60) .. ":" .. i - (60 * math.floor(i/60)) if #a < 4 then a = string.sub(a,1,2) .. "0" .. string.sub(a, 3) end if i == (time*60-(os.time()-getPlayerStorageValue(cid, 62164))) then creatureEvent(doPlayerSendCancel, (time*60-(os.time()-getPlayerStorageValue(cid, 62164)))*1000, cid, "The effect of the exp parchment end.") end creatureEvent(doPlayerSendCancel, ((time*60-(os.time()-getPlayerStorageValue(cid, 62164)))-i)*1000, cid, "2x de experiencia!, o efeito acabara em "..a..".") end end return TRUE ]]> mas ta dando esse erro aqui agora :/ [12/06/2014 13:05:26] > Loading exp.xml...[Error - ScriptingManager::loadFromXml] Cannot load mod mods/exp.xml [12/06/2014 13:05:26] Line: 69, Info: Extra content at the end of the document
Postado Junho 12, 2014 10 anos Não sei mexer com mods ainda , mas testa o meu exp potion lá em cima que certo que funfa .... se quiser alguam adaptação nela só falar) A minha pot funciona assim, tu usa... fica por meia hora soltando um effect e tal... Se o player deslogar acaba e tem que usar denovo... ( da pra fazer com que não precise usar denovo) só fala de como tu precisa ... A minha pot de exp ta la em cima
Postado Junho 12, 2014 10 anos Autor Nao notei muita diferença na alteração de exp pelo seu script llucas75, talvez deve ser porque meu server é configurado a xp por "configuration.lua", que fica numa pasta lib.. la tem isso e muito mais.. e tambem acho que isso deve servir para exps configurados no config.lua speedRate = 5.0 wildEvolveChance = 500 pokemonExpPerLevelRate = 10 baseExpRate = 25 generalExpRate = 30
Postado Junho 12, 2014 10 anos Amigo o número que ira aparecer ... será igual mas vc ira ganahr o dobro de exp... como testar? crie 2 chars level 8 mate 2-3 monstros com 1.... e o outro faça msm coisa usando a pot...
Participe da conversa
Você pode postar agora e se cadastrar mais tarde. Se você tem uma conta, faça o login para postar com sua conta.