Bom, acho que todos que procuram esse systema já vio o outro topico do Spiga, mas infelizmente ele não funciona!
Então resolvi editar uma versão editada desse script '-'
Ai vai:
Crie dois arquivos.lua um com o nome de !back e outro com o nome de !dive e coloque na pasta Talkactions.
No arquivo !dive coloque:
function onSay(cid, words, param, channel) if getPlayerStorageValue(cid,63215) >=1 then pos = getCreaturePosition(cid) if pos.z ~= 7 then return false end npos = {x=pos.x, y=pos.y, z=pos.z + 1} local grounds = {5405, 5406, 5407, 5408, 5409, 5410} if (not isInArray(grounds, getTileThingByPos(npos).itemid)) then return doPlayerSendCancel(cid, "You cannot dive here.") end if doTeleportThing(cid, npos) then doSendMagicEffect(npos, 14) if getPlayerSex(cid) == 1 then doSetCreatureOutfit(cid, {lookType = 1034, lookHead = 0, lookAddons = 0, lookLegs = 0, lookBody = 0, lookFeet = 0}, -1) else doSetCreatureOutfit(cid, {lookType = 1035, lookHead = 0, lookAddons = 0, lookLegs = 0, lookBody = 0, lookFeet = 0}, -1) end setPlayerStorageValue(cid, 63215, 0) local item = getPlayerSlotItem(cid, 8) local pokemon = getItemAttribute(item.uid, "poke") local x = pokes[pokemon] if getItemAttribute(item.uid, "nick") then doCreatureSay(cid, "".."Good job "..getItemAttribute(item.uid, "nick").." !", 1) else doCreatureSay(cid, "".."Good job "..getItemAttribute(item.uid, "poke").." !", 1) end local pk = getCreatureSummons(cid)[1] doChangeSpeed(pk, getCreatureSpeed(cid)) doChangeSpeed(cid, -getCreatureSpeed(cid)) doChangeSpeed(cid, PlayerSpeed) doTeleportThing(pk, getThingPos(cid), true) doCreatureSetLookDir(pk, getCreatureLookDir(cid)) adjustStatus(pk, item.uid, true, false, true) end else return doPlayerSendCancel(cid, "You cannot dive here.") end return TRUE end
No arquivo !back coloque:
function onSay(cid, words, param, channel) divepos = getCreaturePosition(cid) npos2 = getPlayerMasterPos(cid) poszao = {x=divepos.x, y=divepos.y, z=7} pos = getCreaturePosition(cid) local waters = {11756, 4614, 4615, 4616, 4617, 4618, 4619, 4608, 4609, 4610, 4611, 4612, 4613, 7236, 4614, 4615, 4616, 4617, 4618, 4619, 4620, 4621, 4622, 4623, 4624, 4625, 4665, 4666, 4820, 4821, 4822, 4823, 4824, 4825} local poke = {'Poliwag', 'Poliwhirl', 'Seaking', 'Dewgong', 'Blastoise', 'Tentacruel', 'Lapras', 'Gyarados', 'Omastar', 'Kabutops', 'Vaporeon', 'Staryu', 'Starmie', 'Goldeen', 'Seadra', 'Golduck', 'Squirtle', 'Wartortle', 'Tentacool', 'Snorlax', 'Poliwrath', 'Shiny Poliwag', 'Shiny Poliwhirl', 'Shiny Seaking', 'Shiny Dewgong', 'Shiny Blastoise', 'Shiny Tentacruel', 'Shiny Lapras', 'Shiny Gyarados', 'Shiny Omastar', 'Shiny Kabutops', 'Shiny Vaporeon', 'Shiny Staryu', 'Shiny Starmie', 'Shiny Goldeen', 'Shiny Seadra', 'Shiny Golduck', 'Shiny Squirtle', 'Shiny Wartortle', 'Shiny Tentacool', 'Shiny Snorlax', 'Shiny Poliwrath', "Mantine", "Totodile", "Croconow", "Feraligatr", "Marill", "Azumarill", "Quagsire", "Wooper", "Octillery", "Kingdra"} if getCreatureOutfit(cid).lookType == 316 or getCreatureOutfit(cid).lookType == 648 then doSendMagicEffect(fromPosition, 136) end if (getPlayerStorageValue(cid, 63215) >= 1 or getPlayerStorageValue(cid, 17000) >= 1) then return true end if #getCreatureSummons(cid) == 0 then doPlayerSendCancel(cid, "You need a pokemon to dive.") return true end if (not isInArray(poke, getPokemonName(getCreatureSummons(cid)[1]))) then doPlayerSendCancel(cid, "This pokemon cannot dive.") return true end if (not isInArray(waters, getTileThingByPos(poszao).itemid)) then doPlayerSendCancel(cid, "You cant up here.") return true end if pos.z >= 8 then if doTeleportThing(cid, poszao) == true then doSendMagicEffect(poszao, 14) end else return print("Erro ao utilizar comando !back") end if pos.z <=7 then doPlayerSendCancel(cid, "Você precisa estar mergulhando para usar este comando.") return true end end
Agora va no aquivo talkactions.xml e adicione as tags:
<talkaction words="!dive" event="script" value="!dive.lua"/> <talkaction words="!back" event="script" value="!back.lua"/>
Pronto!
Agora é so usar ^^
Topico original:
http://www.xtibia.co...-dash-advanced/
Creditos para:
Spiga Pois fez o script
Para jeffe000 pois arrumou o script
E para mim '-' Pois editei ele.. ^^