Ir para conteúdo
  • Cadastre-se

Posts Recomendados

Ola galera, estou com uma duvida e um problema. Peguei o script de um ot chamado cave exclusiva.

Porem fica dando esse erro no meu console.

 

E Voces poderia me d izer nessa parte de Laranja oque e pra colocar ?

 

 

Citar

 

 

Você tem o código disponível? Se tiver publique-o aqui: 

local function filtrateString(str)
    if type(str) ~= "string" then
        return false
    end
    local first, last = 0, 0
    local second, final = 0, #str
    for i = 1, #str do
        if string.byte(str:sub(i,i)) == string.byte('a') then
            first = i + 2
            for t = first, #str do
                if string.byte(str:sub(t,t)) == string.byte(' ') then
                    last = t - 1
                    break
                end
            end
        end
        if string.byte(str:sub(i,i)) == string.byte('b') then
            second = i + 2
        end
    end
    return {str:sub(first, last), str:sub(second, final)}
end

local f1, t1 = {x = 2435, y = 499, z = 7}, {x = 2578, y = 593, z = 7}
local f2, t2 = {x = 2445, y = 390, z = 7}, {x = 2588, y = 487, z = 7}
local f3, t3 = {x = 2461, y = 315, z = 7}, {x = 2518, y = 368, z = 7}
local f4, t4 = {x = 2423, y = 167, z = 7}, {x = 2561, y = 271, z = 7}
local f5, t5 = {x = 2457, y = 252, z = 6}, {x = 2520, y = 302, z = 6}
local f6, t6 = {x = 1932, y = 402, z = 7}, {x = 2081, y = 459, z = 7}
local f7, t7 = {x = 2194, y = 469, z = 6}, {x = 2282, y = 543, z = 6}
local f8, t8 = {x = 2058, y = 559, z = 7}, {x = 2135, y = 632, z = 7}
local f9, t9 = {x = 2049, y = 468, z = 9}, {x = 2143, y = 523, z = 9}
local f10, t10 = {x = 2068, y = 325, z = 8}, {x = 2160, y = 405, z = 8}
local f11, t11 = {x = 2592, y = 507, z = 7}, {x = 2730, y = 597, z = 7}
local f12, t12 = {x = 2609, y = 399, z = 7}, {x = 2723, y = 489, z = 7}
local f13, t13 = {x = 2526, y = 318, z = 7}, {x = 2580, y = 370, z = 7}
local f14, t14 = {x = 2267, y = 161, z = 7}, {x = 2398, y = 269, z = 7}
local f15, t15 = {x = 2769, y = 505, z = 7}, {x = 2919, y = 601, z = 7}
local f16, t16 = {x = 2245, y = 315, z = 7}, {x = 2393, y = 419, z = 7}
local f17, t17 = {x = 2598, y = 316, z = 7}, {x = 2655, y = 370, z = 7}
local f18, t18 = {x = 2411, y = 16, z = 7}, {x = 2557, y = 124, z = 7}

function onThink(interval, lastExecution)
    local first = getPlayersInArea(f1, t1)
    local second = getPlayersInArea(f2, t2)
    local third = getPlayersInArea(f3, t3)
    local fourth = getPlayersInArea(f4, t4)
    local fifth = getPlayersInArea(f5, t5)
    local sixth = getPlayersInArea(f6, t6)
    local seventh = getPlayersInArea(f7, t7)
    local eighth = getPlayersInArea(f8, t8)
    local ninth = getPlayersInArea(f9, t9)
    local tenth = getPlayersInArea(f10, t10)
    local eleventh = getPlayersInArea(f11, t11)
    local twelfth = getPlayersInArea(f12, t12)
    local thirteenth = getPlayersInArea(f13, t13)
    local fourteenth = getPlayersInArea(f14, t14)
    local fifteenth = getPlayersInArea(f15, t15)
    local sixteenth = getPlayersInArea(f16, t16)
    local seventeenth = getPlayersInArea(f17, t17)
    local eighteenth = getPlayersInArea(f18, t18)
    
    if first then
        for _, pid in pairs(first) do
            if getPlayerAccountId(pid) ~= tonumber(filtrateString(getGlobalStorageValue(822081))[1]) or getPlayerAccountId(pid) == tonumber(filtrateString(getGlobalStorageValue(822081))[1]) and tonumber(filtrateString(getGlobalStorageValue(822081))[2]) <= os.time() then
                doTeleportThing(pid, getTownTemplePosition(getPlayerTown(pid)))
                doPlayerPopupFYI(pid, "Seu tempo como dono da Cave 1 expirou. Você foi levado até seu templo.")
            end
        end
    end
    if second then
        for _, pid in pairs(second) do
                if getPlayerAccountId(pid) ~= tonumber(filtrateString(getGlobalStorageValue(822082))[1]) or getPlayerAccountId(pid) == tonumber(filtrateString(getGlobalStorageValue(822082))[1]) and tonumber(filtrateString(getGlobalStorageValue(822082))[2]) <= os.time()    then
            doTeleportThing(pid, getTownTemplePosition(getPlayerTown(pid)))
                doPlayerPopupFYI(pid, "Seu tempo como dono da Cave 2 expirou. Você foi levado até seu templo.")
            end
        end
    end
    if third then
        for _, pid in pairs(third) do
                if getPlayerAccountId(pid) ~= tonumber(filtrateString(getGlobalStorageValue(822083))[1]) or getPlayerAccountId(pid) == tonumber(filtrateString(getGlobalStorageValue(822083))[1]) and tonumber(filtrateString(getGlobalStorageValue(822083))[2]) <= os.time() then
                        doTeleportThing(pid, getTownTemplePosition(getPlayerTown(pid)))
                doPlayerPopupFYI(pid, "Seu tempo como dono da Cave 3 expirou. Você foi levado até seu templo.")
            end
        end
    end
    if fourth then
        for _, pid in pairs(fourth) do
                if getPlayerAccountId(pid) ~= tonumber(filtrateString(getGlobalStorageValue(822084))[1]) or getPlayerAccountId(pid) == tonumber(filtrateString(getGlobalStorageValue(822084))[1]) and tonumber(filtrateString(getGlobalStorageValue(822084))[2]) <= os.time() then
                doTeleportThing(pid, getTownTemplePosition(getPlayerTown(pid)))
                doPlayerPopupFYI(pid, "Seu tempo como dono da Cave 4 expirou. Você foi levado até seu templo.")
            end
        end
    end
    if fifth then
        for _, pid in pairs(fifth) do
                if getPlayerAccountId(pid) ~= tonumber(filtrateString(getGlobalStorageValue(822085))[1]) or getPlayerAccountId(pid) == tonumber(filtrateString(getGlobalStorageValue(822085))[1]) and tonumber(filtrateString(getGlobalStorageValue(822085))[2]) <= os.time() then
                doTeleportThing(pid, getTownTemplePosition(getPlayerTown(pid)))
                doPlayerPopupFYI(pid, "Seu tempo como dono da Cave 5 expirou. Você foi levado até seu templo.")
            end
        end
    end
    if sixth then
        for _, pid in pairs(sixth) do
                if getPlayerAccountId(pid) ~= tonumber(filtrateString(getGlobalStorageValue(822086))[1]) or getPlayerAccountId(pid) == tonumber(filtrateString(getGlobalStorageValue(822086))[1]) and tonumber(filtrateString(getGlobalStorageValue(822086))[2]) <= os.time() then
                doTeleportThing(pid, getTownTemplePosition(getPlayerTown(pid)))
                doPlayerPopupFYI(pid, "Seu tempo como dono da Cave 6 expirou. Você foi levado até seu templo.")
            end
        end
    end
    if seventh then
        for _, pid in pairs(seventh) do
                if getPlayerAccountId(pid) ~= tonumber(filtrateString(getGlobalStorageValue(822087))[1]) or getPlayerAccountId(pid) == tonumber(filtrateString(getGlobalStorageValue(822087))[1]) and tonumber(filtrateString(getGlobalStorageValue(822087))[2]) <= os.time() then
                doTeleportThing(pid, getTownTemplePosition(getPlayerTown(pid)))
                doPlayerPopupFYI(pid, "Seu tempo como dono da Cave 7 expirou. Você foi levado até seu templo.")
            end
        end
    end
    if eighth then
        for _, pid in pairs(eighth) do
                if getPlayerAccountId(pid) ~= tonumber(filtrateString(getGlobalStorageValue(822088))[1]) or getPlayerAccountId(pid) == tonumber(filtrateString(getGlobalStorageValue(822088))[1]) and tonumber(filtrateString(getGlobalStorageValue(822088))[2]) <= os.time() then
                doTeleportThing(pid, getTownTemplePosition(getPlayerTown(pid)))
                doPlayerPopupFYI(pid, "Seu tempo como dono da Cave 8 expirou. Você foi levado até seu templo.")
            end
        end
    end
    if ninth then
        for _, pid in pairs(ninth) do
                if getPlayerAccountId(pid) ~= tonumber(filtrateString(getGlobalStorageValue(822089))[1]) or getPlayerAccountId(pid) == tonumber(filtrateString(getGlobalStorageValue(822089))[1]) and tonumber(filtrateString(getGlobalStorageValue(822089))[2]) <= os.time() then
                doTeleportThing(pid, getTownTemplePosition(getPlayerTown(pid)))
                doPlayerPopupFYI(pid, "Seu tempo como dono da Cave 9 expirou. Você foi levado até seu templo.")
            end
        end
    end
    if tenth then
        for _, pid in pairs(tenth) do
                if getPlayerAccountId(pid) ~= tonumber(filtrateString(getGlobalStorageValue(822090))[1]) or getPlayerAccountId(pid) == tonumber(filtrateString(getGlobalStorageValue(822090))[1]) and tonumber(filtrateString(getGlobalStorageValue(822090))[2]) <= os.time() then
                doTeleportThing(pid, getTownTemplePosition(getPlayerTown(pid)))
                doPlayerPopupFYI(pid, "Seu tempo como dono da Cave 10 expirou. Você foi levado até seu templo.")
            end
        end
    end
        if eleventh then
        for _, pid in pairs(eleventh) do
                if getPlayerAccountId(pid) ~= tonumber(filtrateString(getGlobalStorageValue(822091))[1]) or getPlayerAccountId(pid) == tonumber(filtrateString(getGlobalStorageValue(822091))[1]) and tonumber(filtrateString(getGlobalStorageValue(822091))[2]) <= os.time() then
                doTeleportThing(pid, getTownTemplePosition(getPlayerTown(pid)))
                doPlayerPopupFYI(pid, "Seu tempo como dono da Cave 11 expirou. Você foi levado até seu templo.")
            end
        end
    end
        if twelfth then
        for _, pid in pairs(twelfth) do
                if getPlayerAccountId(pid) ~= tonumber(filtrateString(getGlobalStorageValue(822092))[1]) or getPlayerAccountId(pid) == tonumber(filtrateString(getGlobalStorageValue(822092))[1]) and tonumber(filtrateString(getGlobalStorageValue(822092))[2]) <= os.time() then
                doTeleportThing(pid, getTownTemplePosition(getPlayerTown(pid)))
                doPlayerPopupFYI(pid, "Seu tempo como dono da Cave 12 expirou. Você foi levado até seu templo.")
            end
        end
    end
            if thirteenth then
        for _, pid in pairs(thirteenth) do
                if getPlayerAccountId(pid) ~= tonumber(filtrateString(getGlobalStorageValue(822093))[1]) or getPlayerAccountId(pid) == tonumber(filtrateString(getGlobalStorageValue(822093))[1]) and tonumber(filtrateString(getGlobalStorageValue(822093))[2]) <= os.time() then
                doTeleportThing(pid, getTownTemplePosition(getPlayerTown(pid)))
                doPlayerPopupFYI(pid, "Seu tempo como dono da Cave 13 expirou. Você foi levado até seu templo.")
            end
        end
    end
            if fourteenth then
        for _, pid in pairs(fourteenth) do
                if getPlayerAccountId(pid) ~= tonumber(filtrateString(getGlobalStorageValue(822094))[1]) or getPlayerAccountId(pid) == tonumber(filtrateString(getGlobalStorageValue(822094))[1]) and tonumber(filtrateString(getGlobalStorageValue(822094))[2]) <= os.time() then
                doTeleportThing(pid, getTownTemplePosition(getPlayerTown(pid)))
                doPlayerPopupFYI(pid, "Seu tempo como dono da Cave 14 expirou. Você foi levado até seu templo.")
            end
        end
    end
        if fifteenth then
        for _, pid in pairs(fifteenth) do
                if getPlayerAccountId(pid) ~= tonumber(filtrateString(getGlobalStorageValue(822095))[1]) or getPlayerAccountId(pid) == tonumber(filtrateString(getGlobalStorageValue(822095))[1]) and tonumber(filtrateString(getGlobalStorageValue(822095))[2]) <= os.time() then
                doTeleportThing(pid, getTownTemplePosition(getPlayerTown(pid)))
                doPlayerPopupFYI(pid, "Seu tempo como dono da Cave 15 expirou. Você foi levado até seu templo.")
            end
        end
    end
        if sixteenth then
        for _, pid in pairs(sixteenth) do
                if getPlayerAccountId(pid) ~= tonumber(filtrateString(getGlobalStorageValue(822096))[1]) or getPlayerAccountId(pid) == tonumber(filtrateString(getGlobalStorageValue(822096))[1]) and tonumber(filtrateString(getGlobalStorageValue(822096))[2]) <= os.time() then
                doTeleportThing(pid, getTownTemplePosition(getPlayerTown(pid)))
                doPlayerPopupFYI(pid, "Seu tempo como dono da Cave 16 expirou. Você foi levado até seu templo.")
            end
        end
    end
        if seventeenth then
        for _, pid in pairs(seventeenth) do
                if getPlayerAccountId(pid) ~= tonumber(filtrateString(getGlobalStorageValue(822097))[1]) or getPlayerAccountId(pid) == tonumber(filtrateString(getGlobalStorageValue(822097))[1]) and tonumber(filtrateString(getGlobalStorageValue(822097))[2]) <= os.time() then
                doTeleportThing(pid, getTownTemplePosition(getPlayerTown(pid)))
                doPlayerPopupFYI(pid, "Seu tempo como dono da Cave 17 expirou. Você foi levado até seu templo.")
            end
        end
    end
        if eighteenth then
        for _, pid in pairs(eighteenth) do
                if getPlayerAccountId(pid) ~= tonumber(filtrateString(getGlobalStorageValue(822098))[1]) or getPlayerAccountId(pid) == tonumber(filtrateString(getGlobalStorageValue(822098))[1]) and tonumber(filtrateString(getGlobalStorageValue(822098))[2]) <= os.time() then
                doTeleportThing(pid, getTownTemplePosition(getPlayerTown(pid)))
                doPlayerPopupFYI(pid, "Seu tempo como dono da Cave 18 expirou. Você foi levado até seu templo.")
            end
        end
    end


    return true
end
    

 

Você tem alguma imagem que possa auxiliar no problema? Se sim, coloque-a aqui. 

 

erro.png

Link para o post
Compartilhar em outros sites

A parte laranja se refere ao início e final da “cave”. 
 

essas posições no script são válidas no seu mapa? Caso não forem isso pode ocasionar o erro. 

Contatos:

Discord: Marvok#9855

 

Link para o post
Compartilhar em outros sites
4 horas atrás, Marvok disse:

A parte laranja se refere ao início e final da “cave”. 
 

essas posições no script são válidas no seu mapa? Caso não forem isso pode ocasionar o erro. 

Isso que queria saber man. Mas muito obrigado por sanar minha duvida.

Oh man, eu setei as caves como vc ''indicou''. mas continua dando erro. Veja na foto se eu  fiz certo. 

 

 

aaaa.thumb.png.fa0d32e12b1f2975012dfe65859fa64b.png

 

 

5 horas atrás, Marvok disse:

A parte laranja se refere ao início e final da “cave”. 
 

essas posições no script são válidas no seu mapa? Caso não forem isso pode ocasionar o erro. 

 

aaa2.png

Link para o post
Compartilhar em outros sites
Em 15/07/2021 em 13:16, Doidodepeda disse:

Isso que queria saber man. Mas muito obrigado por sanar minha duvida.

Oh man, eu setei as caves como vc ''indicou''. mas continua dando erro. Veja na foto se eu  fiz certo. 

 

 

aaaa.thumb.png.fa0d32e12b1f2975012dfe65859fa64b.png

 

 

 

aaa2.png

Isso mesmo, porem essa função é "sensivel" ao ponto que se tiver qualquer piso preto ou seja sem piso ela pode dar esse erro, tenta verificar tudo isso antes de mudarmos a abordagem para ver o motivo do erro.

Contatos:

Discord: Marvok#9855

 

Link para o post
Compartilhar em outros sites

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.

Visitante
Responder

×   Você colou conteúdo com formatação.   Remover formatação

  Apenas 75 emojis são permitidos.

×   Seu link foi automaticamente incorporado.   Mostrar como link

×   Seu conteúdo anterior foi restaurado.   Limpar o editor

×   Não é possível colar imagens diretamente. Carregar ou inserir imagens do URL.

  • Quem Está Navegando   0 membros estão online

    Nenhum usuário registrado visualizando esta página.


  • Conteúdo Similar

    • Por braianlomas
      Como faço para corrigir esse problema para meu cliente, eu uso o tfs 0.3.6  
      Quero resolver esse problema que tenho no meu cliente, como e onde posso resolver?  
      Eu uso o tfs 0.3.6, não tenho as fontes do cliente, se você puder me dar eu vou amá-las para sempre  
       

       
    • Por A.Mokk
      Ola pessoal, estou tentando compilar o TFS 1.5 Downgrade para 8.60 atraves do MSVC 2022, ao tentar compilar da o seguinte erro:
       
       
      Fiz o download do MSVC, GitDash, TFS-SDK-3.2, e de varios boosts que tentei, ao fazer o seguinte procedimento no GitDash:
       
      Ao chegar em ./bootstrap-vcpkg.bat o GitDash nao consegue realizar o procedimento corretamente, alguem poderia me ajudar ?

      Tentei de diversas formas mas o mesmo erro sempre persiste, atualmente meu servidor utiliza TFS 0.4, consigo compilar sem nenhum problema no MSVC 2010, porem, as limitações do TFS 0.4 estão me fazendo precisar atualizar, se alguem souber como corrigir esses erros eu agradeço !

      Tutoriais utilizados :
      Compiling on Windows (vcpkg) · otland/forgottenserver Wiki · GitHub
      Compiling on Windows · otland/forgottenserver Wiki · GitHub
      Compilando TFS 1.3 com vídeo-aula - Tutoriais Infraestrutura & Proteção - Tibia King - Tudo sobre Tibia, OTServ e Bots!
      Compilar TFS 1.3 Vcpkg - Tutoriais Infraestrutura & Proteção - Tibia King - Tudo sobre Tibia, OTServ e Bots!
       
      O que acontece no Powershell:
       
    • Por thunmin
      .Qual servidor ou website você utiliza como base? 
      Canary 2.3.6
      Qual o motivo deste tópico? 
      Queria fazer com que os players não pudessem mexer no aleta sio, pois, agora os mesmos estão conseguindo mexer nos itens
      Está surgindo algum erro? Se sim coloque-o aqui. 
       
      Você tem o código disponível? Se tiver publique-o aqui: 
         
      Você tem alguma imagem que possa auxiliar no problema? Se sim, coloque-a aqui. 
       
    • Por thunmin
      .Qual servidor ou website você utiliza como base? 
      canary para o cliente 13.16
      Qual o motivo deste tópico? 
      Não consigo encontrar onde ajusta
      to com o problema no 13.16  o exausted, por exemplo os kinas era pra combar exori, erori gran e exori min, porém não ta indo ta dando exausted o char ta soltando magia ou runa e não consegue usar as potions
      Está surgindo algum erro? Se sim coloque-o aqui. 
       
      Você tem o código disponível? Se tiver publique-o aqui: 
         
      Você tem alguma imagem que possa auxiliar no problema? Se sim, coloque-a aqui. 
       
    • Por Andersontatuador
      Olá galera da TK, me chamo Anderson estou procurando alguém profissional em otservs e site.
      Já tenho um servidor o site e o cliente preciso só de uma pessoal competente, que esteja empenhado a trabalhar,
      não quero nada de graça, pois nessa onda fui mais roubado do quer eu pagar um profissional.
      caso alguém se interesse entrar em contato comigo através do whatsapp
      82 9 9304-9462
       
      Está surgindo algum erro? Se sim coloque-o aqui. 
       
      Você tem o código disponível? Se tiver publique-o aqui: 
         
      Você tem alguma imagem que possa auxiliar no problema? Se sim, coloque-a aqui. 
       
×
×
  • Criar Novo...

Informação Importante

Confirmação de Termo