Ir para conteúdo
Banner com Efeitos

x1zy

Membro
  • Registro em

  • Última visita

Tudo que x1zy postou

  1. na parte do malee ataque, calculo que tenha que ser por sources, ou você pode tentar por onStatsChange, mas não sei se o timming vai ficar legal. talvez, nunca testei, de para por addEvent lá..mas sei lá acho que isso não é uma boa ideia! as spells já dá para fazer diferente, a animação vem primeiro e depois sai a spell certo? mesmo que por diferença de 1 sec. say words > save/set outfit condition > addEvent > cast spell
  2. x1zy postou uma resposta no tópico em Suporte Tibia OTServer
    a função getPlayerBlessing não existe no teu server ou tem outro nome. descobre qual versão TFS ou outro você está usando, e baixa a lista de funções LUA. google pode te ajudar nisso.
  3. local config = { textoAvisandoSuaVelocidade = "nao", -- Se você quiser que o script mande uma mensagem para o player dizendo a velocidade dele premiumAccount = "nao", -- Se precisa de premium velocidadeDaSuaBike = 1000, -- A volocidade da bike, sempre bote números de 1 á 10. Caso bote mais que isso a volicidade vai ficar muito alta. outfitMale = 95, -- Outfit male outfitFemale = 95, -- Outfit female efeito = 18, -- Efeito que ira aparescer quando der use. storageValue = 5603, -- Storage Para a bike usaVipSystem = "nao", -- Caso alguem use algum tipo de vip system bote sim storageUsadaNoVipSystem = 0, -- Aqui boata a storage do vip system caso use } function onUse(cid, item, itemEx, fromPosition, toPosition) if isPlayer(cid) and getCreatureOutfit(cid).lookType == 814 then return false end if getPlayerStorageValue(cid, config.storageValue) <= 0 then setPlayerStorageValue(cid, 3624, ""..getPlayerStamina(cid).."") a = {lookType = config.outfitMale, lookHead = getCreatureOutfit(cid).lookHead, lookBody = getCreatureOutfit(cid).lookBody, lookLegs = getCreatureOutfit(cid).lookLegs, lookFeet = getCreatureOutfit(cid).lookFeet} b = {lookType = config.outfitFemale, lookHead = getCreatureOutfit(cid).lookHead, lookBody = getCreatureOutfit(cid).lookBody, lookLegs = getCreatureOutfit(cid).lookLegs, lookFeet = getCreatureOutfit(cid).lookFeet} doSendMagicEffect(getThingPos(cid), config.efeito) speedRate = config.velocidadeDaSuaBike * 1000 doChangeSpeed(cid, speedRate + getPlayerStorageValue(cid, 3624)) setPlayerStorageValue(cid, config.storageValue, 1) if getPlayerSex(cid) == 0 then doSetCreatureOutfit(cid, b, -1) else doSetCreatureOutfit(cid, a, -1) end if config.textoAvisandoSuaVelocidade == "sim" then doPlayerSendTextMessage(cid, 27, "Sua velocidade agora é: "..getPlayerStorageValue(cid, 3624).."") end else setPlayerStorageValue(cid, config.storageValue, 0) doSendMagicEffect(getThingPos(cid), config.efeito) doRemoveCondition(cid, CONDITION_OUTFIT) retireSpeedRate = config.velocidadeDaSuaBike * 100 playerSpeedNow = -retireSpeedRate - getPlayerStorageValue(cid, 3624) doChangeSpeed(cid, playerSpeedNow) end return true end
  4. checkistm = cp[pokenick] ----- linha 696 você não tem a tebela "cp"
  5. esse script não reseta a vip, deve ser por login, procura no teu creatureevents.xml os login, que por ser baiak deve ter uns quantos ai.
  6. @UP também faço/edito sistemas de pokemon!
  7. editei para usar a função getPlayerVocation(cid) e não getPlayerVocationId(cid)
  8. experimente mudar 2 coisas, function dtt.removeMonsters() : function dtt.removeMonsters() for i = 1, 4 do local a = getThingfromPos(dtt.monster.pos.a .. i) local b = getThingfromPos(dtt.monster.pos.b .. i) if isMonster(a.uid) then doRemoveCreature(a.uid) end if isMonster(b.uid) then doRemoveCreature(b.uid) end end return true end function onDeath(cid, corpse, mostDamageKiller) : function onDeath(cid, corpse, mostDamageKiller) --Avisos de morte torres time azul if getCreatureName(cid) == dtt.monster.name.a2 then doBroadcastMessage("[DEFEND THE TOWER] A torre azul do topo foi destruida.", MESSAGE_EVENT_ADVANCE) doCreateItem(9596, dtt.monster.pos.a2) setGlobalStorageValue(dtt.storage.tower_red, (getGlobalStorageValue(dtt.storage.tower_red)+1)) return true end if getCreatureName(cid) == dtt.monster.name.a3 then broadcastMessage("[DEFEND THE TOWER] A torre azul do meio foi destruida.", MESSAGE_EVENT_ADVANCE) doCreateItem(9596, dtt.monster.pos.a3) setGlobalStorageValue(dtt.storage.tower_red, (getGlobalStorageValue(dtt.storage.tower_red)+1)) return true end if getCreatureName(cid) == dtt.monster.name.a4 then broadcastMessage("[DEFEND THE TOWER] A torre azul de baixo foi destruida.", MESSAGE_EVENT_ADVANCE) doCreateItem(9596, dtt.monster.pos.a4) setGlobalStorageValue(dtt.storage.tower_red, (getGlobalStorageValue(dtt.storage.tower_red)+1)) return true end --Avisos de morte torres time vermelho if getCreatureName(cid) == dtt.monster.name.b2 then broadcastMessage("[DEFEND THE TOWER] A torre vermelha do topo foi destruida.", MESSAGE_EVENT_ADVANCE) doCreateItem(9596, dtt.monster.pos.b2) setGlobalStorageValue(dtt.storage.tower_blue, (getGlobalStorageValue(dtt.storage.tower_blue)+1)) return true end if getCreatureName(cid) == dtt.monster.name.b3 then broadcastMessage("[DEFEND THE TOWER] A torre vermelha do meio foi destruida.", MESSAGE_EVENT_ADVANCE) doCreateItem(9596, dtt.monster.pos.b3) setGlobalStorageValue(dtt.storage.tower_blue, (getGlobalStorageValue(dtt.storage.tower_blue)+1)) return true end if getCreatureName(cid) == dtt.monster.name.b4 then broadcastMessage("[DEFEND THE TOWER] A torre vermelha de baixo foi destruida.", MESSAGE_EVENT_ADVANCE) doCreateItem(9596, dtt.monster.pos.b4) setGlobalStorageValue(dtt.storage.tower_blue, (getGlobalStorageValue(dtt.storage.tower_blue)+1)) return true end --Aviso ultimas torres e abertura do teleporte if getCreatureName(cid) == dtt.monster.name.a1 then dtt.removeMonsters() setGlobalStorageValue(dtt.storage.win, "red") setGlobalStorageValue(dtt.storage.tower_red, (getGlobalStorageValue(dtt.storage.tower_red)+1)) dtt.close() broadcastMessage(dtt.msg.win_team_red, MESSAGE_EVENT_ADVANCE) dtt.resultBattle() return true end --Aviso ultimas torres e abertura do teleporte if getCreatureName(cid) == dtt.monster.name.b1 then dtt.removeMonsters() setGlobalStorageValue(dtt.storage.win, "blue") setGlobalStorageValue(dtt.storage.tower_blue, (getGlobalStorageValue(dtt.storage.tower_blue)+1)) dtt.close() broadcastMessage(dtt.msg.win_team_blue, MESSAGE_EVENT_ADVANCE) dtt.resultBattle() return true end --Verificando buff sorcerer and paladin if getCreatureName(cid) == dtt.monster.name.buff1 then if (getPlayerStorageValue(mostDamageKiller[1], dtt.storage.team_blue) == 1) then dtt.setBuff(dtt.storage.team_blue, 1, 3) for _, index in ipairs(dtt.getPlayersInEvent()) do if getPlayerStorageValue(index.pid, dtt.storage.team_blue) == 1 then doPlayerSendTextMessage(index.pid, 25, "[DEFEND THE TOWER] Os sorcerers e paladinos do seu time receberao buff, utilize as magias wizard buff ou archer buff.") end end else dtt.setBuff(dtt.storage.team_red, 1, 3) for _, index in ipairs(dtt.getPlayersInEvent()) do if getPlayerStorageValue(index.pid, dtt.storage.team_red) == 1 then doPlayerSendTextMessage(index.pid, 25, "[DEFEND THE TOWER] Os sorcerers e paladinos do seu time receberao buff, utilize as magias wizard buff ou archer buff.") end end end return true end --Verificando buff druid and knight if getCreatureName(cid) == dtt.monster.name.buff2 then if (getPlayerStorageValue(mostDamageKiller[1], dtt.storage.team_blue) == 1) then dtt.setBuff(dtt.storage.team_blue, 2, 4) for _, index in ipairs(dtt.getPlayersInEvent()) do if getPlayerStorageValue(index.pid, dtt.storage.team_blue) == 1 then doPlayerSendTextMessage(index.pid, 25, "[DEFEND THE TOWER] Os druids e knights do seu time receberao buff, utilize as magias magician buff ou warrior buff.") end end else dtt.setBuff(dtt.storage.team_red, 2, 4) for _, index in ipairs(dtt.getPlayersInEvent()) do if getPlayerStorageValue(index.pid, dtt.storage.team_red) == 1 then doPlayerSendTextMessage(index.pid, 25, "[DEFEND THE TOWER] Os druids e knights do seu time receberao buff, utilize as magias magician buff ou warrior buff.") end end end return true end return true end
  9. eu editar o post, faz pelo onThink mesmo, com interval de 30seg. lembrando que eu não testei, posta se tiver erros no console. outra questão, não sei se você vai ter que usar os dias em Inglês ou Português. testa nos 2. local days = { ['Wednesday'] = "16:20:00", -- quarta ['Friday'] = "16:20:00" } local cfg = { storage = 82342, createpos = {x = 174, y = 47, z = 7}, topos = {x = 70, y = 341, z = 6}, msg = "O Last man standing Event Teleport acabou de fechar! Ele irá reaparecer de novo a cada 2 horas! Todos os participantes, preparem-se para a batalha!", timetoclose = 120 } local function remove() local tp = getTileItemById(cfg.createpos, 1387).uid if tp ~= 0 then doRemoveItem(tp) doBroadcastMessage(cfg.msg) setGlobalStorageValue(cfg.storage, 0) end end function onThink(interval) if not getGlobalStorageValue(cfg.storage) == 1 then getDay = days[os.date("%A")] if getDay and getDay == os.date("%H") then setGlobalStorageValue(cfg.storage, 1) doCreateTeleport(1387, cfg.topos, cfg.createpos) doBroadcastMessage("Last man standing event Teleport esta aberto!\nCatch o teleport vai fechar dentro de "..cfg.timetoclose.." segundos! O teleport esta localizado na sala de Eventos.") addEvent(remove, cfg.timetoclose * 1000) end end return true end
  10. eu não percebi bem a sua pergunta, mas calculo que quer trocar horas por minutos, certo? muda isto: setPlayerStorageValue(cid, config.storage, os.time() + config.time * 3600 * 1000) addEvent(endExpRate, config.time * 3600 * 1000, cid) para: setPlayerStorageValue(cid, config.storage, os.time() + config.time * 1000) addEvent(endExpRate, config.time * 1000, cid)
  11. <globalevent name="EVENTNAME" time="16:20:00" script="SCRIPTNAME.lua" /> local cfg = { storage = 82342, createpos = {x = 174, y = 47, z = 7}, topos = {x = 70, y = 341, z = 6}, msg = "O Last man standing Event Teleport acabou de fechar! Ele irá reaparecer de novo a cada 2 horas! Todos os participantes, preparem-se para a batalha!", timetoclose = 120 } local function remove() local tp = getTileItemById(cfg.createpos, 1387).uid if tp ~= 0 then doRemoveItem(tp) doBroadcastMessage(cfg.msg) setGlobalStorageValue(cfg.storage, 0) end end function onTime(interval) if not getGlobalStorageValue(cfg.storage) == 1 then setGlobalStorageValue(cfg.storage, 1) doCreateTeleport(1387, cfg.topos, cfg.createpos) doBroadcastMessage("Last man standing event Teleport esta aberto!\nCatch o teleport vai fechar dentro de "..cfg.timetoclose.." segundos! O teleport esta localizado na sala de Eventos.") addEvent(remove, cfg.timetoclose * 1000) end return true end
  12. Boa noite, faço sistemas completos em lua, também com otclient (Não faço design/manipulação de img)! e posso entrar numa equipe que seja séria e com um mapa lindo. quem sou e o que fiz: conhecido em alguns outros forums, a alguns anos atrás, como josejunior23. algums dos meus trabalhos, lembrando que isto já tem alguns anos. Advanced Pet System With Races - http://x1zycode.weebly.com/pet-system-free.html Advanced Action House - https://otland.net/threads/advanced-auction-house-v1-0-wow-based.129864/ Advanced Vocation Changer:
  13. bem, pelo que esta no script, ele simplesmente teleport o player para x pos. ele não muda outfit de bike nem nada disso. recomendo você descobrir qual o script que remove outfit de bike, e procurar a função, estou falando de apenas uma linha. e também descobrir o ID da storage da BIKE. local storage = 985432 function onSay(cid, words, param) doPlayerSendTextMessage(cid, 25, "Personagem Desbugado!") setPlayerStorageValue(cid, storage, 0) doSendMagicEffect(getCreaturePosition(cid),3) -- ADICIONAR FUNÇÃO QUE MUDA OUTFIT return true end
  14. tou um pouco enferrujado e não testei: local cfg = { [501] = {1, 2, 3, 4, 5, 6}, [601] = {7, 8, 9, 10}, [701] = {11, 12 ,13, 14, 15} } local storage = 23423 -- max level storage function onAdvance(cid, skill, oldLevel, newLevel) local playerVocation = getPlayerVocation(cid) getLevel = cfg[newLevel] if newLevel == getLevel and isInArray(getLevel, playerVocation) or getPlayerStorageValue(storage) == 1 then doPlayerAddExperience(cid, (getExperienceForLevel(getLevel) - getPlayerExperience(cid))) setPlayerStorageValue(storage, 1) return true end return true end
  15. pode postar o seu codigo como ele esta agora, e TODOS os erros que da no console assim que o evento acaba? visto que ainda assim remove os players, o que falta é alguns checks, para n chamar x função caso o player não seja encontrado.
  16. penso que já descobrimos o problema, no codigo, não ha nada que chame: Military Rank: Command Sergeant Major, isso vem de outra função onLook, que de certesa, esta interferindo. pode postar a outra onLook?
  17. local cfg = {item = 2423, ammount = 1} function onUse(cid, item, fromPosition, item2, toPosisition) local rskulls = {green = SKULL_GREEN, red = SKULL_RED, black = SKULL_BLACK} if not isInArray(rskulls, getPlayerSkullType(cid)) then doPlayerSendCancel(cid,"You dont have skulls") return true end if not doPlayerRemoveItem(cid, cfg.item, cfg.ammount) then doPlayerSendCancel(cid,"You need ".. cfg.ammount .. "x " .. getItemNameById(cfg.item) .. ".") return true end doCreatureSetSkullType(cid, 0) doCreatureSay(cid, "Your frags and skulls is cleaned!", 19) player = getPlayerGUID(cid) doRemoveCreature(cid, true) db.executeQuery("UPDATE `killers` SET `unjustified` = 0 WHERE `id` IN (SELECT `kill_id` FROM `player_killers` WHERE `player_id` = " .. player .. ")") return true end
  18. me desculpa, eu tinha acabado de acordar e não li seu código, só li o que você disse. mas nessa parte, que supostamente verifica se o look é em você ou outro player, não ha erros: if isPlayer(thing.uid) and thing.uid ~= cid then doPlayerSetSpecialDescription(thing.uid,' [Frags: '..getPlayerFrags(thing.uid)..']') return true elseif thing.uid == cid then doPlayerSetSpecialDescription(cid,' [Frags: '..getPlayerFrags(cid)..']') pode postar a msg quando da look em outro player? aparece normal?
  19. pelo que vi no script, precisa mudar mais do que em um lugar, se fez isso, provavelmente mudou com os mesmo parâmetros que passei em todas as partes. basta ver no código e seguir a lógica. procura: doPlayerSetBalance(cid,getPlayerBalance(cid) + aloot_boost[bag[i].itemid]) muda: doPlayerAddMoney(cid, aloot_boost[bag[i].itemid]) procura: doPlayerSetBalance(cid,getPlayerBalance(cid) + aloot_boost[info.itemid]) muda: doPlayerAddMoney(cid, aloot_boost[info.itemid]) procura: doPlayerSetBalance(cid, getPlayerBalance(cid) + tonumber(bag[i].quant) * multiplie) muda: doPlayerAddMoney(cid, tonumber(bag[i].quant) * multiplie) procura: doPlayerSetBalance(cid, getPlayerBalance(cid) + info.quant * multiplie) muda: doPlayerAddMoney(cid, info.quant * multiplie) procura: doPlayerSetBalance(cid,getPlayerBalance(cid) + total) muda: doPlayerAddMoney(cid,total)
  20. não vai fazer diferença, tem é que remover o doPlayerSetBalance, ou talvez, você pode até mesmo usar o NPC de banco e deixar como esta.
  21. pelo que vi ele usa um bank system, doPlayerSetBalance(cid, getPlayerBalance(cid) + tonumber(bag[i].quant) * multiplie) onde achar, muda para: doPlayerAddMoney(cid, tonumber(bag[i].quant) * multiplie) lembrando, tenta acompanhar a lógica do script.
  22. ele remove alguns dos players que estão lã? ou não remove nenhum e da erro? edit, troca essa função: function dtt.removeMonsters() for i = 1, 4 do local a = getThingfromPos(dtt.monster.pos.a .. i) local b = getThingfromPos(dtt.monster.pos.b .. i) if isPlayer(a.uid) then doRemoveCreature(a.uid) end if isPlayer(b.uid) then doRemoveCreature(b.uid) end end return true end n testei.
  23. troca essa parte do onLook: function onLook(cid, thing, position, lookDistance) if isPlayer(thing.uid) then doPlayerSetSpecialDescription(cid,' [Frags: '..getPlayerFrags(cid)..']') local string = 'You see yourself.' if getPlayerFlagValue(cid, PLAYERFLAG_SHOWGROUPINSTEADOFVOCATION) then string = string..' You are '.. getPlayerGroupName(cid) ..'.' elseif getPlayerVocation(cid) ~= 0 then string = string..' You are '.. getPlayerVocationName(cid) ..'.' else string = string..' You have no vocation.' end string = string..getPlayerSpecialDescription(cid)..'' if getPlayerNameByGUID(getPlayerPartner(cid), false, false) ~= nil then string = string..' You are '.. (getPlayerSex(cid) == 0 and 'wife' or 'husband') ..' of '.. getPlayerNameByGUID(getPlayerPartner(cid)) ..'.' end if getPlayerGuildId(cid) > 0 then string = string..' You are ' .. (getPlayerGuildRank(cid) == '' and 'a member' or getPlayerGuildRank(cid)) ..' of the '.. getPlayerGuildName(cid) string = getPlayerGuildNick(cid) ~= '' and string..' ('.. getPlayerGuildNick(cid) ..').' or string..'.' end if getPlayerFlagValue(cid, PLAYERCUSTOMFLAG_CANSEECREATUREDETAILS) then string = string..'\nHealth: ['.. getCreatureHealth(cid) ..' / '.. getCreatureMaxHealth(cid) ..'], Mana: ['.. getCreatureMana(cid) ..' / '.. getCreatureMaxMana(cid) ..'].' string = string..'\nIP: '.. doConvertIntegerToIp(getPlayerIp(cid)) ..'.' end if getPlayerFlagValue(cid, PLAYERCUSTOMFLAG_CANSEEPOSITION) then string = string..'\nPosition: [X:'.. position.x..'] [Y:'.. position.y..'] [Z:'.. position.z..'].' end doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, string) return false end return true end
  24. tem que kickar o player antes de chamar DB! não testei. local price = 20000000 function onSay(cid, words, param, channel) local rskulls = {green = SKULL_GREEN, red = SKULL_RED, black = SKULL_BLACK} if not isInArray(rskulls, getPlayerSkullType(cid)) then doPlayerSendCancel(cid,"You dont have skulls") return true end if not doPlayerRemoveMoney(cid, price) then doPlayerSendCancel(cid,"You need " .. price .. " cash.") return true end doCreatureSetSkullType(cid, 0) doCreatureSay(cid, "Your frags and skulls is cleaned!", 19) player = getPlayerGUID(cid) doRemoveCreature(cid, true) db.executeQuery("UPDATE `killers` SET `unjustified` = 0 WHERE `id` IN (SELECT `kill_id` FROM `player_killers` WHERE `player_id` = " .. player .. ")") return true end
  25. Bem, vou te ajudar a pescar, saca? 1º antes de: setPlayerStorageValue(cid, 18392, getCreatureSpeed(cid)) por: local chance = math.random(1, 6) -- chance 1 em 6 if not chance == 1 then doPlayerSendCancel(cid, "Não foi possivel roubar o carro.") return true end 2º no globalEvents, descobre qual o ficheiro lua do seu logout, e coloca isso: if getPlayerStorageValue(cid, 18391) == 1 then doPlayerSendCancel(cid, "Você está num veículo.") return false end 3° basta adicionar actionID nos tiles na frente do "depot" e configurar um onMoviment e checar a storage, se sim chama o codigo que remove o outfit/speed de carro. 4º mais uma vez, não tem no codigo a parte que ele desce do carro.

Informação Importante

Confirmação de Termo