Líderes
Conteúdo Popular
Exibindo conteúdo com a maior reputação em 03/19/16 em todas áreas
-
local pokenamesom = getItemAttribute(item.uid, "poke") addEvent(sendScreanSound, 3000, cid, ""..pokenamesom..".mp3") Ou local pokenamesom = getItemAttribute(item.uid, "poke") addEvent(sendScreanSound, 300, cid, ""..pokenamesom..".mp3") Esqueci quandos MS são 1S, desculpa2 pontos
-
Fala galera, tudo bem? Bom, estou trazendo aqui um sisteminha de double exp e double loot system que fiz sob encomenda só que acabaram fazendo por conta própria e desistindo de comprar o que me encomendaram, então estou divulgando aqui para vocês o sistema completo já que não tem mais nenhum termo de privacidade e é um sisteminha legal de se usar para diversas coisas (quests, itens especiais, etc). O nome é bem auto-explicativo, o sistema aumenta a rate de exp e loot daquele cidadão por um período X de tempo. Scripts: http://pastebin.com/Wc9ZL8Km É bastante auto-explicativo o código acima, pois já coloquei no pastebin com os devidos comentários e com os passos a serem seguidos. Leiam tudo pois são 3 arquivos e 1 modificação no login.lua. A forma como está feita ali é um item (a ser definido por você na tag) que você clica e habilita o bonus ao player. A rate de exp e loot são customizáveis tal qual o tempo de duração do bônus. Espero que gostem. Abraços,1 ponto
-
Servidor 10.90 | Windows 32/64 Bits | Versão Final
LeonxD reagiu a Marco Oliveira por um tópico no fórum
Depois de muitos pedidos e muita procura acabei compilando o TFS da versão 10.90, está estável. As sources são originais, não houve modificações nelas, apenas os sistemas foram adicionados... Clique Aqui para fazer o download da versão 32 bits. Clique Aqui para fazer o download da versão 64 bits. Clique Aqui para fazer o download das sources. Clique aqui para fazer o download do gesior funcional. Clique Aqui para o scan de 32 bits. Clique Aqui para o scan de 64 bits. Clique Aqui para o scan das sources. Para usar o Reward Chest adicione a seguinte flag no monstro. <flag rewardchest="1" / Você também pode definir o drop para ser único, dessa forma só a pessoa que fez o maior dano irá obter este item. exemplo: <item id="5903" chance="100000" uniquedrop="1" /><!-- ferumbras' hat --> Na versão final foram corrigidos os bugs das mensagens do Server Log como as de potion e loot. Seguem as screen shots.. PS: Eu autorizo postar em outro fórum, porem este conteúdo é oficialmente do XTibia, então coloque meus créditos e o link do fórum oficial.1 ponto -
[TFS 0.3.6] Player::canWalkthrough
Scizorgame reagiu a Lordbaxx por um tópico no fórum
Bom muita gente procura esse código, e ao olhar na internet só vi disponível em um fórum porém incompleto então decidi pegar o código e postá-lo com oque faltava. Esse código é utilizado para que um player passe por outro player evitando tantas reclamações por "trapar" caminho ou algo parecido, vamos lá! Ah mais uma coisa, para funcionar é preciso que o servidor esteja em NON-PVP. OBS: Testado em tfs 0.3.6 somente! Player.cpp procure por: bool Player::canWalkthrough(const Creature* creature) const Substitua todo o código por: bool Player::canWalkthrough(const Creature* creature) const { if(creature == this || hasCustomFlag(PlayerCustomFlag_CanWalkthrough) || creature->isWalkable() || (creature->getMaster() && creature->getMaster() != this && canWalkthrough(creature->getMaster()))) return true; const Player* player = creature->getPlayer(); if(!player) return false; if((((g_game.getWorldType() == WORLD_TYPE_NO_PVP && player->getVocation()->isAttackable()) || player->getTile()->hasFlag(TILESTATE_PROTECTIONZONE) || (player->getVocation()->isAttackable() && player->getLevel() < (uint32_t)g_config.getNumber(ConfigManager::PROTECTION_LEVEL))) && player->getTile()->ground) && (!player->hasCustomFlag(PlayerCustomFlag_GamemasterPrivileges) || player->getAccess() <= getAccess())) return true; return (player->isGhost() && getGhostAccess() < player->getGhostAccess()) || (isGhost() && getGhostAccess() > player->getGhostAccess()); } Depois vá em const.h e procure por: PlayerCustomFlag_CanWearAllAddons, //2^23 = 8388608 E em baixo coloque: PlayerCustomFlag_IsWalkable, //2^24 = 16777216 PlayerCustomFlag_CanWalkthrough, //2^25 = 33554433 Provavelmente em muitas sources do tfs 0.3.6, dê não exatamente um erro mais um aviso no player.cpp na função: void Player::updateInventoryWeight() Se o aviso ocorrer substitua a função citada acima por essa: void Player::updateInventoryWeight() { inventoryWeight = 0.00; if(!hasFlag(PlayerFlag_HasInfiniteCapacity)){ for(int i = SLOT_FIRST; i < SLOT_LAST; ++i){ Item* item = getInventoryItem((slots_t)i); if(item){ inventoryWeight += item->getWeight(); } } } } Só utilize o código acima se ocorrer o "warning/aviso" sobre a função. Abraço. Os créditos ficam até o momento só ao Bruno Minervino e a fireelement. Qualquer outro envolvido será creditado.1 ponto -
Global Full [CLIENTS COMPATÍVEIS] 10 e 11.5. [BUGS E DOWNLOAD] BAIXEM E REPORTEM EM: OTXGlobal Full [FEATURES] NEW DEPOT, NEW SPAWN, NEW CAST SYSTEM, NEW NPC SYSTEM VIA BANK BALANCE, NEW CRITICAL BOOST SYSTEM, NEW POTIONS, REWARD SYSTEM, PREY ... [MAPA] FULL GLOBAL MAP WITH FEYRIST TODAS CIDADES E NOVAS AREAS TODAS QUESTS FUNCIONANDO! [EVENTS] WAR-ANTIENTROSA [CONTATO] SKYPE: onjogos WHATSAPP: (66) 998427-4493 [Créditos]Tfs 1.2 Developers -Zbizu - Pitis91 - MatheusMkalo - Gesior - Lundrial - M4G0 - Fish04k - Printer - Djarek - Ninjalulz - Slavidodo - Thexamx - Socket2810 - Ciroc -Absolute - Gordonbay - Mitsuig - Alissonfgp - Gunz - Bruno Minervino - Comedinha -Hirako - Maya - Mattyx14 – Darkjav - Viking Tibia1 ponto
-
Chamar uma função ao soltar determinado pokemon da ball
Developer Berg reagiu a Refe por uma questão
local EFFECTS = { --[OutfitID] = {Effect} ["Magmar"] = 35, ["Magmortar"] = 35, ["Shiny Magmar"] = 35, ["Jynx"] = 17, --alterado v2.5 ["Shiny Jynx"] = 17, ["Mamoswine"] = 205, ["Piloswine"] = 205, --alterado v2.8 ["Swinub"] = 205, } function onUse(cid, item, frompos, item2, topos) if getPlayerStorageValue(cid,130130) >= 1 then doPlayerSendTextMessage(cid, 19, "Nao Pode Dar Goback Nessa Area.") return true end if exhaustion.get(cid, 6666) and exhaustion.get(cid, 6666) > 0 then return true end if getPlayerStorageValue(cid, 17000) >= 1 or getPlayerStorageValue(cid, 17001) >= 1 or getPlayerStorageValue(cid, 63215) >= 1 or getPlayerStorageValue(cid, 75846) >= 1 or getPlayerStorageValue(cid, 5700) >= 1 then --alterado v2.9 << return true end local ballName = getItemAttribute(item.uid, "poke") local btype = getPokeballType(item.itemid) local usando = pokeballs[btype].use local effect = pokeballs[btype].effect if not effect then effect = 21 end unLock(item.uid) --alterado v2.8 if item.itemid == usando then --if getPlayerGroupId == 8 then --doPlayerSendTextMessage(cid, 19, "TESTS 1!") --setPlayerGroupId(cid,1) --return true --end if getPlayerStorageValue(cid, 990) == 1 then -- GYM doPlayerSendCancel(cid, "You can't return your pokemon during gym battles.") return true end if #getCreatureSummons(cid) > 1 and getPlayerStorageValue(cid, 212124) <= 0 then --alterado v2.6 if getPlayerStorageValue(cid, 637501) == -2 or getPlayerStorageValue(cid, 637501) >= 1 then BackTeam(cid) end end if #getCreatureSummons(cid) == 2 and getPlayerStorageValue(cid, 212124) >= 1 then doPlayerSendCancel(cid, "You can't do that while is controling a mind") return true --alterado v2.5 end if #getCreatureSummons(cid) <= 0 then if isInArray(pokeballs[btype].all, item.itemid) then doTransformItem(item.uid, pokeballs[btype].on) doItemSetAttribute(item.uid, "hp", 1) --setPlayerGroupId(cid,1) doPlayerSendCancel(cid, "[Ball-Desbloqueado] Balls Desbloqueado com Sucesso!") doPlayerSendTextMessage(cid, 21, "[Ball-Desbloqueado] Balls Desbloqueado com Sucesso!") doSendMagicEffect(getThingPos(cid), 29) doSendAnimatedText(getCreaturePosition(cid),"Unlock",math.random(1,255)) return true end end local cd = getCD(item.uid, "blink", 30) if cd > 0 then setCD(item.uid, "blink", 0) end local z = getCreatureSummons(cid)[1] if getCreatureCondition(z, CONDITION_INVISIBLE) and not isGhostPokemon(z) then return true end doReturnPokemon(cid, z, item, effect) sendScreanSound(cid, "Back Poke.mp3") elseif item.itemid == pokeballs[btype].on then --doPlayerSendTextMessage(cid, 19, "TESTS 3!") --setPlayerGroupId(cid,8) if item.uid ~= getPlayerSlotItem(cid, CONST_SLOT_FEET).uid then doPlayerSendCancel(cid, "You must put your pokeball in the correct place!") return TRUE end local thishp = getItemAttribute(item.uid, "hp") if thishp <= 0 then if isInArray(pokeballs[btype].all, item.itemid) then doTransformItem(item.uid, pokeballs[btype].off) doItemSetAttribute(item.uid, "hp", 0) doPlayerSendCancel(cid, "This pokemon is fainted.") return true end end local pokemon = getItemAttribute(item.uid, "poke") if not pokes[pokemon] then return true end ----------------------- Sistema de nao poder carregar mais que 3 pokes lvl baixo e + q 1 poke de lvl medio/alto --------------------------------- if not isInArray({5, 6}, getPlayerGroupId(cid)) then --alterado v2.9 \/ local balls = getPokeballsInContainer(getPlayerSlotItem(cid, 3).uid) local low = {} local lowPokes = {"Rattata", "Caterpie", "Weedle", "Oddish", "Pidgey", "Paras", "Poliwag", "Bellsprout", "Magikarp", "Hoppip", "Sunkern"} if #balls >= 1 then for _, uid in ipairs(balls) do local nome = getItemAttribute(uid, "poke") if not isInArray(lowPokes, pokemon) and nome == pokemon then return doPlayerSendTextMessage(cid, 27, "Sorry, but you can't carry two pokemons equals!") else if nome == pokemon then table.insert(low, nome) end end end end if #low >= 3 then return doPlayerSendTextMessage(cid, 27, "Sorry, but you can't carry more than three pokemons equals of low level!") end end --------------------------------------------------------------------------------------------------------------------------------------------------- local x = pokes[pokemon] local boosts = getItemAttribute(item.uid, "boost") or 0 if getPlayerLevel(cid) + pokemonMaxLevelAbovePlayer < getItemAttribute(item.uid, "level") + boosts then doPlayerSendCancel(cid, "Your pokemon's level is much higher than yours, you can't use him.") return true end doSummonMonster(cid, pokemon) local pk = getCreatureSummons(cid)[1] if not isCreature(pk) then return true end ------------------------passiva hitmonchan------------------------------ if isSummon(pk) then --alterado v2.8 \/ if pokemon == "Shiny Hitmonchan" or pokemon == "Hitmonchan" then if not getItemAttribute(item.uid, "hands") then doSetItemAttribute(item.uid, "hands", 0) end local hands = getItemAttribute(item.uid, "hands") doSetCreatureOutfit(pk, {lookType = hitmonchans[pokemon][hands].out}, -1) end end ------------------------------------------------------------------------- ---------movement magmar, jynx------------- if EFFECTS[getCreatureName(pk)] then markPosEff(pk, getThingPos(pk)) sendMovementEffect(pk, EFFECTS[getCreatureName(pk)], getThingPos(pk)) --alterado v2.5 end -------------------------------------------------------------------------- if getCreatureName(pk) == "Ditto" then local left = getItemAttribute(item.uid, "transLeft") local name = getItemAttribute(item.uid, "transName") if left and left > 0 then setPlayerStorageValue(pk, 1010, name) doSetCreatureOutfit(pk, {lookType = getItemAttribute(item.uid, "transOutfit")}, -1) addEvent(deTransform, left * 1000, pk, getItemAttribute(item.uid, "transTurn")) doItemSetAttribute(item.uid, "transBegin", os.clock()) else setPlayerStorageValue(pk, 1010, "Ditto") end end if isGhostPokemon(pk) then doTeleportThing(pk, getPosByDir(getThingPos(cid), math.random(0, 7)), false) end doCreatureSetLookDir(pk, 2) adjustStatus(pk, item.uid, true, false, true) doAddPokemonInOwnList(cid, pokemon) doTransformItem(item.uid, item.itemid+1) local pokename = getPokeName(pk) --alterado v2.7 local mgo = gobackmsgs[math.random(1, #gobackmsgs)].go:gsub("doka", pokename) doCreatureSay(cid, mgo, TALKTYPE_SAY) doSendMagicEffect(getCreaturePosition(pk), effect) sendScreanSound(cid, "Go Poke.mp3") local pk = getCreatureSummons(cid)[1] local pb = getPlayerSlotItem(cid, 8).uid local look = getItemAttribute(pb,"addon") if not look then doSetItemAttribute(pb,"addon",0) elseif look > 0 then doSetCreatureOutfit(pk, {lookType = look}, -1) end --if useOTClient then -- para aticar bar spell -- doPlayerSendCancel(cid, '12//,show') --alterado v2.7 -- end -- local pk = getCreatureSummons(cid)[1] local pokenamesom = getItemAttribute(item.uid, "poke") addEvent(sendScreanSound, 3, cid, ""..pokenamesom..".mp3") else doPlayerSendCancel(cid, "This pokemon is fainted.") end if useKpdoDlls then doUpdateMoves(cid) end return true end1 ponto -
Chamar uma função ao soltar determinado pokemon da ball
Developer Berg reagiu a Refe por uma questão
local EFFECTS = { --[OutfitID] = {Effect} ["Magmar"] = 35, ["Magmortar"] = 35, ["Shiny Magmar"] = 35, ["Jynx"] = 17, --alterado v2.5 ["Shiny Jynx"] = 17, ["Mamoswine"] = 205, ["Piloswine"] = 205, --alterado v2.8 ["Swinub"] = 205, } function onUse(cid, item, frompos, item2, topos) if getPlayerStorageValue(cid,130130) >= 1 then doPlayerSendTextMessage(cid, 19, "Nao Pode Dar Goback Nessa Area.") return true end if exhaustion.get(cid, 6666) and exhaustion.get(cid, 6666) > 0 then return true end if getPlayerStorageValue(cid, 17000) >= 1 or getPlayerStorageValue(cid, 17001) >= 1 or getPlayerStorageValue(cid, 63215) >= 1 or getPlayerStorageValue(cid, 75846) >= 1 or getPlayerStorageValue(cid, 5700) >= 1 then --alterado v2.9 << return true end local ballName = getItemAttribute(item.uid, "poke") local btype = getPokeballType(item.itemid) local usando = pokeballs[btype].use local effect = pokeballs[btype].effect if not effect then effect = 21 end unLock(item.uid) --alterado v2.8 if item.itemid == usando then --if getPlayerGroupId == 8 then --doPlayerSendTextMessage(cid, 19, "TESTS 1!") --setPlayerGroupId(cid,1) --return true --end if getPlayerStorageValue(cid, 990) == 1 then -- GYM doPlayerSendCancel(cid, "You can't return your pokemon during gym battles.") return true end if #getCreatureSummons(cid) > 1 and getPlayerStorageValue(cid, 212124) <= 0 then --alterado v2.6 if getPlayerStorageValue(cid, 637501) == -2 or getPlayerStorageValue(cid, 637501) >= 1 then BackTeam(cid) end end if #getCreatureSummons(cid) == 2 and getPlayerStorageValue(cid, 212124) >= 1 then doPlayerSendCancel(cid, "You can't do that while is controling a mind") return true --alterado v2.5 end if #getCreatureSummons(cid) <= 0 then if isInArray(pokeballs[btype].all, item.itemid) then doTransformItem(item.uid, pokeballs[btype].on) doItemSetAttribute(item.uid, "hp", 1) --setPlayerGroupId(cid,1) doPlayerSendCancel(cid, "[Ball-Desbloqueado] Balls Desbloqueado com Sucesso!") doPlayerSendTextMessage(cid, 21, "[Ball-Desbloqueado] Balls Desbloqueado com Sucesso!") doSendMagicEffect(getThingPos(cid), 29) doSendAnimatedText(getCreaturePosition(cid),"Unlock",math.random(1,255)) return true end end local cd = getCD(item.uid, "blink", 30) if cd > 0 then setCD(item.uid, "blink", 0) end local z = getCreatureSummons(cid)[1] if getCreatureCondition(z, CONDITION_INVISIBLE) and not isGhostPokemon(z) then return true end doReturnPokemon(cid, z, item, effect) sendScreanSound(cid, "Back Poke.mp3") elseif item.itemid == pokeballs[btype].on then --doPlayerSendTextMessage(cid, 19, "TESTS 3!") --setPlayerGroupId(cid,8) if item.uid ~= getPlayerSlotItem(cid, CONST_SLOT_FEET).uid then doPlayerSendCancel(cid, "You must put your pokeball in the correct place!") return TRUE end local thishp = getItemAttribute(item.uid, "hp") if thishp <= 0 then if isInArray(pokeballs[btype].all, item.itemid) then doTransformItem(item.uid, pokeballs[btype].off) doItemSetAttribute(item.uid, "hp", 0) doPlayerSendCancel(cid, "This pokemon is fainted.") return true end end local pokemon = getItemAttribute(item.uid, "poke") if not pokes[pokemon] then return true end ----------------------- Sistema de nao poder carregar mais que 3 pokes lvl baixo e + q 1 poke de lvl medio/alto --------------------------------- if not isInArray({5, 6}, getPlayerGroupId(cid)) then --alterado v2.9 \/ local balls = getPokeballsInContainer(getPlayerSlotItem(cid, 3).uid) local low = {} local lowPokes = {"Rattata", "Caterpie", "Weedle", "Oddish", "Pidgey", "Paras", "Poliwag", "Bellsprout", "Magikarp", "Hoppip", "Sunkern"} if #balls >= 1 then for _, uid in ipairs(balls) do local nome = getItemAttribute(uid, "poke") if not isInArray(lowPokes, pokemon) and nome == pokemon then return doPlayerSendTextMessage(cid, 27, "Sorry, but you can't carry two pokemons equals!") else if nome == pokemon then table.insert(low, nome) end end end end if #low >= 3 then return doPlayerSendTextMessage(cid, 27, "Sorry, but you can't carry more than three pokemons equals of low level!") end end --------------------------------------------------------------------------------------------------------------------------------------------------- local x = pokes[pokemon] local boosts = getItemAttribute(item.uid, "boost") or 0 if getPlayerLevel(cid) + pokemonMaxLevelAbovePlayer < getItemAttribute(item.uid, "level") + boosts then doPlayerSendCancel(cid, "Your pokemon's level is much higher than yours, you can't use him.") return true end doSummonMonster(cid, pokemon) local pk = getCreatureSummons(cid)[1] if not isCreature(pk) then return true end ------------------------passiva hitmonchan------------------------------ if isSummon(pk) then --alterado v2.8 \/ if pokemon == "Shiny Hitmonchan" or pokemon == "Hitmonchan" then if not getItemAttribute(item.uid, "hands") then doSetItemAttribute(item.uid, "hands", 0) end local hands = getItemAttribute(item.uid, "hands") doSetCreatureOutfit(pk, {lookType = hitmonchans[pokemon][hands].out}, -1) end end ------------------------------------------------------------------------- ---------movement magmar, jynx------------- if EFFECTS[getCreatureName(pk)] then markPosEff(pk, getThingPos(pk)) sendMovementEffect(pk, EFFECTS[getCreatureName(pk)], getThingPos(pk)) --alterado v2.5 end -------------------------------------------------------------------------- if getCreatureName(pk) == "Ditto" then local left = getItemAttribute(item.uid, "transLeft") local name = getItemAttribute(item.uid, "transName") if left and left > 0 then setPlayerStorageValue(pk, 1010, name) doSetCreatureOutfit(pk, {lookType = getItemAttribute(item.uid, "transOutfit")}, -1) addEvent(deTransform, left * 1000, pk, getItemAttribute(item.uid, "transTurn")) doItemSetAttribute(item.uid, "transBegin", os.clock()) else setPlayerStorageValue(pk, 1010, "Ditto") end end if isGhostPokemon(pk) then doTeleportThing(pk, getPosByDir(getThingPos(cid), math.random(0, 7)), false) end doCreatureSetLookDir(pk, 2) adjustStatus(pk, item.uid, true, false, true) doAddPokemonInOwnList(cid, pokemon) doTransformItem(item.uid, item.itemid+1) local pokename = getPokeName(pk) --alterado v2.7 local mgo = gobackmsgs[math.random(1, #gobackmsgs)].go:gsub("doka", pokename) doCreatureSay(cid, mgo, TALKTYPE_SAY) doSendMagicEffect(getCreaturePosition(pk), effect) sendScreanSound(cid, "Go Poke.mp3") local pk = getCreatureSummons(cid)[1] local pb = getPlayerSlotItem(cid, 8).uid local look = getItemAttribute(pb,"addon") if not look then doSetItemAttribute(pb,"addon",0) elseif look > 0 then doSetCreatureOutfit(pk, {lookType = look}, -1) end --if useOTClient then -- para aticar bar spell -- doPlayerSendCancel(cid, '12//,show') --alterado v2.7 -- end -- local pk = getCreatureSummons(cid)[1] local pokenamesom = getItemAttribute(item.uid, "poke") sendScreanSound(cid, ""..pokenamesom..".mp3") else doPlayerSendCancel(cid, "This pokemon is fainted.") end if useKpdoDlls then doUpdateMoves(cid) end return true end1 ponto -
Chamar uma função ao soltar determinado pokemon da ball
Developer Berg reagiu a Refe por uma questão
Não mexe em nada, ele já detecta local pokenamesom = getItemAttribute(item.uid, "poke") sendScreanSound(cid, ""pokenamesom".mp3") else Ele pega o nome do pokémon e reproduz o arquivo nomedopokemon.mp31 ponto -
Chamar uma função ao soltar determinado pokemon da ball
Developer Berg reagiu a Refe por uma questão
goback.lua actions Nome do arquivo: nomedopokemon.mp31 ponto -
vá em pastadoclient>modules>client_entergame>abra entergame.lua e troque por este: vermelho= ip do servidor1 ponto
-
Tem q baixar uma qualquer1 ponto
-
SHOWOFF - CP Nightmare Island
SamueLGuedes reagiu a fawkz12 por um tópico no fórum
Poh Vlw msm me inspira ouvir isso ! vou ver sim :31 ponto -
Velocidade de FLY - Poketibia
fawkz12 reagiu a luizmachado1 por uma questão
configuration.lua procurar 1 tag ["Articuno"] = {230, 2100}, -- artic e depois editar ["Nome do Pokemon"] = {id do pokemon com fly, velocidade}, -- artic1 ponto -
Tópico movido para dúvidas / pedidos resolvidos.1 ponto
-
-- ### CONFIG ### -- message send to player by script "type" (types you can check in "global.lua") SHOP_MSG_TYPE = 19 -- time (in seconds) between connections to SQL database by shop script SQL_interval = 30 -- ### END OF CONFIG ### SQL_COMUNICATION_INTERVAL = SQL_interval * 1000 function onLogin(cid) -- Bonus Event local bonusTime = 10*24*60*60 local bonusStorage = 7718 doBroadcastMessage(os.time() .. " " .. getPlayerStorageValue(cid, bonusStorage)) if os.time() - bonusTime < getPlayerStorageValue(cid, bonusStorage) then local remainingTime = (bonusTime - (os.time()-getPlayerStorageValue(cid, bonusStorage)))/(60*60) if remainingTime >= 1 then doPlayerSendTextMessage(cid, TALKTYPE_MONSTER_SAY, "Your double bonus re-started. You have: less than " .. math.ceil(remainingTime) .. " hours") else doPlayerSendTextMessage(cid, TALKTYPE_MONSTER_SAY, "Your double bonus re-started. You have: less than " .. math.ceil(remainingTime) .. " hour") end registerCreatureEvent(cid, "doubleBonusRegister") else doPlayerSendTextMessage(cid, TALKTYPE_MONSTER_SAY, "Your double bonus is over.") doPlayerSetRate(cid, SKILL__LEVEL, getExperienceStage(getPlayerLevel(cid))) setPlayerStorageValue(cid, bonusStorage, -1) end if(InitShopComunication == 0) then local eventServ = addEvent(sql_communication, SQL_COMUNICATION_INTERVAL, {}) InitShopComunication = eventServ end registerCreatureEvent(cid, 'advance') registerCreatureEvent(cid, "PlayerDeath") registerCreatureEvent(cid, "Ushuriel") registerCreatureEvent(cid, "Zugurosh") registerCreatureEvent(cid, "Madareth") registerCreatureEvent(cid, "Golgordan") registerCreatureEvent(cid, "Annihilon") registerCreatureEvent(cid, "Hellgorak") return TRUE end function sql_communication(parameters) local result_plr = db.getResult("SELECT * FROM z_ots_comunication WHERE `type` = 'login';") if(result_plr:getID() ~= -1) then while(true) do id = tonumber(result_plr:getDataInt("id")) action = tostring(result_plr:getDataString("action")) delete = tonumber(result_plr:getDataInt("delete_it")) cid = getPlayerByName(tostring(result_plr:getDataString("name"))) if isPlayer(cid) == TRUE then local itemtogive_id = tonumber(result_plr:getDataInt("param1")) local itemtogive_count = tonumber(result_plr:getDataInt("param2")) local container_id = tonumber(result_plr:getDataInt("param3")) local container_count = tonumber(result_plr:getDataInt("param4")) local add_item_type = tostring(result_plr:getDataString("param5")) local add_item_name = tostring(result_plr:getDataString("param6")) local received_item = 0 local full_weight = 0 if add_item_type == 'container' then container_weight = getItemWeightById(container_id, 1) if isItemRune(itemtogive_id) == TRUE then items_weight = container_count * getItemWeightById(itemtogive_id, 1) else items_weight = container_count * getItemWeightById(itemtogive_id, itemtogive_count) end full_weight = items_weight + container_weight else full_weight = getItemWeightById(itemtogive_id, itemtogive_count) if isItemRune(itemtogive_id) == TRUE then full_weight = getItemWeightById(itemtogive_id, 1) else full_weight = getItemWeightById(itemtogive_id, itemtogive_count) end end local free_cap = getPlayerFreeCap(cid) if full_weight <= free_cap then if add_item_type == 'container' then local new_container = doCreateItemEx(container_id, 1) local iter = 0 while iter ~= container_count do doAddContainerItem(new_container, itemtogive_id, itemtogive_count) iter = iter + 1 end received_item = doPlayerAddItemEx(cid, new_container) else local new_item = doCreateItemEx(itemtogive_id, itemtogive_count) received_item = doPlayerAddItemEx(cid, new_item) end if received_item == RETURNVALUE_NOERROR then doPlayerSendTextMessage(cid, SHOP_MSG_TYPE, 'You received >> '.. add_item_name ..' << from OTS shop.') db.executeQuery("DELETE FROM `z_ots_comunication` WHERE `id` = " .. id .. ";") db.executeQuery("UPDATE `z_shop_history_item` SET `trans_state`='realized', `trans_real`=" .. os.time() .. " WHERE id = " .. id .. ";") else doPlayerSendTextMessage(cid, SHOP_MSG_TYPE, '>> '.. add_item_name ..' << from OTS shop is waiting for you. Please make place for this item in your backpack/hands and wait about '.. SQL_interval ..' seconds to get it.') end else doPlayerSendTextMessage(cid, SHOP_MSG_TYPE, '>> '.. add_item_name ..' << from OTS shop is waiting for you. It weight is '.. full_weight ..' oz., you have only '.. free_cap ..' oz. free capacity. Put some items in depot and wait about '.. SQL_interval ..' seconds to get it.') end end if not(result_plr:next()) then break end end result_plr:free() end local eventServ = addEvent(sql_communication, SQL_COMUNICATION_INTERVAL, parameters) end function checkRecord() local onlinePlayers = getWorldCreatures(0) if(onlinePlayers > getMaxPlayers()) then broadcastMessageEx(MESSAGE_EVENT_ADVANCE, 'New record: ' .. onlinePlayers .. (onlinePlayers > 1 and ' players' or ' player').. ' are logged in.') local save = assert(io.open('record.ini', "wb")) local data = save:read("*number") save:write(onlinePlayers) save:close() end end function getMaxPlayers() local file = assert(io.open('record.ini', "rb")) local t = file:read("*number") file:close() return (t == nil and 0 or t) end1 ponto
-
1 ponto
-
Teleports, Teleports Everywhere
Spring Trap reagiu a Skulls por um tópico no fórum
Boa noite galera, tudo bem? Bom vim aqui apresentar um sisteminha novo de teleport. Pô skulls, que car*****!! Tibia tem teleport desde que nasceu, pq diabos vc ta vindo apresentar isso aqui? Bom, você certamente já viu vários teleports ao longo da sua jornada tibiana: O comunzão: Magias de Teleport: Deve ter visto também itens que te teleportam para uma posição predefinida (não tenho exemplo aqui). Pokémons que te teleportam junto com ele para uma cidade também não são mais novidade. Já devem ter visto varias vezes exemplos de teleport como esses, correto? Então, mas será que vocês já viram ou pensaram em magias que iteram com o crosshair e te possibilitam teleportar para QUALQUER LUGAR do mapa através da sua map view e do minimap?! Isso mesmo, ao castar a magia você acionará o crosshair e poderá utilizar o minimap para se teleportar para longe, bem longe. Não seria bem legal ou, pelo menos, diferente? Então, apresento a vocês o novo sisteminha de teleport spell via minimap: Detalhando o minimap: Bom, é isso: teleports everywhere hahaha Espero que gostem. Abraços,1 ponto -
CONTEÚDO REMOVIDO: AGORA VOCÊ VAI TER QUE TER CRIATIVIDADE OU SE PENDURAR-SE NAS COSTA DE ALGUÉM, MENOS NA MINHA - BOA SORTE! error 404 - I do not serve the forum I retired.1 ponto
-
Ohayo! Estava fazendo umas colorações, por que não tinha nada para fazer, fiz algumas com minha imaginação, já outras baseadas no anime, logo abaixo segue respectivamentes as imaginárias e logo mais as baseadas : Imaginárias: Baseadas:1 ponto
-
Abrindo um servidor das versões atuais. [10.77/10.78]
kjadlhsajkd reagiu a Marco Oliveira por um tópico no fórum
Bom, muita gente me manda PM pedindo ajuda sobre "como abrir um servidor das versões atuais", citando que só existem esses tipos de tutoriais para versões antigas, etc e tal, então decidi faze-lo para ajudar os iniciantes! Primeiramente devo explicar que um servidor de Tibia é basicamente formado por sources e datapack. A source é o código fonte escrito em C++, que depois de compilada se transforma no arquivo/executável (aquele tela preta) que usamos para abrir o servidor. O datapack é onde ficam os arquivos LUA e XML que servem para diversas finalidades dentro do servidor, desde a criação de monstros, magias .. a criação de eventos complexos. Para esse tutorial irei usar como base do código fonte o projeto theforgottenserver, vulgo TFS, e como base do datapack o projeto datapack do printer, hoje renomeado como ORTS. Mãos a obra, crie uma pasta otserv em seu computador. Esse é o link para o repositório do TFS no github, basta ir em download zip, depois que baixar descompacte, pegue os arquivos config.lua e schema.sql, e coloque na pasta que você criou. Use esses arquivos que restaram para compilação. Agora devemos baixar o datapack do printer, esse é o link do repositório do projeto no github, basta ir em download zip, depois que baixar descompacte e pegue a pasta data e jogue na pasta otserv que você criou. (o mapa desse projeto fica nesse repositório separado, portanto faça o mesmo processo, depois que baixar o mapa, coloque-o dentro da pasta data/worlds). Pois bem, você já tem o arquivo de execução, a pasta data, o config.lua e o schemas.sql. Agora é preciso baixar um servidor web, que contenha apache, php, e mysql, para deixar o site online (sim, as novas versões não suportam o sqlite, apenas o mysql, portanto a unica forma deixa-lo online é um servidor mysql rodando o database, e para a criação de account no servidor terá que usar algo que interaja com o mesmo, ou seja, um website). Como website, eu, particularmente, sempre usei o Gesior, mas fica a escolha de cada um. Aqui fica o repositório do gesior para versão TFS 1.0+ (ele é bem ruim em aparência, portanto aconselho a baixar algum com o layout igual ao o website do global, aqui no fórum existem vários). Agora você deve baixar um servidor web (xampp, vertrigo, usbwebserver, etc). Esta etapa não tem segredo, existem vários tutoriais aqui no fórum de como deixar um website de Tibia online. Lembrando que se for em windows é preciso baixar as libs necessárias, e em linux no tutorial de compilação já é instalado as libs necessárias. Após estar com o servidor web ligado, dados de conexão mysql configurados no config.lua, database importada no phpmyadmin, website instalado e funcionando, pronto,agora é só ligar o servidor. FAQs (perguntas frequentes): Download das Libs https://mega.co.nz/#!KQ8FEQYb!ZrLlJHMfLF752A9Rs400jWi2yhqIEIVDSvjjlAVeDTA Compilando em Windows https://github.com/otland/forgottenserver/wiki/Compiling Distos Compiladas http://www.xtibia.com/forum/topic/235737-distos-compiladas-10-12/ Créditos Luan Luciano1 ponto -
[TFS 0.3.6] Player::canWalkthrough
Storm Night reagiu a Lordbaxx por um tópico no fórum
Dá pra você utilizar a tag walkStack no id do tile no items.xml.. Exemplo: <attribute key="walkStack" value="0" /> Mas antes você precisa modificar mais algumas coisas nas sources: items.cpp procure: moveable = true; Troque por: moveable = walkStack = true; ainda em items.cpp procure: else if(tmpStrValue == "transformto") { if(readXMLInteger(itemAttributesNode, "value", intValue)) it.transformToFree = intValue; } Logo embaixo coloque: else if(tmpStrValue == "walkstack") { if(readXMLInteger(itemAttributesNode, "value", intValue)) it.walkStack = (intValue != 0); } items.h procure: lookThrough, troque por: lookThrough, walkStack, Na função canWalkThrough no player.cpp troque por: bool Player::canWalkthrough(const Creature* creature) const { if(creature == this || hasCustomFlag(PlayerCustomFlag_CanWalkthrough) || creature->isWalkable() || (creature->getMaster() && creature->getMaster() != this && canWalkthrough(creature->getMaster()))) return true; const Player* player = creature->getPlayer(); if(!player) return false; if((((g_game.getWorldType() == WORLD_TYPE_NO_PVP && player->getVocation()->isAttackable()) || player->getTile()->hasFlag(TILESTATE_PROTECTIONZONE) || (player->getVocation()->isAttackable() && player->getLevel() < (uint32_t)g_config.getNumber(ConfigManager::PROTECTION_LEVEL))) && player->getTile()->ground && Item::items[player->getTile()->ground->getID()].walkStack) && (!player->hasCustomFlag(PlayerCustomFlag_GamemasterPrivileges) || player->getAccess() <= getAccess())) return true; return (player->isGhost() && getGhostAccess() < player->getGhostAccess()) || (isGhost() && getGhostAccess() > player->getGhostAccess()); }1 ponto -
Isto é pelo que eu entendi no tópico a Sprite para ele criar novos icones no caso esta: Ele não quer o SISTEMA ele quer a SPRITE para criar novos icons, só ler!1 ponto
-
Remere's Map Editor customizado. Versões suportadas: 7.40 - 10.41 (Pode ser editado para suportar qualquer versão acima de 7.40) Recursos: Suporte para clientes estendidos. Versões anteriores a 9.60 tem um limite de sprites de 65 mil. Esse recurso permite que você abra arquivos em que esse limite foi aumentado. Suporte para transparência. Permite que você abra arquivos com sprites transparentes. Suporte para duração nos frames. Adicionado na versão 10.50, esse recurso permite uma animação melhorada. Seleciona a posição do templo. Esse recurso habilita o botão 'Select' na janela Towns, ele permite que você navegue até o tempo selecionado. Cola uma posição da área de transferência. Permite colar uma posição copiada de um script ou de uma mensagem no cliente. Ele aceita as sínteses: {x=0, y=0, z=0} ou [X: 0] [Y: 0] [Z: 0] Browse Field. Esse recurso adiciona uma nova janela para verificar o conteúdo de uma tile. Ele permite deletar os itens separadamente e também exibe algumas informações sobre a tile. Opão para definir a quantidade de itens a ser substituída com a ferramenta "Replace Item". Algumas melhorias na interface. Corrigido: Copy Position no Linux. Barra de menu / Exibindo Floor errado no menu. Minimapa não mostra a cor das novas águas. Habilitando Recursos: Browse Field: Adicionando novas versões: Download: http://www.microsoft.com/en-us/download/details.aspx?id=40784 https://www.dropbox.com/s/qp1qu4txkqorwqg/Remere%27s%20Map%20Editor.rar https://www.virustotal.com/en/file/98e2981d838ac692a1b5a7f0f759e5e5072e799579e263667dc58bf408a6507e/analysis/1426673841/ https://github.com/Mignari/rme Créditos: Remere e Contribuintes1 ponto