Fala galera , trago hoje pra vocês do tibiaking um evento EXXXXXXXXXXCLUSIVO!
É o evento [Floresta Encantada]
Como funciona?
- É aberto um teleport no templo do servidor (configurável).
- O mesmo ficará aberto por 5 minutos (os jogadores permanecerão na sala de espera do evento)
- Quando o evento começar os jogadores terão que andar pela floresta até chegar ao local da bandeira e dar use na mesma.
- Observação: Há diversos atalhos que os jogadores podem chegar rapidamente ou voltar para o começo ( Eis a sorte ).
- O Jogadores que chegar até a bandeira pós os atalhos e derrotar os monstros é o vencedor!
- Obs: Para concluir basta clicar na bandeira.
Vamos a instalação/scripts:
Em data/actions/scripts crie um arquivo com o nome de flagabsolute.lua e adicione dentro:
function onUse(cid, item)
if getGlobalStorageValue(configExf.stats) == 1 then
doTeleportThing(cid, configExf.templepos)
doCloseExf()
doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "Voce ganhou o evento Floresta encantada, parabens receba seu premio")
doBroadcastMessage(getPlayerName(cid) .. " foi o vencedor do Floresta Encantada.")
doPlayerAddItem(cid, configExf.prize)
else
doPlayerSendCancel(cid, "Desculpe mas o evento encontra se fechado")
end
return true
end
Em data/actions/actions.xml adicione a seguinte linha:
<action uniqueid="5312" event="script" value="flagabsolute.lua" />
Em data/movements/scripts você irá criar 2 arquivos.
Primeiro crie o enterTp.lua e adicione dentro:
function onStepIn(cid, item, position, lastPosition, fromPosition, toPosition, actor)
if(not isPlayer(cid)) then
return true
end
if(configExchantedForest.status == 0) then -- ativo
addPlayerToExchantedForest(cid)
end
return true
end
Depois ainda na mesma pasta crie o magicTp.lua e dentro adicione:
function onStepIn(cid, item, position, lastPosition, fromPosition, toPosition)
if isPlayer(cid) then
if getGlobalStorageValue(configExf.stats) == 1 then
doTeleportThing(cid, configExf.randpos[math.random(1, #configExf.randpos)])
doSendMagicEffect(getPlayerPosition(cid), 29)
else
doTeleportThing(cid, configExf.teleportPla)
end
end
return true
end
Em data/movements/movements.xml adicione a linha:
<movevent type="StepIn" actionid="5310" event="script" value="eforest/magicTp.lua"/>
Em data/talkactions/scripts crie um arquivo com o nome de florestaabsolute.lua e adicione dentro:
function onSay(cid, words, param)
if param == "on" then
if getGlobalStorageValue(configExf.stats) == -1 then
doStartExf()
else
doPlayerSendCancel(cid, "O evento ja esta ocorrendo.")
end
elseif param == "off" then
if getGlobalStorageValue(configExf.stats) ~= -1 then
doCloseExf()
doBroadcastMessage("Agora o evento Flroesta Encantada esta fechado.")
else
doPlayerSendCancel(cid, "O evento noo esta ocorrendo.")
end
end
return true
end
Em data/talkactions/talkactions.xml adicione a seguinte linha:
<talkaction log="yes" words="/eforest" access="3" event="script" value="florestaabsolute.lua"/>
Em data/monster crie um arquivo com o nome de Fucking Florest.xml e dentro adicione:
<?xml version="1.0" encoding="UTF-8"?>
<monster name="Fucking Florest" nameDescription="a fucking flroest" race="blood" experience="0" speed="920" manacost="0">
<health now="60800" max="60800"/>
<look type="229" corpse="9660"/>
<targetchange interval="5000" chance="8"/>
<strategy attack="100" defense="0"/>
<flags>
<flag summonable="0"/>
<flag attackable="1"/>
<flag hostile="1"/>
<flag illusionable="0"/>
<flag convinceable="0"/>
<flag pushable="0"/>
<flag canpushitems="1"/>
<flag canpushcreatures="1"/>
<flag targetdistance="1"/>
<flag staticattack="90"/>
<flag runonhealth="0"/>
</flags>
<attacks>
<attack name="melee" interval="2000" min="-0" max="-500"/>
<attack name="lifedrain" interval="1000" chance="20" range="1" min="-200" max="-600">
<attribute key="areaEffect" value="redshimmer"/>
</attack>
<attack name="physical" interval="2000" chance="8" range="7" min="-0" max="-550">
<attribute key="shootEffect" value="suddendeath"/>
<attribute key="areaEffect" value="mortarea"/>
</attack>
<attack name="physical" interval="1000" chance="35" range="7" min="-200" max="-800">
<attribute key="shootEffect" value="energy"/>
</attack>
</attacks>
<defenses armor="26" defense="23"/>
<elements>
<element energyPercent="10"/>
<element earthPercent="80"/>
<element icePercent="15"/>
<element firePercent="-10"/>
<element holyPercent="-25"/>
</elements>
<immunities>
<immunity death="1"/>
<immunity invisible="1"/>
</immunities>
<voices interval="4000" chance="100">
<voice sentence="I AM BOSSING OF FLOREST"/>
<voice sentence="NAO PEGUE MINHA BANDEIRA."/>
<voice sentence="MUAHAHAHAHA."/>
<voice sentence="Absolute on TibiaKing."/>
</voices>
<loot>
<item id="2160" countmax="1" chance="2000"/><!-- gold coin -->
</item>
</loot>
</monster>
E para finalizar crie um arquivo com o nome de florestaabsolute.lua em data/libs e dentro adicione:
configExf = {
teleportPos = {x = 32341,y = 32213, z = 7}, -- aonde aparecerá o teleport
teleportPla = {x=32622, y=31699, z=7}, -- para onde o teleport levará
stats = 201201180701,
timetostart = 300, -- tempo para iniciar
topleftPos = {x = 32589, y = 31662, z = 7}, -- canto esquerdo superior
botrightPos = {x = 32631, y = 31693, z = 7}, -- canto direito inferior
prize = 6571, -- recompensa
templepos = {x=32369, y=32241, z=7}, -- posição do templo
randpos = {{x=32625,y=31692,z=7},{x=32621,y=31692,z=7},{x=32617,y=31692,z=7},{x=32619,y=31687,z=7},{x=32624,y=31681,z=7},{x=32630,y=31668,z=7},{x=32627,y=31668,z=7},{x=32617,y=31672,z=7},{x=32613,y=31677,z=7},{x=32608,y=31665,z=7},{x=32610,y=31688,z=7},{x=32598,y=31684,z=7},{x=32596,y=31684,z=7},{x=32597,y=31668,z=7}}
} -- O PAPAI ABSOLUTE EXPLICARÁ NAS IMAGENS ESSAS POSIÇÕES
function doStartExf()
doCreateTeleport(1387, configExf.teleportPla, configExf.teleportPos)
setGlobalStorageValue(configExf.stats, 0)
doBroadcastMessage("The Exchanted Forest event will open in " .. configExf.timetostart .. " seconds.")
addEvent(doInitExf, configExf.timetostart*1000)
end
function doInitExf()
if getGlobalStorageValue(configExf.stats) == 0 then
doBroadcastMessage("The Exchanted Forest event is starting...")
setGlobalStorageValue(configExf.stats, 1)
end
end
function doCloseExf()
setGlobalStorageValue(configExf.stats, -1)
local item = getTileItemById(configExf.teleportPos, 1387)
if(item.uid ~= 0) then
doRemoveItem(item.uid)
end
doRemovePlayersFromArea(configExf.topleftPos, configExf.botrightPos, configExf.templepos)
end
Configurando a LIB:
teleportPos = {x = 32341,y = 32213, z = 7}, -- LUGAR DO SEU OT QUE IRÁ NASCER O TP
teleportPla = {x=32622, y=31699, z=7}, -- LUGAR ONDE OS PLAYERS IRÃO SER TELEPORTADOS, COMO NA IMAGEM SERÁ AQUI:
timetostart = 300, -- TEMPO EM SEGUNDOS PRA COMEÇAR O EVENTO
topleftPos = {x = 32589, y = 31662, z = 7}, -- canto esquerdo superior = NO CASO SERIA ASSIM, ONDE CIRCULEI:
botrightPos = {x = 32631, y = 31693, z = 7}, -- canto direito inferior (ONDE CIRCULEI):
prize = 6571, -- ID DA RECOMPENSA PRO GANHADOR
templepos = {x=32369, y=32241, z=7}, -- posição do templo do seu ot
randpos = {{x=32625,y=31692,z=7},{x=32621,y=31692,z=7},{x=32617,y=31692,z=7},{x=32619,y=31687,z=7},{x=32624,y=31681,z=7},{x=32630,y=31668,z=7},{x=32627,y=31668,z=7},{x=32617,y=31672,z=7},{x=32613,y=31677,z=7},{x=32608,y=31665,z=7},{x=32610,y=31688,z=7},{x=32598,y=31684,z=7},{x=32596,y=31684,z=7},{x=32592,y=31672,z=7},{x=32594,y=31672,z=7},{x=32597,y=31668,z=7}} -- Como na imagem irá mostrar, são os SQMS CINZAS, os responsáveis pelos atalhos, portanto coloque a configuração de cada um certo (IMPORTANTE):
-- END --
E por fim:
Download do mapa: https://www.sendspace.com/file/ilhba3
Scan do mapa:
Screen do mapa:
TO END:
SQM QUE VOCÊ COLOCARÁ O BOSS QUE CRIOU (FUCKING FLOREST):
Observação: Os monstros vocês colocarão no mapa no caminho da floresta, podem variar de acordo com o servidor, apenas não esqueçam rs.
Créditos:
Absolute
GlobalWAR
Qualquer dúvida por favor poste aqui no tópico que irei ajudar a resolver
Não tenha vergonha de perguntar, ninguém nasceu sabendo!
Espero ajudar e ver esse evento em vários servidores.
EXCLUUUUUUUUUSSIVO PRA VOCÊS
Em breve mais eventos/sistemas
Absolute.