
Tudo que Bodak Reborn postou
-
(Resolvido)Monstro não ataca player com storage
@RXSora, não existe função para remover hp. Pelo menos não no meu servidor. x)
-
(Resolvido)Puxar a alavanca c/ item no piso certo , se não , morre
Editei o código, testa lá.
-
(Resolvido)Puxar a alavanca c/ item no piso certo , se não , morre
E se não estiver, ele morre?
-
Passiva Poke Stage
configuration.lua, na pasta lib. config.lua é outra coisa.
-
(Resolvido)Puxar a alavanca c/ item no piso certo , se não , morre
Como assim? Tá funcionando? Qual o erro?
-
(Resolvido)Puxar a alavanca c/ item no piso certo , se não , morre
function onUse(cid, item, frompos, item2, topos) local pos = {x=828,y=743,z=7} local poss = {x=845,y=745,z=7} local item = 1616 if getTileItemById (pos, item).uid >= 1 then doTeleportThing (cid, poss) elseif getTileItemById (pos, item).uid == 0 then doCreatureAddHealth (cid, -getCreatureMaxHealth (cid)) end return true end
-
(Resolvido)Monstro não ataca player com storage
movements/scripts nome_arquivo.lua function onStepIn(cid, item, position, fromPosition) local storage = 318926 -- storage da quest. if getPlayerStorageValue (cid, storage) ~= 1 then doCreatureAddHealth (cid, -getCreatureMaxHealth(cid)) end return true end movements.xml <movevent type="StepIn" actionid="ACTION_ID_DO_PISO" event="script" value="nome_arquivo.lua" />
-
[PEDIDO] Hunt Excluisiva.
Qual parte tu não entendeu? Está perguntando sobre o teleport ser sem coordenadas?
-
[PEDIDO]
Coloca um action id no chão que você quer que adicione o ponto. Você deve colocar pelo remeres. "de quanto em quanto tempo será adicionado um ponto" seria a quantidade de tempo em segundos para adicionar um ponto a mais. Ou seja, se for 1, você ganhará 1 ponto por segundo que ficar em cima do piso.
-
Potion infinita só nos traineres
Pelo que entendi, seria no script da potion. E @MaTTch, o potion não é removido, ele é transformado.
-
Regeneration no Ditto
O erro ocorre quando você executa o comando !revert, volta o Ditto pra ball ou quando tira ele da ball?
-
[PEDIDO]
movements/scripts nome_arquivo.lua local timeToAddPoints = 1 -- tempo em segundos para adicionar um ponto. local storage = 87954 addPoints = {} local function doAddPoints (cid, storage) if not isPlayer(cid) then addPoints[cid] = nil return true end setPlayerStorageValue (cid, storage, getPlayerStorageValue (cid, storage) + 1) doSendAnimatedText (getThingPosition (cid), getCreatureName(cid).." ["..getPlayerStorageValue (cid, storage).."]", math.random (1,255)) addPoints[cid] = addEvent(doAddPoints, timeToAddPoints * 1000, cid, storage) return true end function onStepIn(cid, item, position, fromPosition) if isPlayer(cid) then addPoints[cid] = addEvent(doAddPoints, timeToAddPoints * 1000, cid, storage) end return true end function onStepOut(cid) if isPlayer(cid) then stopEvent(addPoints[cid]) end return true end movements.xml <movevent type="StepIn" actionid="actiond_id" event="script" value="nome_arquivo.lua" /> <movevent type="StepOut" actionid="actiond_id" event="script" value="nome_arquivo.lua" />
-
[PEDIDO]Script De Anunciar morte
Utilize a ferramenta de pesquisa antes de postar.
-
Como por Tile da Staff? // POKETIBIA
Faça uma cópia de um arquivo aleatório em movements/script, renomeie-o e coloque o script que eu te passei. Depois, faça o que eu disse em movements.xml. O action id tu coloca pelo remeres.
-
Recompensa ao matar player
Esse é o único script do sistema? Eu só adicionei duas linhas de código, uma que define o item que será adicionado e outra que adiciona o item ao player... Não faz sentido parar de funcionar, verifique se você copiou o código inteiro. Teste com o código antigo e com o que eu passei, para ver se o erro persiste.
-
Ajude npc +REP
local config = { item = 2160, -- ID do item. qnt = 5, -- quantidade do item. } focus = 0 talk_start = 0 target = 0 following = false attacking = false q = 1 w = 0 certas = 0 erradas = 0 question = {} question[1] = {p="Quem é o atual administrador do tibiaking sem ser o Gustavo?", r="don"} question[2] = {p="Quem é o coordenador registrado em julho de 2005?", r="caidera"} question[3] = {p="Como se chama o mascote do tibiaking?", r="x-boy"} question[4] = {p="Quem foi o primeiro colaborador de Actions do tibiaking", r="colex"} question[5] = {p="Quem foi o vencedor do 1º tibiaking Scripting Championship?", r="xxxhiagoxxx"} question[6] = {p="A regra número 3 da seção geral na parte OTServer fala sobre...", r="flood"} question[7] = {p="Qual o nome da rádio oficial do tibiaking?", r="jovemix"} question[8] = {p="Qual o nome da 1ª equipe a ter seu lugar no Incentivos tibiaking?", r="spol team"} question[9] = {p="Qual o username do antigo moderador atual apoio, cujo sua primeira letra é igual a primeira letra do nome do site?", r="x9kill"} question[10] = {p="Quem é o co-fundador da Spol Team?", r="bizugo"} question[11] = {p="Quem deu a idéia para o projecto X-OTS?", r="jvchequer"} question[12] = {p="Quem postou o code para NPCs venderem Bps de items?", r="frerety"} function onThingMove(creature, thing, oldpos, oldstackpos) end function onCreatureAppear(creature) end function onCreatureDisappear(cid, pos) if focus == cid then selfSay('Good bye then.') selfLook(cid) focus = 0 talk_start = 0 end end function onCreatureTurn(creature) end function msgcontains(txt, str) return (string.find(txt, str) and not string.find(txt, '(%w+)' .. str) and not string.find(txt, str .. '(%w+)')) end function onCreatureSay(cid, type, msg) msg = string.lower(msg) if ((msgcontains(msg, 'hi')) and (focus == 0)) and getDistanceToCreature(cid) < 6 then selfSay('Olá, Eu sou um NPC de entertrenimento feito por Colex, para eu começar as perguntas digite: continuar.') focus = cid talk_start = os.clock() end if msgcontains(msg, 'hi') and (focus ~= cid) and getDistanceToCreature(cid) < 6 then selfSay('Sorry, ' .. creatureGetName(cid) .. '! I talk to you in a minute.') end if (focus == cid) and getDistanceToCreature(cid) < 6 then if (w == 1) then if msgcontains(msg, question[q].r) then selfSay('Certa resposta, diz Continuar para passar-mos a próxima pergunta!') talk_start = os.clock() q = q+1 certas = certas + 1 w = 0 else selfSay('Resposta errada, diz Continuar para passar-mos a próxima pergunta!') talk_start = os.clock() q = q+1 w = 0 erradas = erradas + 1 end else if msgcontains(msg, 'continuar') then if question[q] then selfSay(question[q].p) talk_start = os.clock() w = 1 else selfSay('Esta foi a última pergunta, voce teve ' .. certas .. ' respostas certas e ' .. erradas .. ' respostas erradas.') if certas == 12 then doPlayerAddItem (cid, config.item, config.qnt) end focus = 0 talk_start = 0 q = 1 w = 0 certas = 0 erradas = 0 end end end if msgcontains(msg, 'bye') or msgcontains(msg, 'xau') then selfSay('Adeus, ' .. creatureGetName(cid) .. '!') focus = 0 talk_start = 0 q = 1 w = 0 certas = 0 erradas = 0 end end end function onCreatureChangeOutfit(creature) end function onThink() if (os.clock() - talk_start) > 120 then if focus > 0 then selfSay('Próxima...') q = 1 w = 0 certas = 0 erradas = 0 end focus = 0 end if focus ~= 0 then if getDistanceToCreature(focus) > 5 then selfSay('Adeus então.') q = 1 w = 0 certas = 0 erradas = 0 end end end
-
(Resolvido)[Master ball] Poketibia
=)
-
Recompensa ao matar player
Você testou com o mesmo computador/mesma internet?
-
(Resolvido)[Master ball] Poketibia
data/actions/scripts/catch.lua Procura por "shinys" e adiciona lá os pokémons que você não quer que sejam capturados pela Master Ball.
- [PEDIDO]
-
Script que Desloga char ao dar Party
function onThink(cid, interval) if getPlayerStorageValue (cid, STORAGE_DE_PARTY) == 1 then doRemoveCreature (cid) end return true end Isso em creaturescripts... não sei se é onThink ou onJoinChannel
-
[PEDIDO] Hunt Excluisiva.
Como faltou algumas informações, fiz do jeito que entendi. Crie um teleport sem coordenadas pelo remeres (os que vão teleportar para a cave). Nesses teleports, coloque um action id. movements/scripts nome_arquivo.lua function onStepIn(cid, item, position, fromPosition) local config = { storage = 789456, from = {x = 1049, y = 1051, z = 6}, -- coordenada do canto superior esquerdo da área. to = {x = 1051, y = 1053, z = 7}, -- coordenada do canto inferior direito da área. maxPlayers = 1, -- quantos jogadores poderão entrar na área ao mesmo tempo. pos = {x = 1050, y = 1056, z = 7}, -- para onde o jogador será teleportado. } local function getPlayersInArea(left, right) local playersInArea = {} for _, cid in ipairs(getPlayersOnline()) do if isInRange(getThingPos(cid), left, right) then table.insert(playersInArea, cid) end end return playersInArea end if isPlayer(cid) then if getPlayerStorageValue (cid, config.storage) < os.time() then doPlayerSendTextMessage(cid, 19, "MSG caso o player não tenha acesso.") doSendMagicEffect(getThingPos(cid), CONST_ME_TELEPORT) doTeleportThing(cid, fromPosition, true) else doSendMagicEffect(getThingPos(cid), CONST_ME_TELEPORT) end if table.getn(getPlayersInArea(config.from, config.to)) < config.maxPlayers and getPlayerStorageValue (cid, config.storage) > os.time() then doSendMagicEffect(fromPosition, CONST_ME_TELEPORT) doTeleportThing (cid, config.pos) doSendMagicEffect(getThingPos(cid), CONST_ME_TELEPORT) elseif table.getn(getPlayersInArea(config.from, config.to)) >= config.maxPlayers and getPlayerStorageValue (cid, config.storage) > os.time() then doPlayerSendTextMessage (cid, 19, "MSG caso já tenha o limite de jogadores dentro da área.") doSendMagicEffect(getThingPos(cid), CONST_ME_TELEPORT) doTeleportThing(cid, fromPosition, true) end end return true end movements.xml <movevent type="StepIn" actionid="ACTION_ID_DO_TP" event="script" value="nome_arquivo.lua" /> actions/scripts nome_arquivo.lua function onUse(cid, item, frompos, item2, topos) local config = { timeExhausted = 24, -- tempo em horas para poder usar o item novamente. timeForUse = 6, -- tempo em horas que o player poderá entrar na cave. exhausted = 456789, storage = 789456, toKnow = 123456, effect = 27, -- efeito que dará ao usar o item. } if getPlayerStorageValue(cid, config.exhausted) < os.time() then setPlayerStorageValue (cid, config.storage, config.timeForUse * 60 * 60 + os.time()) setPlayerStorageValue (cid, config.exhausted, config.timeExhausted * 60 * 60 + os.time()) setPlayerStorageValue (cid, config.toKnow, 1) doSendMagicEffect (getThingPos(cid), config.effect) doPlayerSendTextMessage (cid, 19, "MSG informando que o jogador tem acesso à área.") else doPlayerSendTextMessage (cid, 19, "MSG caso o player esteja exhaustado. (Sobre ter que esperar 24 horas)") end return true end actions.xml <action itemid="ID_DO_ITEM" event="script" value="nome_arquivo.lua"/> creaturescripts/scripts nome_arquivo.lua local config = { toKnow = 123456, storage = 789456, pos = {x = 1050, y = 1056, z = 7}, -- para onde o jogador será teleportado caso o tempo tenha acabado. } function onKill(cid, target, lastHit) if getPlayerStorageValue (cid, config.toKnow) == 1 then if getPlayerStorageValue (cid, config.storage) < os.time () then doSendMagicEffect(getThingPos(cid), CONST_ME_TELEPORT) doRemoveCreature (cid) end end return true end function onLogin(cid) if getPlayerStorageValue (cid, config.toKnow) == 1 then if getPlayerStorageValue (cid, config.storage) < os.time () then doTeleportThing (cid, config.pos) setPlayerStorageValue (cid, config.toKnow, 0) end end return true end creaturescripts.xml <event type="login" name="timeAcess" event="script" value="nome_arquivo.lua"/> <event type="kill" name="timeAcessKill" event="script" value="nome_arquivo.lua"/> Em creaturescripts/login.lua procure por "registerCreatureEvent" e coloque isso embaixo: registerCreatureEvent(cid, "timeAcess") registerCreatureEvent(cid, "timeAcessKill") PS: Eu testei apenas os códigos de actions e movements. Não testei os códigos de creaturescripts, logo, são passíveis de erros.
-
Como por Tile da Staff? // POKETIBIA
Só tem o script em movements e no xml...
-
[PEDIDO] Hunt Excluisiva.
Se ninguém fizer até eu chegar em casa... eu faço.
-
Erro Script
Ah, sim... doDisapear é para apenas para pokémon, creio eu. Para o jogador ficar invisível, tenho quase certeza que envolve source. Não poderei te ajudar com isso, lamento...