Ir para conteúdo

WooX

Héroi
  • Registro em

  • Última visita

Tudo que WooX postou

  1. local combat = createCombatObject() setCombatParam(combat, COMBAT_PARAM_TARGETCASTERORTOPMOST, true) setCombatParam(combat, COMBAT_PARAM_TYPE, COMBAT_DEATHDAMAGE) setCombatParam(combat, COMBAT_PARAM_EFFECT, CONST_ME_MORTAREA) setCombatParam(combat, COMBAT_PARAM_DISTANCEEFFECT, CONST_ANI_SUDDENDEATH) setCombatFormula(combat, COMBAT_FORMULA_LEVELMAGIC, -1, -10, -1, -10, 5, 5, 0, 0) function onCastSpell(cid, var) doPlayerRemoveItem(cid,2268,1) return doCombat(cid, combat, var) end
  2. Acredito que a melhor maneira seria usando action, posta o script da SD ai.
  3. WooX postou uma resposta no tópico em Suporte Tibia OTServer
    Se não me engano acho que foi você que postou sobre isso no fórum gringo, eu já trabalhei com 1 equipe que conseguiu isso. Entre em contato comigo via PM.
  4. --<action uniqueid="15000" event="script" value="other/cheststorage.lua"/>-- local storage = 18940 local uid = 15000 function onUse(cid, item, frompos, item2, topos) if (item.uid == 15000) and (getPlayerStorageValue(cid,storage) < 1) then setPlayerStorageValue(cid,storage,1) else doPlayerSendCancel(cid, "You already have the storage.") end return true end
  5. Cara já que você quer substituir TODAS as sprites, eu recomendo você iniciar um SPR, DAT e OTB do 0, vai ser muito menos dor de cabeça.
  6. local config = { loginMessage = getConfigValue('loginMessage'), useFragHandler = getBooleanFromString(getConfigValue('useFragHandler')) } function onLogin(cid) local loginmsg = "[DOUBLE POINTS]: Receba pontos em dobro para qualquer valores acima de R$10,00! Promoção estendida até dia 06/05!." doCreatureSay(getCreatureByName(getCreatureName(cid)), loginmsg, TALKTYPE_PRIVATE, false, cid) local loss = getConfigValue('deathLostPercent') if(loss ~= nil) then doPlayerSetLossPercent(cid, PLAYERLOSS_EXPERIENCE, loss * 10) doPlayerAddBlessing(cid, 1) doPlayerAddBlessing(cid, 2) doPlayerAddBlessing(cid, 3) doPlayerAddBlessing(cid, 4) doPlayerAddBlessing(cid, 5) doPlayerAddPremiumDays(cid, 2) end local accountManager = getPlayerAccountManager(cid) if(accountManager == MANAGER_NONE) then local lastLogin, str = getPlayerLastLoginSaved(cid), config.loginMessage if(lastLogin > 0) then doPlayerSendTextMessage(cid, MESSAGE_STATUS_DEFAULT, str) str = "Your last visit was on " .. os.date("%a %b %d %X %Y", lastLogin) .. "." else str = str .. " Please choose your outfit." doPlayerSendOutfitWindow(cid) end doPlayerSendTextMessage(cid, MESSAGE_STATUS_DEFAULT, str) elseif(accountManager == MANAGER_NAMELOCK) then addEvent(valid(doCreatureSay), 500, cid, "Hello, it appears that your character has been locked for name violating rules, what new name would you like to have?", TALKTYPE_PRIVATE_NP, true, cid) elseif(accountManager == MANAGER_ACCOUNT) then addEvent(valid(doCreatureSay), 500, cid, "Hello, type {account} to manage your account. If you would like to start over, type {cancel} anywhere.", TALKTYPE_PRIVATE_NP, true, cid) else addEvent(valid(doCreatureSay), 500, cid, "Hello, type {account} to create an account or {recover} to recover an account.", TALKTYPE_PRIVATE_NP, true, cid) end if(not isPlayerGhost(cid)) then doSendMagicEffect(getCreaturePosition(cid), CONST_ME_TELEPORT) end registerCreatureEvent(cid, "AntiMC") registerCreatureEvent(cid, "FragReward") registerCreatureEvent(cid, "CheckVip") registerCreatureEvent(cid, "onPrepareDeath") registerCreatureEvent(cid, "PlayerLogout") registerCreatureEvent(cid, "onPrepareDeath") registerCreatureEvent(cid, "deathBroadcast") registerCreatureEvent(cid, "LevelMax") registerCreatureEvent(cid, "DeathBroadcast") registerCreatureEvent(cid, "StartSkills") registerCreatureEvent(cid, "Idle") if(config.useFragHandler) then registerCreatureEvent(cid, "SkullCheck") registerCreatureEvent(cid, "zombieevent") registerCreatureEvent(cid, "ProtectMl") registerCreatureEvent(cid, "Protectskill") registerCreatureEvent(cid, "IconMap") registerCreatureEvent(cid, "deathchannel") doPlayerOpenChannel(cid, 9) doPlayerOpenChannel(cid, 15) end registerCreatureEvent(cid, "ReportBug") registerCreatureEvent(cid, "fraglook") if getPlayerName(cid) == "Account Manager" and #getPlayersByIp(getPlayerIp(cid)) > 10 then return false end return true end
  7. Agora sim, testa ai. local config = { loginMessage = getConfigValue('loginMessage'), useFragHandler = getBooleanFromString(getConfigValue('useFragHandler')) } function onLogin(cid) local loginmsg = "[DOUBLE POINTS]: Receba pontos em dobro para qualquer valores acima de R$10,00! Promoção estendida até dia 06/05!." doCreatureSay(getCreatureByName("[Server Information]"), loginmsg, TALKTYPE_PRIVATE, false, cid) local loss = getConfigValue('deathLostPercent') if(loss ~= nil) then doPlayerSetLossPercent(cid, PLAYERLOSS_EXPERIENCE, loss * 10) doPlayerAddBlessing(cid, 1) doPlayerAddBlessing(cid, 2) doPlayerAddBlessing(cid, 3) doPlayerAddBlessing(cid, 4) doPlayerAddBlessing(cid, 5) doPlayerAddPremiumDays(cid, 2) end local accountManager = getPlayerAccountManager(cid) if(accountManager == MANAGER_NONE) then local lastLogin, str = getPlayerLastLoginSaved(cid), config.loginMessage if(lastLogin > 0) then doPlayerSendTextMessage(cid, MESSAGE_STATUS_DEFAULT, str) str = "Your last visit was on " .. os.date("%a %b %d %X %Y", lastLogin) .. "." else str = str .. " Please choose your outfit." doPlayerSendOutfitWindow(cid) end doPlayerSendTextMessage(cid, MESSAGE_STATUS_DEFAULT, str) elseif(accountManager == MANAGER_NAMELOCK) then addEvent(valid(doCreatureSay), 500, cid, "Hello, it appears that your character has been locked for name violating rules, what new name would you like to have?", TALKTYPE_PRIVATE_NP, true, cid) elseif(accountManager == MANAGER_ACCOUNT) then addEvent(valid(doCreatureSay), 500, cid, "Hello, type {account} to manage your account. If you would like to start over, type {cancel} anywhere.", TALKTYPE_PRIVATE_NP, true, cid) else addEvent(valid(doCreatureSay), 500, cid, "Hello, type {account} to create an account or {recover} to recover an account.", TALKTYPE_PRIVATE_NP, true, cid) end if(not isPlayerGhost(cid)) then doSendMagicEffect(getCreaturePosition(cid), CONST_ME_TELEPORT) end registerCreatureEvent(cid, "AntiMC") registerCreatureEvent(cid, "FragReward") registerCreatureEvent(cid, "CheckVip") registerCreatureEvent(cid, "onPrepareDeath") registerCreatureEvent(cid, "PlayerLogout") registerCreatureEvent(cid, "onPrepareDeath") registerCreatureEvent(cid, "deathBroadcast") registerCreatureEvent(cid, "LevelMax") registerCreatureEvent(cid, "DeathBroadcast") registerCreatureEvent(cid, "StartSkills") registerCreatureEvent(cid, "Idle") if(config.useFragHandler) then registerCreatureEvent(cid, "SkullCheck") registerCreatureEvent(cid, "zombieevent") registerCreatureEvent(cid, "ProtectMl") registerCreatureEvent(cid, "Protectskill") registerCreatureEvent(cid, "IconMap") registerCreatureEvent(cid, "deathchannel") doPlayerOpenChannel(cid, 9) doPlayerOpenChannel(cid, 15) end registerCreatureEvent(cid, "ReportBug") registerCreatureEvent(cid, "fraglook") if getPlayerName(cid) == "Account Manager" and #getPlayersByIp(getPlayerIp(cid)) > 10 then return false end return true end
  8. Testei com a armor aqui e realmente não funcionou como deveria, eu havia testado apenas com o caso do shield e tinha funcionado, deveria funcionar pra você também (pelo menos no caso do shield). Saber onde modificar até sei, mas não tenho o conhecimento em c++ pra fazer essa modificação.
  9. Sim, postei apenas para que você possa ver e copiar, posta seu código dentro disto.
  10. Poste seu login.lua
  11. Quando eu iniciei meu estudos em LUA essa playlist aqui me ajudou bastante, o conteúdo é sobre a linguagem em sí e algumas de suas funções, vai te dar uma boa base.
  12. Se não me engano OTX3 é baseado no TFS 1.2, qualquer gesior que funcione com TFS 1.x, deve funcionar com OTX3.
  13. Carinha, estudei o seu caso e não existe 1 função em lua que identifique qual é o slot de determinado item, então a "solução" seria 1 script para cada slot. Por exemplo, para shields você vai ter que usar este script em cada um dos shields existentes no movements.xml (caso haja algum shield que não esteja lá, você vai ter que adicionar). function onEquip(cid, item, slot) if (slot == 5) then return true else return false end return true end Rainbow Shield usado como exemplo: <!-- Rainbow Shield --> <movevent type="Equip" itemid="8905" slot="shield" level="100" event="script" value="slotshield.lua"> <vocation name="Knight"/> <vocation id="8" showInDescription="0"/> </movevent> Espero que tenha entendido o raciocínio, segue os scripts para os outros slots. Helmets function onEquip(cid, item, slot) if (slot == 1) then return true else return false end return true end Armors function onEquip(cid, item, slot) if (slot == 4) then return true else return false end return true end Legs function onEquip(cid, item, slot) if (slot == 7) then return true else return false end return true end Boots function onEquip(cid, item, slot) if (slot == 8) then return true else return false end return true end Rings function onEquip(cid, item, slot) if (slot == 9) then return true else return false end return true end Amuletos function onEquip(cid, item, slot) if (slot == 2) then return true else return false end return true end Munições function onEquip(cid, item, slot) if (slot == 10) then return true else return false end return true end Wands/Armas function onEquip(cid, item, slot) if (slot == 6) then return true else return false end return true end Lembrando: isso é uma PUTA duma GAMBIARRA, o correto seria fazer essas alterações direto nas sources.
  14. Ok, vou codar algo aqui e posto pra você testar.
  15. Como fixar items para seus devidos slots.
  16. Acabei esquecendo do tópico, vou fazer o script aqui pra você, mas antes muda o nome desse tópico, isso não é 1 bug e sim 1 frescura rs.
  17. Fico surpreso de nego realmente perder tempo mudando algo assim rs. Isso é só 1 capricho, 1 detalhe, não é 1 bug. Eu não recomendo você mudar isso, muitos jogadores de 8.60 já estão acostumados com isso, inverter a ordem e usar a arma no lugar do shield, equipar bps no lugar da flecha etc. Mas se ainda assim, você insistir nessa, eu posso fazer 1 script pra você.
  18. Cara, a armor não está sendo equipada varias vezes, você não vai ter mais defesa ou ganhar o atributo 2x se fizer isso, nas versões 8.60 sempre foi assim, sempre foi possivel colocar QUALQUER item nas mãos e no slot da flecha. Estou curioso, me diz o OT em questão, porque jogo Tibia a mais de 10 anos e nunca, repito NUNCA ví 1 OT 8.60 que não fosse desta maneira. Porque como já disse antes isso não influencia em nada, não é 1 BUG.
  19. Pelas imagens que vi não tem nada de errado, na versão 8.60 sempre foi possivel colocar partes do set nas mãos e no slot da flecha.
  20. local combat = createCombatObject() setCombatParam(combat, COMBAT_PARAM_EFFECT, 95) setCombatParam(combat, COMBAT_PARAM_TARGETCASTERORTOPMOST, 1) setCombatParam(combat, COMBAT_PARAM_AGGRESSIVE, 1) function onCastSpell(cid, var) local min, max = 30000, 40000 doCreatureAddHealth(cid, math.random(min, max)) return doCombat(cid, combat, var) end
  21. O sistema chama-se paperdoll, alguns projetos que nunca saíram do papel desenvolveram algo parecido. A mais de 2 anos atrás eu fiz algumas sprites pra uma equipe que pretendia usar este sistema num servidor atual de tibia 10.x (não lembro exatamente). Me lembro que por ser 10.x eram muitos frames, cheguei a fazer sprites para o crown e demon helmet. Vou postar aqui para você ter 1 ideia de quantos sprites eram necessários. Obs: isso somente para 2 helmets e outfit citizen, imagine combinações de sets inteiros com outfits diferentes?? Enfim... é um sistema bem complexo, que para funcionar corretamente vai exigir mais sprites do que linhas de codigos rs.
  22. Agora que fui perceber, eu cometi 1 erro no script anterior, tenta agora. --<globalevent name="rmvpz" interval="3000" event="script" value="rmvpz.lua"/>-- XML function onThink(interval, lastExecution, thinkInterval) local players = getPlayersOnline() for _, pid in ipairs(players) do if getTilePzInfo(getThingPos(pid)) and isPlayerPzLocked(pid) and getPlayerStorageValue(pid, 16700) ~= -1 then doPlayerSetPzLocked(pid, false) doCreatureSetSkullType(pid, 0) end end return true end
  23. Foi o que falei de inicio, mas você preferiu o caminho mais curto, agora não vou voltar atrás. Para remover em todos os casos basta usar o script anterior sem a verificação da storage.

Informação Importante

Confirmação de Termo