Ir para conteúdo

Celulose

Membro
  • Registro em

  • Última visita

Tudo que Celulose postou

  1. algo bem simples porém funcional kk @Spooky Ghost se tu deixar em login.lua não vai mandar a mensagem precisa ser feito a verificação dentro do script local channels = { [4] = {txt = "(Game-Chat) Este canal é apenas para CONVERSAS CASUAIS e SOCIALIZAÇÃO. Negociações e spam/flood são proibidas neste canal, respeito e educação são essenciais. Siga as regras para não ser mutado"}, -- GameChat [5] = {txt = "(TRADE) Este canal é apenas para TROCAS de itens relacionados ao jogo. Qualquer coisa além disso pode ocasionar um mute ou banimento."}, -- Trade [9] = {txt = "(HELP) Este canal é apenas para AJUDA, Faça sua pergunta educadamente, ou se você estiver respondendo uma dúvida, seja claro e objetivo. Falta de educação você será mutado ou ate mesmo banido!"}, -- Help [12] = {txt = "(LOOT) Este canal vai lhe mostrar o loot dos monstros que você matou."}, -- loot channel [11] = {txt = "(COOLDOWN) Este canal vai lhe mostrar o cooldown(tempo de espera) de seus Jutsus Especiais(Combo)."}, -- loot channel } function onJoinChannel(cid, channelId, users) local t = channels[channelId] if t then addEvent(doPlayerSendChannelMessage, 150, cid, "", t.txt, TALKTYPE_CHANNEL_O, channelId) end return true end function onLogin(cid) doPlayerOpenChannel(cid, 4) doPlayerOpenChannel(cid, 5) doPlayerOpenChannel(cid, 9) doPlayerOpenChannel(cid, 12) doPlayerOpenChannel(cid, 11) return true end <event type="joinchannel" name="OpenChannelDialog" script="msg.lua"/> <event type="login" name="OpenChannelDialog" script="msg.lua"/> login.lua : registerCreatureEvent(cid, "OpenChannelDialog") PS: não pode ter doPlayerOpenChannel no login.lua ! otx : local channels = { [4] = {txt = "(Game-Chat) Este canal é apenas para CONVERSAS CASUAIS e SOCIALIZAÇÃO. Negociações e spam/flood são proibidas neste canal, respeito e educação são essenciais. Siga as regras para não ser mutado"}, -- GameChat [5] = {txt = "(TRADE) Este canal é apenas para TROCAS de itens relacionados ao jogo. Qualquer coisa além disso pode ocasionar um mute ou banimento."}, -- Trade [9] = {txt = "(HELP) Este canal é apenas para AJUDA, Faça sua pergunta educadamente, ou se você estiver respondendo uma dúvida, seja claro e objetivo. Falta de educação você será mutado ou ate mesmo banido!"}, -- Help [12] = {txt = "(LOOT) Este canal vai lhe mostrar o loot dos monstros que você matou."}, -- loot channel [11] = {txt = "(COOLDOWN) Este canal vai lhe mostrar o cooldown(tempo de espera) de seus Jutsus Especiais(Combo)."}, -- loot channel } function onChannelJoin(cid, channelId, users) local t = channels[channelId] if t then addEvent(doPlayerSendChannelMessage, 150, cid, "", t.txt, TALKTYPE_CHANNEL_O, channelId) end return true end function onLogin(cid) doPlayerOpenChannel(cid, 4) doPlayerOpenChannel(cid, 5) doPlayerOpenChannel(cid, 9) doPlayerOpenChannel(cid, 12) doPlayerOpenChannel(cid, 11) return true end <event type="login" name="OpenChannelDialog" script="msg.lua"/> <event type="channeljoin" name="OpenChannelDialog" script="msg.lua"/> login.lua: registerCreatureEvent(cid, "OpenChannelDialog") PS: não pode ter doPlayerOpenChannel no login.lua !
  2. <defense name="healing" interval="9000" chance="11" min="700" max="999">
  3. https://tibiaking.com/forums/topic/73679-036-fun%C3%A7%C3%A3o-doplayeropenchannel/
  4. isso é uma dll, você está no char de adm né? geralmente isso que acontece.
  5. @Guilherme HP transformar.lua sobre o vocation em fromvoc você deve deixar igual está em vocation id=" exemplo vocation id="893" deixa fromvoc="893" antes era vocation id="893" / fromvoc="892"
  6. @Guilherme HP ---------- Darui ----------- [885] = { 50, 886, 2011, 13}, [886] = { 100, 887, 2012, 13}, [887] = { 150, 888, 2013, 13}, [888] = { 200, 889, 2014, 13}, [889] = { 250, 890, 2015, 13}, [890] = { 300, 891, 2016, 13}, [891] = { 400, 892, 2017, 13}, [892] = { 500, 893, 2018, 13} unica coisa errada é a virgula nesse script e questão do <vocation id="893" name="Darui" description="Darui" needpremium="0" gaincap="15" gainhp="380" gainmana="380" gainhpticks="2" gainhpamount="100" gainmanaticks="2" gainmanaamount="100" manamultiplier="1.1" attackspeed="500" soulmax="250" gainsoulticks="15" fromvoc="892"> porque seu fromvoc é sempre 1 antes ?
  7. a 2 anos atrás quando usava "TFS" Acontecia isso comigo não faço minima ideia como eu corrigi na época. Mais isso ocorre dessa maneira aqui. Quando tu usar um comando, npc, ou algo que te da skill, ele buga fazendo seu skill ir ao um valor bem grande exemplo: você vai ao um npc e fala hi skill sword yes, tu compra 10 de skill de sword ele buga em algumas tfs .... para tu corrigir isso de cair é só limitar um valor em cada skill e assim quando passa-se esse valor o char não da dano em nada . agora para corrigir isso de aumentar a skill e ir valores alto não sei te ajudar ;/ PS : Isso de mudar de vocation é por causa ta caindo o servidor, vocÊ está dando hit muito alto assim cai o game. se fazer oque falei de limitar um exemplo 250 não vai cair o game pois não vai da dano.
  8. não tem a db com nome "wodbo"
  9. setCombatParam(combat1, COMBAT_PARAM_HITCOLOR, COLOR_BLUE) exemplo : local combat1 = createCombatObject() setCombatParam(combat1, COMBAT_PARAM_HITCOLOR, COLOR_BLUE) setCombatParam(combat1, COMBAT_PARAM_TYPE, COMBAT_PHYSICALDAMAGE) setCombatParam(combat1, COMBAT_PARAM_EFFECT, 38) setCombatParam(combat1, COMBAT_PARAM_DISTANCEEFFECT, 59) setCombatFormula(combat1, COMBAT_FORMULA_LEVELMAGIC, -250.0, 0, -275.0, 0) local function onCastSpell1(parameters) doCombat(parameters.cid, parameters.combat1, parameters.var) end function onCastSpell(cid, var) local parameters = { cid = cid, var = var, combat1 = combat1 } addEvent(onCastSpell1, 0, parameters) return true end
  10. @cabrera2608 delay...
  11. Pra quem quiser ativar pela config.lua bool Game::playerMove(uint32_t playerId, Direction dir) { Player* player = getPlayerByID(playerId); if(!player || player->isRemoved()) return false; player->setIdleTime(0); if(player->getNoMove()) { player->sendCancelWalk(); return false; } std::list<Direction> dirs; dirs.push_back(dir); if(g_config.getBool(ConfigManager::PUSH_CRUZADO)) { player->startAutoWalk(dirs); } else { player->setNextWalkActionTask(NULL); player->startAutoWalk(dirs); } return true; } configmanager.cpp m_confBool[PUSH_CRUZADO] = getGlobalBool("PushCruzado", true); configmanager.h PUSH_CRUZADO, Conf.lua PushCruzado = true @WooX quiser atualizar bb
  12. SET GLOBAL max_allowed_packet = 16776192; @zLockey9 ALTER TABLE `accounts` ADD `creation` INT NOT NULL DEFAULT 0 AFTER `email`;
  13. Mysql> ALTER TABLE `killers` ADD `war` INT(11) NOT NULL DEFAULT 0;
  14. Boa noite Posta o script.. ou você mesmo pode fazer isso setando uma storage igual nós 2 script..
  15. --[[ Script by Bruno Minervino para o Tibia King Caso for postar, colocar os créditos ]] local config = { tempo = 10, --tempo em segundos mensagem = { texto = "[TOP]", --não use mais de 9 caracteres efeito = TEXTCOLOR_LIGHTBLUE --efeito para a função doSendAnimatedText }, efeito = 30, --efeito da função doSendMagicEffect globalstr = 5687 -- uma global storage qualquer q esteje vazia } --[[ Não mexa em nada abaixo ]] local topPlayer = getGlobalStorageValue(config.globalstr) > 0 and getGlobalStorageValue(config.globalstr) or 0 function onLogin(cid) local query = db.getResult("SELECT `id`, `name`, `level` FROM `players` WHERE `group_id` < 2 ORDER BY `level` DESC LIMIT 13") if (query:getID() ~= -1) then local pid = query:getDataString("id") local name = query:getDataString("name") if getPlayerName(cid) == name then if topPlayer ~= getPlayerID(cid) then topPlayer = getPlayerID(cid) end setGlobalStorageValue(config.globalstr, pid) TopEffect(cid) end end registerCreatureEvent(cid, "CheckTop") return true end function onAdvance(cid, skill, oldlevel, newlevel) if skill == 8 then local query = db.getResult("SELECT `id`, `name`, `level` FROM `players` WHERE `group_id` < 2 ORDER BY `level` DESC LIMIT 13") if (query:getID() ~= -1) then local level = tonumber(query:getDataString("level")) if level < newlevel and topPlayer ~= getPlayerID(cid) then doBroadcastMessage("O jogador " .. getPlayerName(cid) .. " tornou-se o novo Top Level. Parabens!", 22) topPlayer = getPlayerID(cid) doSaveServer() setGlobalStorageValue(config.globalstr, getPlayerID(cid)) TopEffect(cid) end end end return true end function TopEffect(cid) if not isPlayer(cid) then return true end if topPlayer == getPlayerID(cid) then doSendAnimatedText(getCreaturePosition(cid), config.mensagem.texto, config.mensagem.efeito) doSendMagicEffect(getCreaturePosition(cid), config.efeito) addEvent(TopEffect, config.tempo * 1000, cid) end end function getPlayerNameById(id) local query = db.getResult("SELECT `name` FROM `players` WHERE `id` = " .. db.escapeString(id)) if query:getID() ~= -1 then return query:getDataString("name") end return 0 end function getPlayerIdByName(name) local query = db.getResult("SELECT `id` FROM `players` WHERE `name` = " .. db.escapeString(name)) if query:getID() ~= -1 then return tonumber(query:getDataString("id")) end return 0 end function getPlayerID(cid) return getPlayerIdByName(getPlayerName(cid)) end
  16. @ITALOx posso @ITALOx manda ip e porta e se quer com effect
  17. Qual versão do client ? fala o ip e a porta que crio aqui, quer ele extended ?
  18. @kido omega local combat = createCombatObject() setCombatParam(combat, COMBAT_PARAM_BLOCKARMOR, 1) setCombatParam(combat, COMBAT_PARAM_BLOCKSHIELD, 1) setCombatParam(combat, COMBAT_PARAM_TYPE, COMBAT_FIREDAMAGE) setCombatFormula(combat, COMBAT_FORMULA_SKILL, 1, 0, 1, 0) local area = createCombatArea({ {0, 0, 0}, {0, 3, 0}, {0, 0, 0} }) setCombatArea(combat, area) function onUseWeapon(cid, var) local target = getThingPosition(getCreatureTarget(cid)) local pos = {x=target.x+0, y=target.y+0, z=target.z+0} doSendMagicEffect(pos, 136) local NumberOfHits = 1 local value = getCreatureMaxMana(target2)*0.20 -- 0.20 representa a 20% da mana total do seu target local restoremana = "false" for x=1,NumberOfHits do if isPlayer(target) then doCreatureAddMana(target, -value) if restoremana == "true" then doCreatureAddMana(cid, value) end end end return doCombat(cid, combat, var) end
  19. @kido omega local combat = createCombatObject() setCombatParam(combat, COMBAT_PARAM_BLOCKARMOR, 1) setCombatParam(combat, COMBAT_PARAM_BLOCKSHIELD, 1) setCombatParam(combat, COMBAT_PARAM_TYPE, COMBAT_FIREDAMAGE) setCombatFormula(combat, COMBAT_FORMULA_SKILL, 1, 0, 1, 0) local area = createCombatArea({ {0, 0, 0}, {0, 3, 0}, {0, 0, 0} }) setCombatArea(combat, area) function onUseWeapon(cid, var) local target = getThingPosition(getCreatureTarget(cid)) local pos = {x=target.x+0, y=target.y+0, z=target.z+0} doSendMagicEffect(pos, 136) local target2 = getCreatureTarget(cid) local NumberOfHits = 1 local value = getCreatureMaxMana(target2)*0.20 -- 0.20 representa a 20% da mana total do seu target local restoremana = "false" if isMonster(target2)then return false end for x=1,NumberOfHits do if isPlayer(target) then doCreatureAddMana(target, -value) if restoremana == "true" then doCreatureAddMana(cid, value) end end end return doCombat(cid, combat, var) end
  20. Celulose postou uma resposta no tópico em Suporte Tibia OTServer
    timeBetweenActions = 0 timeBetweenExActions = 200 timeBetweenCustomActions = 0 porém, com essa mudança aconselho você seta uma storage em cada actions
  21. abre o phpmyadmin e faz o procedimento caso usa sql mesma coisa
  22. SET GLOBAL max_allowed_packet = 16776192; adiciona na database em SQL
  23. @bpm91 seria um tempo para todos ? ou seria um tempo por player ?

Informação Importante

Confirmação de Termo