Ir para conteúdo

Pesquisar na Comunidade

Mostrando resultados para as tags ''otclient''.

  • Pesquisar por Tags

    Digite tags separadas por vírgulas
  • Pesquisar por Autor

Tipo de Conteúdo


Fóruns

  • xTibia - Notícias e Suporte
    • Regras
    • Noticias
    • Soluções
    • Projetos Patrocinados
    • Tutoriais para Iniciantes
    • Imprensa
  • OTServ
    • Notícias e Debates
    • OTServlist
    • Downloads
    • Recursos
    • Suporte
    • Pedidos
    • Show-Off
    • Tutoriais
  • OFF-Topic
    • Barzinho do Éks
    • Design
    • Informática

Encontrar resultados em...

Encontrar resultados que contenham...


Data de Criação

  • Início

    FIM


Data de Atualização

  • Início

    FIM


Filtrar pelo número de...

Data de Registro

  • Início

    FIM


Grupo


Sou

  1. Gengo

    [OtClient] Auto-Loot

    Fala ai galera do xtibia estou aqui trazendo mais um module para o otClient. Esses dias atras estavo jogando pokestorm e me deparei com o autoloot e decidi fazer um parecido com o deles e então pensei porque não trazer para a comunidade? Afinal não vejo muitos modulos de autoloot para otClient o unico que vi foi o autoloot da DxP, porem não é muito intuitivo comparado com modulo da pokestorm, bom sem mais enrolação vamos lá. Feito o download do arquivo, coloque-o na pasta do seu otClient em /modules/ e pronto já é possível "utilizar-lo", porem com algumas exceções de algumas configurações básicas que temos que fazer para poder utilizar-lo com algumas eficiências. 1º Na pasta do seu otClient/data/ crie uma pasta chamada items e coloque o seus arquivos items.otb e items.xml. 2º Vai até a pasta do seu otClient/modules/game_things abre o arquivo things.lua e procure a função load(), e coloque o seguinte: g_things.loadOtb ('/items/items.otb') g_things.loadXml('/items/items.xml') Obs: Não se assustem quando entrarem no client para logar, no inicio vai dar uma travada, mas depois de esperar uns segundos ele normaliza, pois o único problema é que o carregamento dos arquivos dos items eles são demorados. Também é preciso fazer umas configurações rápida na parte do servidor para poder funcionar. Copie e cole esse script e coloque na pasta do servidor em mods/ e de o nome de autoloot.xml Ainda na pasta do seu servidor abre o arquivo /data/creaturescripts/scripts/login.lua e coloque o seguinte script dentro da função onLogin: local loot = '' for i = 1, #getPlayerStorageTable(cid, info.Storages[1]) do loot = loot..getItemInfo(getPlayerStorageTable(cid, info.Storages[1])[i]).clientId..'-'..getItemNameById(getPlayerStorageTable(cid, info.Storages[1])[i])..'@' end doSendPlayerExtendedOpcode(cid, 157, loot) Feito todos os passos corretamente, configurado certo, deve ficar assim no game: Bom espero que tenham entendido e gostado, não sou muito de ficar escrevendo tutorial, até uma próxima. Download Créditos
  2. Eu que fiz pra um amigo, créditos são meus Não fiz modificações na source, se quiserem pode pegar src e vc14 do edubart no github Download: https://www.dropbox.com/s/hxlekf4c5pmkvpo/OTC TIBIA STYLE.rar?dl=0 Scan: https://www.virustotal.com/gui/file/213f863233fe4f9443a5682f33037d6bfd685e454e0ba9855899224017d81c55/detection Tamanho: 6MB Como usar: 1. TrocarIP: modules/client_entergame/entergame.lua Alterar: EnterGame.setUniqueServer('127.0.0.1', 7171, 772, 270, 210) 127.0.0.1 = IP do SV, 772 = Versão do Client 2. Adicionar sua SPR e DAT Coloque em data/things/versão 3. Alterar Links dos botões na tela inicial client_background/background.lua 4. Alterar funções dos botões do cliente: game_inventory/inventory.lua
  3. Eai galera, blz? Bom, vim trazer pra vcs a versão 1.0 do mod de pokedex que eu desenvolvi mês passado visando aprendizado no mundo de OTC, com o objetivo também de mostrar que o otclient é flexível suficiente para se fazer muitas coisas sem a necessidade das sources nem do servidor e nem do client... Para aqueles que não conhecem, vejam o Show Off desse trabalho. Atualizações: 1. Adicionado um pack com 276 imagens de pokemons (16,1MB); 2. Pokemons shiny tem a exibição da imagem de pokemons normais (para alterar, basta remover a linha 75 do arquivo game_pokedex.lua, na pasta modules/game_pokedex de seu client); 3. Pokedex fecha ao se deslogar do char com ela aberta [créditos a @@Soulviling pela ideia]; Bom, sem mais delongas; Instalação fácil: Passo 1. Faça o download do arquivo RAR (download no final do tópico); Passo 2. Copie a pasta modules pro seu client; Passo 3. "Deseja substituir?" [X]Sim [ ]Não Passo 4. Só vai até o passo 3; Bom, segue uma imagem ATUALIZADA Download e Scan
  4. Estou disponibilizando para os Senhores, o Gerador Client Tibia, com ele voçês criaram seu proprio client old com seu ip ou host. 1 - Abra o Gerador.exe 2 - Procure pelo seu Client Tibia.exe 3 -Preencha os espaços Tibia.dat , Tibia.spr, Tibia.pic 4 - Versão 8.54 voçês coloquem e deixa em (Custom Client) 5 - IP >127.0.0.1< Coloquem o ip ou host de voçês 6 - Criem uma Imagem de Pic que é a background, imagem no formato "png" edite no Paint, irei deixar o download dele aqui 7 - Basta depois o Sr. executar e separar uma pasta propria, de preferençia nome de "Tibia", ou do seu jogo lembrando, depois voçê substitui a Spr. Dat. do seu tibia, pelo o seu client original para voçê logar! Pronto! agora só compartilhar o client e logar. Quem quiser ajudar com doação , meu pix: 062.854.037-08 😇 Cliente_Creator.rar Pic_Editor_v2.5_install.rar
  5. No print a seguir, estou com dois clients abertos ao mesmo tempo. O primeiro está com OTClient V8 Master |||| O segundo é o client clássico. Acontece que meu OTClient não está carregando essas sprites (talvez algumas outras que eu não tenha descoberto ainda também). Pra quem não conhece esse derivado (DBO), este npc só ocupa 1 sqm mesmo. O resto são sprites de tipo parede/algo intransponível. Isso deixa o caso curioso, pois não carregou sprites seguidas umas das outras... Alguém pode me ajudar a resolver? Seria difícil eu procurar outro client completo como esse e ainda ter que editar tudo que fiz até aqui nele.
  6. Bom, vou mostrar a vocês como editar o andar diagonal no otclient da maneira que vocês preferirem... Atualmente, creio que quando você anda diagonalmente, tem um delay até que você possa andar novamente. Vou ensinar tirar esse delay, e deixar a velocidade ao gosto de vocês. Em creature.cpp do server, procure pela linha: if(std::abs(newPos.x - oldPos.x) >= 1 && std::abs(newPos.y - oldPos.y) >= 1) lastStepCost = 3; Esse lastStepCost será a velocidade que o player terá ao andar diagonalmente, em relação a velocidade de quando ele anda em uma direção reta, por exemplo, um player que demora 1 segundo para andar 1 sqm, demoraria 3 segundos para andar diagonalmente. Edite esse valor ao seu gosto! Em creature.cpp do client, procure as linhas que tem isso: getStepDuration(true) E deixe assim: getStepDuration() Agora procure por: float factor = 3; if(g_game.getClientVersion() <= 810) factor = 2; Apague essa parte Logo mais abaixo tem: if(!ignoreDiagonal && (m_lastStepDirection == Otc::NorthWest || m_lastStepDirection == Otc::NorthEast || m_lastStepDirection == Otc::SouthWest || m_lastStepDirection == Otc::SouthEast)) interval *= factor; Em factor, deixe o mesmo valor que você deixou em lastStepCost no servidor. Agora em localplayer.cpp no client, novamente procure por: getStepDuration(true) E troque por: getStepDuration() Pronto, seu personagem andará diagonalmente mais suave, e com a velocidade que você escolheu.
  7. The Forgotten Tibia Server The Forgotten Tibia Server é um emulador de server MMORPG grátis de código aberto escrito em C++. É uma ramificação do projeto The Forgotten Server 1.3. Para se conectar ao server você precisará do The Forgotten Tibia Client (um cliente customizado feito do OTClient por mim - vc_redist.x86.exe é necessário) que você pode baixar no final dessa página. Traduzirei o resto da página em breve. What makes it different from The Forgotten Server 1.3? (you can see the diff analysis here) There are no vocations: Everyone starts as a normal human being with some points to be distributed among the skills. There is no skill training: It uses a system to advance skills by distributing points. All clubs, swords and axes damage are based on strenght. Distance weapons damage are based on strenght and/or dexterity. Two-handed melee weapons gives critical hit chance and critical hit damage. The more levels you get, less points you receive. Skills (some stats may be working a little different, check images) Magic (+ spell power, + rune power, + mana) Vitality (+ health) Strenght (+ physical damage) Dexterity (+ distance damage, + walk speed, + attack speed) Faith (+ support spells, + rod max damage, + mana) Intelligence (+ attack spells, + wand max damage, + mana) Defence (+ physical defence) Endurance (+ capacity, + health) Custom Systems (values may be different) Dual Wield: The player can use 2 weapons (for example: club and sword, axe and spear, sword and throwing knife). The attack speed will be fixed in 200% but the damage will drop to 75%. Each combat turn the player will use one hand to defend and the other to attack. Two Handed Melee Weapons: All two-handed melee weapons give +25% of critical hit chance and +100% of critical hit amount. Also, they have a chance of giving a bleeding effect to the target. Auto Loot Gold: The money dropped from monsters goes directly to the player. Quiver: Distance weapons are loading ammo from container item in the arrow slot and there is a new container item called "quiver". Wands and Rods varying with skills: Intelligence and faith raises the wands/rods maximum damage. Spells based on Faith and Intelligence: There is no level and vocation requirement for spells. The more you raise faith and intelligence, more spells you get. Screen with one more tile: It was added one more square meter to the screen. Title: After you reach a certain minimum value of magic, strenght or dexterity, you can choose a title to display when people look at your character. Spacebar Attack: When you use that feature from the client with autoloot gold and addons you can almost hunt without your mouse. Things You Need To Know I stopped working on this server suddenly, 4 months ago, to focus on my graduation and study other things like making games on Unity or penetration tests with Linux, also because I think you need a lot of passion and money to spend on publicity to make players enter and stay. The last thing I remember I was developing was a War System that should work integrated with the normal server, so people would play a for-fun server or a serious-rpg-server. You may want to disable the system in data files. I don't remember which files are used for this. I've made a correction recommended by Mark Saman on monster's AI system (this solves the laggy movement from fast monsters), but that change can make the server lag if there is too much players online interacting with monsters). Same as Capture The Flag system, I don't know if it's working perfectly. You may want to disable it in data files and I don't remember which files are used. I don't know if the schema.sql file available in my repository works for this server. I still have to remove passwords and accounts from the one I was using to make it available for public. The map is a mix of Svargrond, Yalahar, YurOTS, The Forgotten Server's official map and many hunting places and quests from global map. There are NPCs for tasks, blessings, bank and mount systems. The OTClient version used for this project is much more outdated then the The Forgotten Server version, one of the known bugs is the non-smoothly-walk-system. I disabled many features from OTClient's interface. Client and server compiled with Microsoft Visual Studio, I don't remember which version but I think client was with 2013 and server with 2015. There is a project folder to open the projects on Microsoft Visual Studio. You will have a lot of work to do if you want to change the spells values, in the client you need to change in 2 files and in the server you need to change in 1 I think. In some places its written "resistance" but in the clients interface its "defence". They are the same thing. Useful Links GitHub Official Repository (with data folder and schema): GustavoContreiras/TheForgottenTibiaServer (https://github.com/GustavoContreiras/TheForgottenTibiaServer) DLLs, .exe, sources: GustavoContreiras/TheForgottenTibiaServer (https://github.com/GustavoContreiras/TheForgottenTibiaServer/releases) Differences TFS 1.3 / TFTS 0.8: The Forgotten Tibia Server. · GustavoContreiras/TheForgottenTibiaServer@ce89322 (https://github.com/GustavoContreiras/TheForgottenTibiaServer/commit/ce89322c08799231f9704e65572a2ffa11fc4d2f) GitHub Official Repository of the client: GustavoContreiras/TheForgottenTibiaClient (https://github.com/GustavoContreiras/TheForgottenTibiaClient) Images Interesting Things data/actions/scripts/other/ctf.lua (when click on the flag of capture the flag arena) data/actions/scripts/other/yurez_ship.lua (when click on the wheel of the ship teleports) data/actions/scripts/other/send_cancel.lua (when click, send cancel message) data/actions/scripts/other/fulloutfits.lua (when click, give full outfits) data/creaturescripts/scripts/arena.lua data/creaturescripts/scripts/skillpoints.lua data/creaturescripts/scripts/killtasks.lua data/creaturescripts/scripts/ctf.lua data/globalevents/scripts/ctf.lua data/globalevents/scripts/dailyserversave.lua data/globalevents/scripts/raids.lua data/lib/core/ctf.lua (many lua functions used by ctf system) data/lib/core/skillpoints.lua (many lua functions used by skillpoints systems) data/lib/core/player.lua (many new lua functions) data/movements/scripts/dual_wield.lua (changes players stats when move second weapon to hand) data/movements/scripts/arena.lua (configure enter and exit teleports and set storage for arena) data/spells/spells.xml (intelligence and faith values - changes must be applied on otclient files too) data/talkactions/scripts/skillpoints.lua data/talkactions/scripts/title.lua data/weapons/scripts/bleeding_effect.lua.lua data/npc/scripts/guide.lua data/npc/scripts/bless.lua data/npc/scripts/bank.lua data/npc/scripts/tasks.lua data/npc/scripts/The Oracle.lua Fibula(client+minimap)260918.zip TheForgottenTibiaServer-0.8.zip TheForgottenTibiaServer-x64.exe DLLs.zip DLLs.zip Fibula(client+minimap)260918.zip TheForgottenTibiaServer-0.8.zip TheForgottenTibiaServer-x64.zip
  8. Gostaria de pedir uma ajuda pra adicionar um botão no final de cada skill que ao ser clicado chama uma talkaction, um botão tipo esse: Ficaria tipo: Magic Level 10 Fist Fighting 10 e por ai vai.... Alguém saberia me ajudar, esses são os arquivos do otclient skills.lua skill.otui
  9. Olá por acaso alguém sabe como eu deixo a tela do OTClient sempre no tamanho máximo? Tipo, fiz o esquema de aumentar os tiles da tela do OTClient mas quando eu logo no jogo eu preciso apertar (CTRL+.) duas vezes para a tela ficar estendida, gostaria de deixar sempre estendida sem precisar apertar o botão para ficar dessa forma. Como está: Como eu quero que fique: Creio que seja no mesmo lugar que mexe no zoom, até encontrei a opção currentViewMode para deixar sempre estendido mas até mesmo essa opção tem bordas pequenas nas laterais. Mandei tbm o arquivo para caso queiram ver como tá. gameinterface.lua
  10. [OTClient] Health Player Info OTPokemon Eae galerinha do xtibia, hoje venho trazer mais uma contribuição para a comunidade, um módulo indêntico ao do OtPokemon. Mesmo que seja simples a instalação, tem sempre aquele que não sabe onde deve colocar o módulo, peço então que tenha paciência quanto a esse simples tutorial, aos demais aqueles que já sabem, peço que ao menos leia a Observações do módulo. 1º Faça o download do módulo. 2º Extraia o módulo para a pasta do seu otClient em /modules ficando assim: Feito o passo 1 e 2 creio que já estará funcionando, isto se você fez tudo certinho. •Observações do módulo• Demonstrativo do módulo no jogo.
  11. Qm puder me dizer tambem se tem um macro de mensagem para otclient eu agradeçeria
  12. ESTOU COM O SEGUINTE ERRO AO UTILIZAR QUALQUER SPELL QUE TENHA SHOOT EFFECTS (DISTANCE EFFECTS). TANTO EU QUANTO OS MONSTROS QUE USAM DA ESTE SEGUINTE ERRO NO TERMINAL: ERROR: ProtocolGame parse message exception (56 bytes unread, last opcode is 0, prev opcode is 133): unhandled opcode 0 JA ADICIONEI OS FEATURES TODOS NECESSÁRIOS E MESMO ASSIM CONTINUO COM ESTE PROBLEMA. É SO NESTA PARTE QUE DA ESSE ERRO, E QUANDO ALGUM MONSTRO USAR UMA SPELL COM DISTANCE A SPELL NÃO DA DANO NO PLAYER. JA TAMBEM REINSTALEI O TFS 0.4 QUE JA VEM COM OS OPCODES E JA ADICIONEI NO CREATURE SCRIPT MAS NÃO FAÇO IDEIA DE COMO RESOLVER ISSO.
  13. Galera alguem pode min da uma forca com isso ? estou tentando colocar que o char apareça ali com todas as informações mais não estou conseguindo.
  14. Bom galera, eu to com esse erro ai... vou seguindo os parços e coloco cd c git clone https://github.com/microsoft/vcpkg.git cd vcpkg Porem quando uso esse ".\bootstrap-vcpkg.bat" da esse erro ai... Desculpas se coloquei na area errada, alguém poderia me ajudar? ? Grato pela atenção ❤️
  15. Mizakinha

    OTClient bugado

    Alguém me ajuda pelo amor de Deus. Depois de infinitas tentativas eu finalmente consegui compilar as sources do SERVIDOR, substitui o arquivo .exe que gerou e coloquei na pasta do server, liguei o server e tudo funcionou perfeitamente, mas quando eu entro no servidor o client tá todo bugado. Alguém sabe o que pode ser? Eu compilei as sources do servidor não a do client, não mexi nada no client. To usando como base o Pokemon HuatsonOT V2.0 (DXP).
  16. Base Pokemasterx, estou editando para um novo projeto, espero que gostem!
  17. helviio

    [OTC] Tema

    Olá estou convertendo um tema que ganhei do OtcV8 pra OTC ... porém estou tendo um trabalho enorme pra achar essa parte ... sei que é na pasta styles e tal ... porém ja deixei tudo igual nas pastas window/miniwindow/minimap ... se alguém puder me dar essa luz ficaria agradecido
  18. Eai galera do Xtibia hoje eu trago um module que desenvolvi para notificar o player caso ele esteja com o cliente desatualizado. Esse tutorial é para TFS 1.x, da pra usar em TFS 0.x mas terá que adaptar o código e ter OPCODES na sua source! Como instalar o module: 1 - Pegue a pasta do module e coloque na pasta mods do seu client. no arquivo module.lua você vai encontrar a seguinte linha: local VERSION = "1.0" nessa linha você define a versão atual do seu client, a cada novo client você modifica esse valor! 2 - Vá até a pasta creaturescripts/scripts do seu servidor e crie uma novo script chamado clientVersion.lua dentro desse script, cole o seguinte código: Em local VERSION = "1.0" você define a mesma versão que colocou no client, sempre que atualizar o client, deve alterar a variável VERSION desse script acima, do mesmo modo que altera no module do client. Em local MESSAGE = "..." você pode alterar a mensagem que será enviada ao player caso ele esteja com um cliente desatualizado. 3 - Em creaturescripts/creaturescripts.xml adicione a seguinte linha: <event type="extendedopcode" name="ClientVersion" script="clientVersion.lua" /> 4 - Agora no arquivo creaturescripts/login.lua registre esse evento antes de return true player:registerEvent("ClientVersion") Pronto, o module foi instalado! Print: Download
  19. KaboFlow

    OTClient Pra PDA

    alguem me ajude a adicionar o cliente a este banco de dados, por favor add OTCLIENT Pra base pda old
  20. Boa tarde galera, eu mostrei no meu showoff a tela do meu cliente, que pretendo liberar para a galera, porem, recebi mensagens de como fazer aquilo, e como eu vou postar o cliente com o module, resolvi fazer esse tutorial e liberar o module.. Esse module é para mudar a Game Window, para que não conhece, veja um print: Então, vou liberar o entergame já feito, e também vou ensinar como modificar. *Download no fim do topico*, vamos ao tutorial: Tenha em mente a imagem, e então, veja o tamanho dela, feito isso, va no entergame.lua e procure a linha que seta o IP do seu servidor, va está assim: EnterGame.setUniqueServer("127.0.0.1", 7877, 854, 361, 356) Vou explicar a linha toda para que entendam: 127.0.0.1 = IP do server 7877 = port do servidor, no meu caso ta 7877, porque é a porta Linnux. 854 = Versão do cliente/servidor. 361 = Tamanho da game window 356 = largura da game window em outras palavras, 361 e 356 é onde vamos modificar.. Você pega as dimensões da imagem, e coloca no lugar dos mesmos(361 e 356).. Feito isso, salve o entergame.lua e feche. Agora vamos editar a OTUI.. Abra o Entergame.otui e na primeira linha temos isso: EnterGameWindow < MainWindow !text: tr('Enter Game') size: 236 274 Bom, vamos modificar.. Retire essa linha: !text: tr('Enter Game') Nessa função modifique esse tamanho "236 274" para as dimensões da imagem *no caso seria (361 e 356): Antes: size: 236 274 Agora: size: 361 356 Adicione isto em baixo dessa função acima: image-source: enter.png *enter.png é a imagem que estamos usando para colocar no game window, a mesma que a gente pegou as dimensões e modificamos no entergame.lua*, *ela tem que está dentro da pasta onde se localiza o entergame.lua*. pronto, seu cliente já vai ler sua nova window com imagem. *Terá que mudar os lugares de onde coloca senha e conta* É bem simples, basta ir na OTUI e mudar os margin-top* DOWNLOAD ENTERGAME COM NOVA WINDOW: Download OBS: Deixei uns 3 Entergame dentro, se vocês quiserem usar como base, não me importo.. POR FAVOR, NÃO POSTE ESSE TUTORIAL EM OUTRO FÓRUM SEM OS DEVIDOS CRÉDITOS. FUNCIONA EM QUALQUER VERSÃO DO OTCLIENT. OBS: se vocês não souberem editar o entergame, irá bugar. É melhor baixar o que estou disponizilizando, e então mudar somente as dimensões..
  21. Olá a todos do xtibia gostaria da ajuda de alguem pra solucionar meu probleminha, estou editando um servidor de dragonball com src etc. So que tem um pequeno bug visual no meu otclient, quando eu solto um atk com effect distance fica esse bug agradeço desde já ?❤ PODEM FECHAR O TOPICO NÃO TEVE NEMHUMA RESPOSTA QUE PUDESE CORRIGIR O PROBLEMA ENTÃO EU RESOLVI DEIXAR OS EFFECTS EM UNIT8 PARA RESOLVER O PROBLEMA! OBRIGADO POR TENTAREM AJUDAR ❤️
  22. Gengo

    [OTClient] OTP Bank System

    Estava fazendo esse modulo e decidi postar, para quem quiser é um modulo de banco igual do OTPokemon, segue o demostrativo. OBS: Download contém apenas o módulo e não está completo.
  23. Eu baixei a ultima versão do OTClient, e no entergame.lua não esta aparecendo a linha que tinha nos anteriores. "function EnterGame.setUniqueServer(host, port, protocol, windowWidth, windowHeight)". Como faz para por IPFixo no otclientv8-master? EnterGame = { } -- private variables local loadBox local enterGame local enterGameButton local clientBox local protocolLogin local server = nil local versionsFound = false local customServerSelectorPanel local serverSelectorPanel local serverSelector local clientVersionSelector local serverHostTextEdit local rememberPasswordBox local protos = {"740", "760", "772", "792", "800", "810", "854", "860", "870", "961", "1000", "1077", "1090", "1096", "1098", "1099", "1100", "1200", "1220"} local checkedByUpdater = {} -- private functions local function onProtocolError(protocol, message, errorCode) if errorCode then return EnterGame.onError(message) end return EnterGame.onLoginError(message) end local function onSessionKey(protocol, sessionKey) G.sessionKey = sessionKey end local function onCharacterList(protocol, characters, account, otui) if rememberPasswordBox:isChecked() then local account = g_crypt.encrypt(G.account) local password = g_crypt.encrypt(G.password) g_settings.set('account', account) g_settings.set('password', password) else EnterGame.clearAccountFields() end for _, characterInfo in pairs(characters) do if characterInfo.previewState and characterInfo.previewState ~= PreviewState.Default then characterInfo.worldName = characterInfo.worldName .. ', Preview' end end if loadBox then loadBox:destroy() loadBox = nil end CharacterList.create(characters, account, otui) CharacterList.show() g_settings.save() end local function onUpdateNeeded(protocol, signature) return EnterGame.onError(tr('Your client needs updating, try redownloading it.')) end local function onProxyList(protocol, proxies) for _, proxy in ipairs(proxies) do g_proxy.addProxy(proxy["host"], proxy["port"], proxy["priority"]) end end local function parseFeatures(features) for feature_id, value in pairs(features) do if value == "1" or value == "true" or value == true then g_game.enableFeature(feature_id) else g_game.disableFeature(feature_id) end end end local function validateThings(things) local incorrectThings = "" local missingFiles = false local versionForMissingFiles = 0 if things ~= nil then local thingsNode = {} for thingtype, thingdata in pairs(things) do thingsNode[thingtype] = thingdata[1] if not g_resources.fileExists("/things/" .. thingdata[1]) then incorrectThings = incorrectThings .. "Missing file: " .. thingdata[1] .. "\n" missingFiles = true versionForMissingFiles = thingdata[1]:split("/")[1] else local localChecksum = g_resources.fileChecksum("/things/" .. thingdata[1]):lower() if localChecksum ~= thingdata[2]:lower() and #thingdata[2] > 1 then if g_resources.isLoadedFromArchive() then -- ignore checksum if it's test/debug version incorrectThings = incorrectThings .. "Invalid checksum of file: " .. thingdata[1] .. " (is " .. localChecksum .. ", should be " .. thingdata[2]:lower() .. ")\n" end end end end g_settings.setNode("things", thingsNode) else g_settings.setNode("things", {}) end if missingFiles then incorrectThings = incorrectThings .. "\nYou should open data/things and create directory " .. versionForMissingFiles .. ".\nIn this directory (data/things/" .. versionForMissingFiles .. ") you should put missing\nfiles (Tibia.dat and Tibia.spr) " .. "from correct Tibia version." end return incorrectThings end local function onTibia12HTTPResult(session, playdata) local characters = {} local worlds = {} local account = { status = 0, subStatus = 0, premDays = 0 } if session["status"] ~= "active" then account.status = 1 end if session["ispremium"] then account.subStatus = 1 -- premium end if session["premiumuntil"] > g_clock.seconds() then account.subStatus = math.floor((session["premiumuntil"] - g_clock.seconds()) / 86400) end local things = { data = {G.clientVersion .. "/Tibia.dat", ""}, sprites = {G.clientVersion .. "/Tibia.spr", ""}, } local incorrectThings = validateThings(things) if #incorrectThings > 0 then g_logger.error(incorrectThings) if Updater and not checkedByUpdater[G.clientVersion] then checkedByUpdater[G.clientVersion] = true return Updater.check({ version = G.clientVersion, host = G.host }) else return EnterGame.onError(incorrectThings) end end onSessionKey(nil, session["sessionkey"]) for _, world in pairs(playdata["worlds"]) do worlds[world.id] = { name = world.name, port = world.externalportunprotected or world.externalportprotected or world.externaladdress, address = world.externaladdressunprotected or world.externaladdressprotected or world.externalport } end for _, character in pairs(playdata["characters"]) do local world = worlds[character.worldid] if world then table.insert(characters, { name = character.name, worldName = world.name, worldIp = world.address, worldPort = world.port }) end end -- proxies if g_proxy then g_proxy.clear() if playdata["proxies"] then for i, proxy in ipairs(playdata["proxies"]) do g_proxy.addProxy(proxy["host"], tonumber(proxy["port"]), tonumber(proxy["priority"])) end end end g_game.setCustomProtocolVersion(0) g_game.chooseRsa(G.host) g_game.setClientVersion(G.clientVersion) g_game.setProtocolVersion(g_game.getClientProtocolVersion(G.clientVersion)) g_game.setCustomOs(-1) -- disable if not g_game.getFeature(GameExtendedOpcode) then g_game.setCustomOs(5) -- set os to windows if opcodes are disabled end onCharacterList(nil, characters, account, nil) end local function onHTTPResult(data, err) if err then return EnterGame.onError(err) end if data['error'] and data['error']:len() > 0 then return EnterGame.onLoginError(data['error']) elseif data['errorMessage'] and data['errorMessage']:len() > 0 then return EnterGame.onLoginError(data['errorMessage']) end if type(data["session"]) == "table" and type(data["playdata"]) == "table" then return onTibia12HTTPResult(data["session"], data["playdata"]) end local characters = data["characters"] local account = data["account"] local session = data["session"] local version = data["version"] local things = data["things"] local customProtocol = data["customProtocol"] local features = data["features"] local settings = data["settings"] local rsa = data["rsa"] local proxies = data["proxies"] local incorrectThings = validateThings(things) if #incorrectThings > 0 then g_logger.info(incorrectThings) return EnterGame.onError(incorrectThings) end -- custom protocol g_game.setCustomProtocolVersion(0) if customProtocol ~= nil then customProtocol = tonumber(customProtocol) if customProtocol ~= nil and customProtocol > 0 then g_game.setCustomProtocolVersion(customProtocol) end end -- force player settings if settings ~= nil then for option, value in pairs(settings) do modules.client_options.setOption(option, value, true) end end -- version G.clientVersion = version g_game.setClientVersion(version) g_game.setProtocolVersion(g_game.getClientProtocolVersion(version)) g_game.setCustomOs(-1) -- disable if rsa ~= nil then g_game.setRsa(rsa) end if features ~= nil then parseFeatures(features) end if session ~= nil and session:len() > 0 then onSessionKey(nil, session) end -- proxies if g_proxy then g_proxy.clear() if proxies then for i, proxy in ipairs(proxies) do g_proxy.addProxy(proxy["host"], tonumber(proxy["port"]), tonumber(proxy["priority"])) end end end onCharacterList(nil, characters, account, nil) end -- public functions function EnterGame.init() if USE_NEW_ENERGAME then return end enterGame = g_ui.displayUI('entergame') serverSelectorPanel = enterGame:getChildById('serverSelectorPanel') customServerSelectorPanel = enterGame:getChildById('customServerSelectorPanel') serverSelector = serverSelectorPanel:getChildById('serverSelector') rememberPasswordBox = enterGame:getChildById('rememberPasswordBox') serverHostTextEdit = customServerSelectorPanel:getChildById('serverHostTextEdit') clientVersionSelector = customServerSelectorPanel:getChildById('clientVersionSelector') if Servers ~= nil then for name,server in pairs(Servers) do serverSelector:addOption(name) end end if serverSelector:getOptionsCount() == 0 or ALLOW_CUSTOM_SERVERS then serverSelector:addOption(tr("Another")) end for i,proto in pairs(protos) do clientVersionSelector:addOption(proto) end if serverSelector:getOptionsCount() == 1 then enterGame:setHeight(enterGame:getHeight() - serverSelectorPanel:getHeight()) serverSelectorPanel:setOn(false) end local account = g_crypt.decrypt(g_settings.get('account')) local password = g_crypt.decrypt(g_settings.get('password')) local server = g_settings.get('server') local host = g_settings.get('host') local clientVersion = g_settings.get('client-version') if serverSelector:isOption(server) then serverSelector:setCurrentOption(server, false) if Servers == nil or Servers[server] == nil then serverHostTextEdit:setText(host) end clientVersionSelector:setOption(clientVersion) else server = "" host = "" end enterGame:getChildById('accountPasswordTextEdit'):setText(password) enterGame:getChildById('accountNameTextEdit'):setText(account) rememberPasswordBox:setChecked(#account > 0) g_keyboard.bindKeyDown('Ctrl+G', EnterGame.openWindow) if g_game.isOnline() then return EnterGame.hide() end scheduleEvent(function() EnterGame.show() end, 100) end function EnterGame.terminate() if not enterGame then return end g_keyboard.unbindKeyDown('Ctrl+G') enterGame:destroy() if loadBox then loadBox:destroy() loadBox = nil end if protocolLogin then protocolLogin:cancelLogin() protocolLogin = nil end EnterGame = nil end function EnterGame.show() if not enterGame then return end enterGame:show() enterGame:raise() enterGame:focus() enterGame:getChildById('accountNameTextEdit'):focus() end function EnterGame.hide() if not enterGame then return end enterGame:hide() end function EnterGame.openWindow() if g_game.isOnline() then CharacterList.show() elseif not g_game.isLogging() and not CharacterList.isVisible() then EnterGame.show() end end function EnterGame.clearAccountFields() enterGame:getChildById('accountNameTextEdit'):clearText() enterGame:getChildById('accountPasswordTextEdit'):clearText() enterGame:getChildById('accountTokenTextEdit'):clearText() enterGame:getChildById('accountNameTextEdit'):focus() g_settings.remove('account') g_settings.remove('password') end function EnterGame.onServerChange() server = serverSelector:getText() if server == tr("Another") then if not customServerSelectorPanel:isOn() then serverHostTextEdit:setText("") customServerSelectorPanel:setOn(true) enterGame:setHeight(enterGame:getHeight() + customServerSelectorPanel:getHeight()) end elseif customServerSelectorPanel:isOn() then enterGame:setHeight(enterGame:getHeight() - customServerSelectorPanel:getHeight()) customServerSelectorPanel:setOn(false) end if Servers and Servers[server] ~= nil then serverHostTextEdit:setText(Servers[server]) end end function EnterGame.doLogin() if g_game.isOnline() then local errorBox = displayErrorBox(tr('Login Error'), tr('Cannot login while already in game.')) connect(errorBox, { onOk = EnterGame.show }) return end G.account = enterGame:getChildById('accountNameTextEdit'):getText() G.password = enterGame:getChildById('accountPasswordTextEdit'):getText() G.authenticatorToken = enterGame:getChildById('accountTokenTextEdit'):getText() G.stayLogged = true G.server = serverSelector:getText():trim() G.host = serverHostTextEdit:getText() G.clientVersion = tonumber(clientVersionSelector:getText()) if not rememberPasswordBox:isChecked() then g_settings.set('account', G.account) g_settings.set('password', G.password) end g_settings.set('host', G.host) g_settings.set('server', G.server) g_settings.set('client-version', G.clientVersion) g_settings.save() local server_params = G.host:split(":") if G.host:lower():find("http") ~= nil then if #server_params >= 4 then G.host = server_params[1] .. ":" .. server_params[2] .. ":" .. server_params[3] G.clientVersion = tonumber(server_params[4]) elseif #server_params >= 3 then if tostring(tonumber(server_params[3])) == server_params[3] then G.host = server_params[1] .. ":" .. server_params[2] G.clientVersion = tonumber(server_params[3]) end end return EnterGame.doLoginHttp() end local server_ip = server_params[1] local server_port = 7171 if #server_params >= 2 then server_port = tonumber(server_params[2]) end if #server_params >= 3 then G.clientVersion = tonumber(server_params[3]) end if type(server_ip) ~= 'string' or server_ip:len() <= 3 or not server_port or not G.clientVersion then return EnterGame.onError("Invalid server, it should be in format IP:PORT or it should be http url to login script") end local things = { data = {G.clientVersion .. "/Tibia.dat", ""}, sprites = {G.clientVersion .. "/Tibia.spr", ""}, } local incorrectThings = validateThings(things) if #incorrectThings > 0 then g_logger.error(incorrectThings) if Updater and not checkedByUpdater[G.clientVersion] then checkedByUpdater[G.clientVersion] = true return Updater.check({ version = G.clientVersion, host = G.host }) else return EnterGame.onError(incorrectThings) end end protocolLogin = ProtocolLogin.create() protocolLogin.onLoginError = onProtocolError protocolLogin.onSessionKey = onSessionKey protocolLogin.onCharacterList = onCharacterList protocolLogin.onUpdateNeeded = onUpdateNeeded protocolLogin.onProxyList = onProxyList EnterGame.hide() loadBox = displayCancelBox(tr('Please wait'), tr('Connecting to login server...')) connect(loadBox, { onCancel = function(msgbox) loadBox = nil protocolLogin:cancelLogin() EnterGame.show() end }) if G.clientVersion == 1000 then -- some people don't understand that tibia 10 uses 1100 protocol G.clientVersion = 1100 end -- if you have custom rsa or protocol edit it here g_game.setClientVersion(G.clientVersion) g_game.setProtocolVersion(g_game.getClientProtocolVersion(G.clientVersion)) g_game.setCustomProtocolVersion(0) g_game.setCustomOs(-1) -- disable g_game.chooseRsa(G.host) if #server_params <= 3 and not g_game.getFeature(GameExtendedOpcode) then g_game.setCustomOs(2) -- set os to windows if opcodes are disabled end -- extra features from init.lua for i = 4, #server_params do g_game.enableFeature(tonumber(server_params[i])) end -- proxies if g_proxy then g_proxy.clear() end if modules.game_things.isLoaded() then g_logger.info("Connecting to: " .. server_ip .. ":" .. server_port) protocolLogin:login(server_ip, server_port, G.account, G.password, G.authenticatorToken, G.stayLogged) else loadBox:destroy() loadBox = nil EnterGame.show() end end function EnterGame.doLoginHttp() if G.host == nil or G.host:len() < 10 then return EnterGame.onError("Invalid server url: " .. G.host) end loadBox = displayCancelBox(tr('Please wait'), tr('Connecting to login server...')) connect(loadBox, { onCancel = function(msgbox) loadBox = nil EnterGame.show() end }) local data = { type = "login", account = G.account, accountname = G.account, email = G.account, password = G.password, accountpassword = G.password, token = G.authenticatorToken, version = APP_VERSION, uid = G.UUID, stayloggedin = true } HTTP.postJSON(G.host, data, onHTTPResult) EnterGame.hide() end function EnterGame.onError(err) if loadBox then loadBox:destroy() loadBox = nil end local errorBox = displayErrorBox(tr('Login Error'), err) errorBox.onOk = EnterGame.show end function EnterGame.onLoginError(err) if loadBox then loadBox:destroy() loadBox = nil end local errorBox = displayErrorBox(tr('Login Error'), err) errorBox.onOk = EnterGame.show if err:lower():find("invalid") or err:lower():find("not correct") or err:lower():find("or password") then EnterGame.clearAccountFields() end end
  24. [OTClient] Sistema de Dialogo Otpokemon Venho através desse tópico contribuir para a comunidade, um simples modulo de dialogo no estilo do Otpokemon, não é um sistema de dialogo avançado é algo simples que deixa seu servidor intuitivo. 1) Faça o download do modulo no qual se encontra no final do tópico e abrindo a pasta do seu client, extraia e coloque o modulo na pasta modules. 2) O módulo utiliza uma função chamada switch que não é comum ter no otclient, porem podemos colocar sem muito esforço, na pasta do otclient abra o arquivo util.lua que se encontra em modules/corelib/ e no final do arquivo coloque o seguinte código: Feito o passo 1 e 2, vamos para a parte do servidor. 1) Crie um arquivo na pasta data/lib/ podendo ter o nome de npcdialog_lib.lua e coloque o seguinte código: 2) O arquivo que acabamos de criar utiliza uma função chamada table.serialize que não é comum ter nos servidores, para que funcione sem erros vamos adicionar, abra o arquivo 012-table.lua que fica na pasta do seu servidor em data/lib/ ou você pode criar o arquivo e adicionar o seguinte código: Feito todo esse procedimento, estarei disponibilizando um npc para que vocês possam ter uma noção de como utilizar esse sistema de dialogo. 1) Crie um arquivo na pasta do servidor em data/npc/ chamado Gengo.xml e adicione o seguinte código: 2) Crie um arquivo na pasta do servidor em data/npc/lib/ com o nome gengo.lua e adicione o seguinte código: O npc é algo simples, porem serve para que você possa ter uma noção de como utilizar as funções do npc. Demostrativo dentro do game: Arquivos para download e o scan:
  25. Olá xTibia Hoje Trago pra vocês um pack de Client Wodbo Explorer Descompilado atual ano 2019 ( Não tenho certeza disso, eu nao lembro mais. deixei que minha notebook guardava mais o clientes.) Espero que vocês gostam. https://www.mediafire.com/file/zqnt30azbuvi1wc/WODBOExplorer.zip/file Imagens Pack Client Wodbo Explorer Creditos: Mask Ghost ( Descompilador Client's Pack ) Scan: https://www.virustotal.com/gui/file/d6fa20a70c9e6578d55f0cccbda9888f6846fcf1faa4f8744d7d2089ed022cda/detection Não postem em outros fórum sem a minha permissão. é isto bom aprveito a todos. 2020 - Bom Dia.
×
×
  • Criar Novo...