Ir para conteúdo

DukeeH

Membro
  • Registro em

  • Última visita

Tudo que DukeeH postou

  1. No xml do monstro (data/monsters/script.xml) depois de </flags> Adicionar: <scripts> <event name="lastHit"/> </script> creaturescripts/scripts/login.lua Registrar: registerCreatureEvent(cid, "lastHit") Sendo lastHit o nome que botou no creaturescripts.xml.
  2. DukeeH postou uma resposta no tópico em Suporte Tibia OTServer
    tem que compilar. otserv.cpp, remover: << "> WARNING: This method is completely unsafe!" << std::endl << "> Please set encryptionType = \"sha1\" (or any other available method) in config.lua" << std::endl; boost::this_thread::sleep(boost::posix_time::seconds(30));
  3. Você está reiniciando o server ou dando /reload actions depois de alterar? Se sim, você provavelmente tem mais de um script de potions e esta alterando um que não está ativo, vá no data/actions/actions.xml procura pelo id de uma potion e vê qual o script dela, ai procura esse script e edita ele.
  4. local function tameMonster(cid, item, itemEx, tame, run, broken) n = math.random(100) if n <= broken then doCreatureSay(cid, "O item quebrou! :@", TALKTYPE_ORANGE_1) doRemoveItem(item.uid) elseif n > broken and n <= (tame+broken) then doRemoveItem(item.uid) doCreatureSay(cid, "Montado com sucesso! :D", TALKTYPE_ORANGE_1) doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_BLUE, "Voce domou com sucesso "..getCreatureName(itemEx.uid)..".") return true elseif n > (tame+broken) and n <= (tame+broken+run) then doCreatureSay(cid, "O monstro escapou", TALKTYPE_ORANGE_1) doRemoveCreature(itemEx.uid) else doCreatureSay(cid, "Tente denovo!! :(", TALKTYPE_ORANGE_1) end return false end local function inArray(table, value) for i,v in pairs(table) do if (v.name == string.lower(value)) then return i end end return 0 end local mounts = { {item = 13307, name = "wailing widow", id = 1, tame=60, run=20, broken=20}, {item = 13298, name = "terror bird", id = 2, tame=40, run=20, broken=40}, {item = 5907, name = "bear", id = 3, tame=90, run=5, broken=5}, {item = 13295, name = "black sheep", id = 4, tame=40, run=30, broken=30}, {item = 13293, name = "midnight panther", id = 5, tame=60, run=20, broken=20}, {item = 13538, name = "panda", id = 19, tame=50, run=25, broken=25}, {item = 13539, name = "enraged white deer", id = 18, tame=70, run=15, broken=15}, {item = 13294, name = "draptor", id = 6, tame=60, run=20, broken=20}, {item = 13537, name = "donkey", id =13, tame=40, run=30, broken=30}, {item = 13305, name = "crustacea gigantica", id = 7, tame=80, run=10, broken=10}, {item = 13536, name = "crystal wolf", id = 16, tame=60, run=20, broken=20}, {item = 13247, name = "boar", id = 10, tame=80, run=10, broken=10}, {item = 13498, name = "sandstone scorpion", id = 21, tame=70, run=10, broken=20}, {item = 13508, name = "slug", id = 14, tame=60, run=20, broken=20}, {item = 13535, name = "dromedary", id = 20, tame=60, run=20, broken=20}, {item = 13291, name = "undead cavebear", id = 12, tame=70, run=10, broken=20}, {item = 13939, name = "fire horse", id = 22, tame=60, run=20, broken=20}, {item = 13939, name = "gray horse", id = 29, tame=60, run=20, broken=20}, {item = 13939, name = "brown war horse", id = 17, tame=60, run=20, broken=20}, {item = 15546, name = "lady bug", id = 27, tame=70, run=10, broken=20}, {item = 15545, name = "manta", id = 28, tame=60, run=20, broken=20}, {item = 13938, name = "uniwheel", id = 15, tame=70, run=15, broken=15}, {item = 13292, name = "tin lizzard", id = 8, tame=70, run=15, broken=15}, {item = 15546, name = "lady bug", id = 27, tame=70, run=15, broken=15}, {item = 15545, name = "manta ray", id = 28, tame=70, run=15, broken=15}, {item = 18447, name = "ironblight", id = 30, tame=70, run=15, broken=15}, {item = 18448, name = "magma crawler", id = 31, tame=70, run=15, broken=15}, {item = 18449, name = "dragonling", id = 32, tame=70, run=15, broken=15}, {item = 18516, name = "gnarlhound", id = 33, tame=70, run=15, broken=15}, } function onUse(cid, item, fromPosition, itemEx, toPosition) if isCreature(itemEx.uid) then if isPaladin(cid) or isKnight(cid) then if inArray(mounts, getCreatureName(itemEx.uid)) > 0 then i = inArray(mounts, getCreatureName(itemEx.uid)) if item.itemid == mounts[i].item and not getPlayerMount(cid, mounts[i].id) then if tameMonster(cid, item, itemEx, mounts[i].tame, mounts[i].run, mounts[i].broken) then doSendMagicEffect(fromPosition, CONST_ME_MAGIC_BLUE) doRemoveCreature(itemEx.uid) doPlayerAddMount(cid, mounts[i].id) else doSendMagicEffect(toPosition, CONST_ME_POFF) end end end else doPlayerSendTextMessage(cid, MESSAGE_STATUS_DEFAULT, "Somente knights e paladins podem usar o item.") end end return true end
  5. Vá no globalevents.xml e remova a tag que seja do shop. Ele está tentando achar uma tabela que não existe em sua database.
  6. DukeeH postou uma resposta no tópico em Suporte Tibia OTServer
    O windows é antigo por ser server, que é o mais indicado para hostear coisas e ter um baixo consumo do próprio sistema operacional. é o que normalmente fazem em um vps. Não tenho idéia sobre vps windows, mas por ser windows o que pode acontecer pra não ficar online é firewall, se da algum erro poste aqui, porque por não ficar online eu entendo que a instalação da certo e você não consegue abrir. Mas se tiver algum erro ja fica mais facil entender o porque.
  7. DukeeH postou uma resposta no tópico em Suporte Tibia OTServer
    Baixar um servidor: http://www.tibiaking.com/forum/search/?type=forums_topic&nodes=162&tags=9.x+-+10.x Compilar um servidor: Tutoriais diversos de como começar um servidor: http://www.tibiaking.com/forum/forums/forum/123-começando-seu-servidor/
  8. Bom e barato são coisas que dificilmente vão andar lado a lado. Pelo que vejo você está começando, então deve ir de vps (semi-dedicado) porque é excelente para quem está começando porque suporta uma média de players legal por um baixo custo, quando comparado ao dedicado. Eu não ganho nada de nenhuma empresa, mas vou falar por experiência própria, a servercore.com.br (também é host do tibiaking e alguns servidores gigantes) é muito boa e tem vps iniciando em R$49,90 e R$ 99,90. A dica sempre é pegar o melhor que puder pelo dinheiro que pode investir, depois caso precise e consiga é facil de melhorar o vps. Mas um desses dois (principalmente o segundo, se puder) vai estar muito bom para começar, lembrando de sempre pegar linux, por mais que não saiba é facil de lidar e o desempenho e segurança é MUITO melhor que windows.
  9. DukeeH postou uma resposta no tópico em Suporte Tibia OTServer
    As talkactions que estão ali (!buypremium e !changender) estão registradas duas vezes, da uma olhada no talkactions.xml e nos mods.
  10. Talkactions, vê se tem algo com relação a illegalwords, se não tiver é sources.
  11. Usar a busca...
  12. Sim, se você usar bless os jogadores vão perder menos level, mas ainda vão perder. Abre o login.lua e adiciona isso: doCreatureSetDropLoot(cid, false) Em algum lugar antes do ultimo end. (cuidado com o lugar) Assim eles vão perder level normalmente e nada de itens.
  13. DukeeH postou uma resposta no tópico em Suporte Tibia OTServer
    Se não tem promotion é só alterar o que falei no paladin. Sobre skill stages te mandei pm, ai é só fazer aquilo e botar todos os skills para x para ficar justo com quem começar depois.
  14. Testa assim: local combat = createCombatObject() setCombatParam(combat, COMBAT_PARAM_BLOCKARMOR, 1) setCombatParam(combat, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatParam(combat, COMBAT_PARAM_EFFECT, CONST_ME_PHYSICALDAMAGE) setCombatParam(combat, COMBAT_PARAM_DISTANCEEFFECT, CONST_ANI_SMALLICE) function getSpellDamage(cid, weaponSkill, weaponAttack, attackStrength) if isMonster(getCreatureTarget(cid)) then local hit = 550 local damage = -(math.random(hit * 0.7, hit)) return damage, damage else local hit = 550 local damage = -(math.random(hit * 10.7, hit)) return damage, damage end setCombatCallback(combat, CALLBACK_PARAM_SKILLVALUE, "getSpellDamage") end
  15. Atualizar até da, mas vai ser BEM complicado, as versões mais novas usam o TFS 1.0+, e você provavelmente use o 0.4, a estrutura dos scripts e da pasta mudou quase que totalmente, então você teria que converter os scripts, ou achar scripts que fazem a mesma coisa para a nova versão. Ou seja, é possivel, mas não é um ctrl + c, ctrl + v. Você consegue usar seu mapa normalmente, usa a data do outro server e vai passando/procurando os scripts aos poucos enquanto corrige os erros.
  16. DukeeH postou uma resposta no tópico em Suporte Tibia OTServer
    Eu aqui de novo. vocations.xml Vai na vocação paladin (e promotion caso use), vai ter uma tag: distDamage="1.0" abaixe esse numero, vai testando, mas na lógica cada 0.1 que você diminui seria 10% do dano. Ps. Tem que reiniciar o server a cada edição quando for no vocations.
  17. Olha no console do server, vão aparecer os ips. Eu não arrumei o script, apenas botei para aparecer se ele está pegando os ips certos.
  18. estranho Roda esse script: Mata alguem para testar, vão aparecer os 2 ips no console. local config = { affected = 10, -- how many players (deathAssits) from table deathList should this script be executed for? killStorageValue = 3943, deathStorageValue = 3944, -- commands for the texts (those inside of ||, example: |KILLS| to show skills): KILLS, KILLERNAME, TARGETNAME rewardItem = { use = true, itemid = 5953, minLevel = false, -- false if you don't want any level req minLevelDiff = false, -- false if you don't want any level diff req (negative numbers allowed). }, killMessage = { use = true, text = "You owned |TARGETNAME|! You have now |KILLERKILLS| kills!", messageClass = MESSAGE_STATUS_CONSOLE_BLUE }, killerAnimation = { use = false, text = "Frag!", -- Only 9 letters! No "commands" here. color = 1 }, targetAnimation = { use = false, text = "OWNED!!", -- Only 9 letters! No "commands" here. color = 180 } } function onDeath(cid, corpse, deathList) for i = 1, math.min(config.affected, getConfigInfo('deathAssistCount')) do local killer = deathList if(isPlayer(killer) == TRUE) then local targetKills = math.max(0, getPlayerStorageValue(cid, config.killStorageValue)) + 1 local targetDeaths = math.max(0, getPlayerStorageValue(cid, config.deathStorageValue)) + 1 local killerKills = math.max(0, getPlayerStorageValue(killer, config.killStorageValue)) + 1 local killerDeaths = math.max(0, getPlayerStorageValue(killer, config.deathStorageValue)) + 1 setPlayerStorageValue(killer, config.killStorageValue, targetKills) setPlayerStorageValue(cid, config.deathStorageValue, targetDeaths) local killerLevel = getPlayerLevel(killer) local targetLevel = getPlayerLevel(cid) local killerIp = getPlayerIp(killer) local targetIp = getPlayerIp(cid) print(targetIp) print(killerIp) local levelDiff = targetLevel - killerLevel local values = { ["KILLERKILLS"] = killerKills, ["KILLERDEATHS"] = killerDeaths, ["KILLERNAME"] = getCreatureName(killer), ["KILLERLEVEL"] = killerLevel, ["TARGETKILLS"] = targetKills, ["TARGETDEATHS"] = targetDeaths, ["TARGETNAME"] = getCreatureName(cid), ["TARGETLEVEL"] = targetLevel } function formateString(str) return(str:gsub("|([A-Z]+)|", (function(a) return values[a] end))) end if(config.rewardItem.use and (not config.rewardItem.minLevel or targetLevel >= config.rewardItem.minLevel) and (not config.rewardItem.minLevelDiff or levelDiff >= config.rewardItem.minLevelDiff)) then local uid = doPlayerAddItem(killer, config.rewardItem.itemid, 1) end if(config.killMessage.use) then doPlayerSendTextMessage(killer, config.killMessage.messageClass, formateString(config.killMessage.text)) end if(config.killerAnimation.use) then doSendAnimatedText(getCreaturePosition(killer), config.killerAnimation.text, config.killerAnimation.color) end if(config.targetAnimation.use) then doSendAnimatedText(getCreaturePosition(cid), config.targetAnimation.text, config.targetAnimation.color) end end end return true end
  19. local config = { affected = 10, -- how many players (deathAssits) from table deathList should this script be executed for? killStorageValue = 3943, deathStorageValue = 3944, -- commands for the texts (those inside of ||, example: |KILLS| to show skills): KILLS, KILLERNAME, TARGETNAME rewardItem = { use = true, itemid = 5953, minLevel = false, -- false if you don't want any level req minLevelDiff = false, -- false if you don't want any level diff req (negative numbers allowed). }, killMessage = { use = true, text = "You owned |TARGETNAME|! You have now |KILLERKILLS| kills!", messageClass = MESSAGE_STATUS_CONSOLE_BLUE }, killerAnimation = { use = false, text = "Frag!", -- Only 9 letters! No "commands" here. color = 1 }, targetAnimation = { use = false, text = "OWNED!!", -- Only 9 letters! No "commands" here. color = 180 } } function onDeath(cid, corpse, deathList) for i = 1, math.min(config.affected, getConfigInfo('deathAssistCount')) do local killer = deathList if(isPlayer(killer) == TRUE) then local targetKills = math.max(0, getPlayerStorageValue(cid, config.killStorageValue)) + 1 local targetDeaths = math.max(0, getPlayerStorageValue(cid, config.deathStorageValue)) + 1 local killerKills = math.max(0, getPlayerStorageValue(killer, config.killStorageValue)) + 1 local killerDeaths = math.max(0, getPlayerStorageValue(killer, config.deathStorageValue)) + 1 setPlayerStorageValue(killer, config.killStorageValue, targetKills) setPlayerStorageValue(cid, config.deathStorageValue, targetDeaths) local killerLevel = getPlayerLevel(killer) local targetLevel = getPlayerLevel(cid) local levelDiff = targetLevel - killerLevel local values = { ["KILLERKILLS"] = killerKills, ["KILLERDEATHS"] = killerDeaths, ["KILLERNAME"] = getCreatureName(killer), ["KILLERLEVEL"] = killerLevel, ["TARGETKILLS"] = targetKills, ["TARGETDEATHS"] = targetDeaths, ["TARGETNAME"] = getCreatureName(cid), ["TARGETLEVEL"] = targetLevel } function formateString(str) return(str:gsub("|([A-Z]+)|", (function(a) return values[a] end))) end if getPlayerIp(cid) == getPlayerIp(killer) then return true end if(config.rewardItem.use and (not config.rewardItem.minLevel or targetLevel >= config.rewardItem.minLevel) and (not config.rewardItem.minLevelDiff or levelDiff >= config.rewardItem.minLevelDiff)) then local uid = doPlayerAddItem(killer, config.rewardItem.itemid, 1) end if(config.killMessage.use) then doPlayerSendTextMessage(killer, config.killMessage.messageClass, formateString(config.killMessage.text)) end if(config.killerAnimation.use) then doSendAnimatedText(getCreaturePosition(killer), config.killerAnimation.text, config.killerAnimation.color) end if(config.targetAnimation.use) then doSendAnimatedText(getCreaturePosition(cid), config.targetAnimation.text, config.targetAnimation.color) end end end return true end
  20. data/spells/spells.xml vai ter todas as spells lá, e embaixo os ids que podem usar, vê o id das vocações que colocou e adiciona eles nas magias que quiser que eles usem.
  21. local config = { affected = 10, -- how many players (deathAssits) from table deathList should this script be executed for? killStorageValue = 3943, deathStorageValue = 3944, -- commands for the texts (those inside of ||, example: |KILLS| to show skills): KILLS, KILLERNAME, TARGETNAME rewardItem = { use = true, itemid = 5953, minLevel = false, -- false if you don't want any level req minLevelDiff = false, -- false if you don't want any level diff req (negative numbers allowed). }, killMessage = { use = true, text = "You owned |TARGETNAME|! You have now |KILLERKILLS| kills!", messageClass = MESSAGE_STATUS_CONSOLE_BLUE }, broadcastMessage = { use = true, minLevel = false, -- false if you don't want any level req minLevelDiff = false, -- false if you don't want any level diff req (negative numbers allowed). text = "|KILLERNAME| [|KILLERLEVEL|] just killed |TARGETNAME| [|TARGETLEVEL|]!", messageClass = MESSAGE_STATUS_WARNING }, killerAnimation = { use = false, text = "Frag!", -- Only 9 letters! No "commands" here. color = 1 }, targetAnimation = { use = false, text = "OWNED!!", -- Only 9 letters! No "commands" here. color = 180 } } function onDeath(cid, corpse, deathList) for i = 1, math.min(config.affected, getConfigInfo('deathAssistCount')) do local killer = deathList if(isPlayer(killer) == TRUE) then local targetKills = math.max(0, getPlayerStorageValue(cid, config.killStorageValue)) + 1 local targetDeaths = math.max(0, getPlayerStorageValue(cid, config.deathStorageValue)) + 1 local killerKills = math.max(0, getPlayerStorageValue(killer, config.killStorageValue)) + 1 local killerDeaths = math.max(0, getPlayerStorageValue(killer, config.deathStorageValue)) + 1 setPlayerStorageValue(killer, config.killStorageValue, targetKills) setPlayerStorageValue(cid, config.deathStorageValue, targetDeaths) local killerLevel = getPlayerLevel(killer) local targetLevel = getPlayerLevel(cid) local levelDiff = targetLevel - killerLevel local values = { ["KILLERKILLS"] = killerKills, ["KILLERDEATHS"] = killerDeaths, ["KILLERNAME"] = getCreatureName(killer), ["KILLERLEVEL"] = killerLevel, ["TARGETKILLS"] = targetKills, ["TARGETDEATHS"] = targetDeaths, ["TARGETNAME"] = getCreatureName(cid), ["TARGETLEVEL"] = targetLevel } function formateString(str) return(str:gsub("|([A-Z]+)|", (function(a) return values[a] end))) end if getPlayerIp(cid) == getPlayerIp(killer) then return true end if(config.rewardItem.use and (not config.rewardItem.minLevel or targetLevel >= config.rewardItem.minLevel) and (not config.rewardItem.minLevelDiff or levelDiff >= config.rewardItem.minLevelDiff)) then local uid = doPlayerAddItem(killer, config.rewardItem.itemid, 1) end if(config.killMessage.use) then doPlayerSendTextMessage(killer, config.killMessage.messageClass, formateString(config.killMessage.text)) end if(config.broadcastMessage.use and (not config.broadcastMessage.minLevel or getPlayerLevel(cid) >= config.broadcastMessage.minLevel) and (not config.broadcastMessage.minLevelDiff or levelDiff >= config.broadcastMessage.minLevelDiff)) then broadcastMessage(formateString(config.broadcastMessage.text), config.broadcastMessage.messageClass) end if(config.killerAnimation.use) then doSendAnimatedText(getCreaturePosition(killer), config.killerAnimation.text, config.killerAnimation.color) end if(config.targetAnimation.use) then doSendAnimatedText(getCreaturePosition(cid), config.targetAnimation.text, config.targetAnimation.color) end end end return true end
  22. Tem que ver quantos GHz tem esse procesador, otservers só utilizam 1 core, então o outro é meio inutil. 1GB de ram não é muito aconselhavel nem para mapas pequenos, provavelmente é esse o problema.
  23. DukeeH postou uma resposta no tópico em Suporte Tibia OTServer
    Isso, promotion 1 seria para as normais, elder, master, elite e royal.
  24. DukeeH postou uma resposta no tópico em Suporte Tibia OTServer
    function onUse(cid, item, frompos, item2, topos) if getPlayerStorageValue(cid,13542) > 0 then doPlayerSendTextMessage(cid,22,"Você já pegou sua recompensa.") else doTeleportThing(cid, getPlayerMasterPos(cid)) setPlayerPromotionLevel(cid, 2) doPlayerPopupFYI(cid, "Você tem uma nova promotion!\nAproveite!.") setPlayerStorageValue(cid,13542,1) end return true end Registra no actions.xml e põem o actionid registrado no baú.

Informação Importante

Confirmação de Termo