Ir para conteúdo

Erros do PokexAdvanced


Knowth

Posts Recomendados

Bom nesse tópico eu venho trazer alguns erros do meu servidor, então peço desde já que não fechem esse tópico por favor ! Pois não quero ter muitos tópicos para colocar erros simples.. Então sempre que tiver um erro irei colocar aqui :)

 

Informações do server:

 

Base DxP by Lordbaxx

Server com sources !

Não tem sistemas, tipo: Nickname, aura...

 

Vamos la pra começar eu tou com esses erros na minha distro.. que no caso é do Go/back. Já tentei arrumar copiar de outros servidores e por no meu mais não funcionou ¬¬'

 

Erro do Go/back

 

[20/04/2014 12:38:01] [Error - Action Interface]
[20/04/2014 12:38:01] In a timer event called from:
[20/04/2014 12:38:01] data/actions/scripts/goback.lua:onUse
[20/04/2014 12:38:01] Description:
[20/04/2014 12:38:01] (luaDoItemSetAttribute) Invalid data type

[20/04/2014 12:38:01] [Error - Action Interface]
[20/04/2014 12:38:01] In a timer event called from:
[20/04/2014 12:38:01] data/actions/scripts/goback.lua:onUse
[20/04/2014 12:38:01] Description:
[20/04/2014 12:38:01] data/lib/moves.lua:708: attempt to perform arithmetic on local 'damage' (a nil value)
[20/04/2014 12:38:01] stack traceback:
[20/04/2014 12:38:01] data/lib/moves.lua:708: in function 'doBurn2'
[20/04/2014 12:38:01] data/lib/moves.lua:1158: in function

 

Meu Go/back

 

function onUse(cid, item, frompos, item2, topos)
if #getCreatureSummons(cid) >= 1 and getPlayerStorageValue(getCreatureSummons(cid)[1], 33) >= 1 then
return true
end

----
btype = getPokeballType(item.itemid)
usando = pokeballs[btype].use
online = pokeballs[btype].on
morto = pokeballs[btype].off
----


if item.itemid == usando then

doPlayerSendCancel(cid, '12//,hide')
doReturnPokemon(cid) -- Editei aqui


elseif item.itemid == morto then
return doPlayerSendCancel(cid, "This pokemon is fainted.")

elseif item.itemid == online then

doPlayerSendCancel(cid, '12//,show')
addEvent(doUpdateMoves, 50, cid)
doGoPokemon(cid)


end
return TRUE
end
-----------

 

O segundo erro é nos Spells, quando uso os ataques

 

[20/04/2014 12:37:43] [Error - Spell Interface]
[20/04/2014 12:37:43] data/spells/scripts/ps/Confusion.lua:onCastSpell
[20/04/2014 12:37:43] Description:
[20/04/2014 12:37:43] (luaGetThingFromPos) Tile not found

 

[20/04/2014 12:37:46] [Error - Spell Interface]
[20/04/2014 12:37:46] In a timer event called from:
[20/04/2014 12:37:46] data/spells/scripts/ps/Psyusion.lua:onCastSpell
[20/04/2014 12:37:46] Description:

[20/04/2014 12:37:46] (luaGetThingFromPos) Tile not found

 

Confusion.lua

 

function onCastSpell(cid, var)

if isSummon(cid) then return true end

docastspell(cid, "Confusion")

return true
end

 

Psyusion.lua

 

function onCastSpell(cid, var)

if isSummon(cid) then return true end

docastspell(cid, "Psyusion")

return true
end

 

================================ Outros erros ! =============================

 

Bom, agora esta dando um erro no order >.< Aconteçe quando eu mando o Pokémon ir para algum lugar..

 

[20/04/2014 12:59:22] [Error - Action Interface]
[20/04/2014 12:59:22] data/actions/scripts/order.lua:onUse
[20/04/2014 12:59:22] Description:
[20/04/2014 12:59:22] (luaGetCreatureMaster) Creature not found

 

Meu order.lua !

 

local nao = {'4820', '4821', '4822', '4823', '4824', '4825', '1395', '1389', '1391', '1393', '460'}

local direction = {'4', '5', '6', '7'}
-- ridefly
local bolas = {'2222', '2223', '2224'}
local ultra = {'2220', '2221', '2227'}
local etudao = 9506

local mind = 9507

-- LIGHT
local light = {"Uknown", "Dark Abra", "Dark Alakazam", "Shiny Jolteon", "Abra", "Kadabra", "Alakazam", "Magnemite", "Magneton", "Drowzee", "Hypno", "Voltorb", "Electrode", "Mrmime", "Electabuzz", "Jolteon", "Porygon", "Pikachu", "Raichu"}
local exhautStorage = 9500
local time = 600
local cd = 17
-- LIGHT

-- BLINK
local blink = {"Espeon", "Umbreon","Uknown", "Dark Abra", "Dark Alakazam", "Abra", "Kadabra", "Alakazam", "Porygon", "Porygon2", "Mew", "Mewtwo", "MrMime"}
local exhaustblink = 9501
local cdblink = 50
-- BLINK

local systems = {
["rock smash"] = {"Sandshrew", "Sandslash", "Diglett", "Dugtrio", "Primeape", "Machop", "Machoke", "Machamp", "Geodude", "Graveler", "Golem" , "Onix", "Cubone", "Marowak", "Rhyhorn", "Rhydon", "Kangaskhan", "Tauros", "Snorlax", "Poliwrath", "Hitmonlee", "Hitmonchan", "Aerodactyl", "Charizard", "Blastoise", "Typhlosion", "Feraligatr", "Furret", "Ledian", "Ampharos", "Politoed", "Quagsire", "Forretress", "Steelix", "Snubbull", "Granbull", "Sudowoodo", "Gligar", "Scizor", "Heracross", "Sneasel", "Ursaring", "Teddiursa", "Slugma", "Magcargo", "Piloswine", "Swinub", "Corsola", "Phanpy", "Donphan", "Tyrogue", "Hitmontop", "Miltank", "Blissey", "Tyranitar", "Pupitar"},
["cut"] = {"Charmander", "Raticate", "Bulbasaur", "Ivysaur", "Venusaur", "Charmeleon", "Sandshrew", "Sandslash", "Gloom", "Vileplume", "Paras", "Parasect", "Meowth", "Persian", "Bellsprout", "Weepinbell", "Victreebel", "Farfetchd", "Krabby", "Kingler", "Exeggutor", "Cubone", "Marowak", "Tangela", "Scyther", "Pinsir", "Chikorita", "Bayleef", "Meganium", "Croconow", "Feraligatr", "Furret", "Bellossom", "Hoppip", "Skiploom", "Jumpluff", "Sunkern", "Sunflora", "Scizor", "Heracross", "Sneasel", "Teddiursa", "Ursaring", "Gligar", "Skarmory"},
["digholes"] = {"468", "481", "483"},
["dig"] = {"Raticate", "Sandshrew", "Sandslash", "Diglett", "Dugtrio", "Primeape", "Machop", "Machoke", "Machamp", "Geodude", "Graveler", "Golem" , "Onix", "Cubone", "Marowak", "Rhyhorn", "Rhydon", "Kangaskhan", "Tauros", "Snorlax", "Eevee", "Dunsparce", "Flareon", "Jolteon", "Vaporeon", "Espeon", "Umbreon", "Vulpix", "Ninetales", "Nidorina", "Nidoqueen", "Nidorino", "Nidoking", "Persian", "Arcanine"},
["blink"] = {"Abra", "Kadabra", "Alakazam", "Porygon", "Porygon2", "Mew", "Mewtwo", "MrMime"}
}

-------- DITTO E CONTROL MIND ---------

function onUse(cid, item, frompos, item2, topos, item3)
if getPlayerItemCount(cid, item2.itemid) >= 1 then
return false
end
local item = getPlayerSlotItem(cid, 8)
local name = getItemAttribute(item.uid, "nome")
if isPlayerSummon(cid, item2.uid) then
local summon = getCreatureSummons(cid)[1]
if getItemAttribute(item.uid, "nome") == "Ditto" or getItemAttribute(item.uid, "nome") == "Shiny Ditto" then
doCreatureSay(cid, getCreatureName(summon)..", reverse transformation!", 1)
doSendMagicEffect(getCreaturePosition(summon), 184)


doCreatureChangeOutfit(summon, {lookType = 28})

doItemSetAttribute(getPlayerSlotItem(cid, 8).uid, "dittoName", getItemAttribute(item.uid, "nome"))
doItemSetAttribute(getPlayerSlotItem(cid, 8).uid, "dittoOut", getCreatureOutfit(summon).lookType)
setPlayerStorageValue(summon, storages.pokeName, getItemAttribute(item.uid, "nome"))
if getItemAttribute(item.uid, "nome") == "Shiny Ditto" then
doCreatureChangeOutfit(summon, {lookType = 694, lookLegs = getCreatureOutfit(cid).lookBody})
end
return TRUE
end
end

if isMonster(item2.uid) and getPokemonName(getCreatureSummons(cid)[1]) == "Smeargle" then

if not pokes[getPokemonName(item2.uid)] then
return doPlayerSendCancel(cid, "Sorry, this moves of this pokemon don't is copied.")
end

local summon = getCreatureSummons(cid)[1]
if getPlayerLevel(cid) >= pokes[getPokemonName(item2.uid)].level then

setPlayerStorageValue(summon, storages.pokeName, getPokemonName(item2.uid))
doCreatureSay(cid, getCreatureName(summon)..", copie this moves!", 1)
doSendMagicEffect(getThingPos(summon), 14)
doSendMagicEffect(getThingPos(item2.uid), 13)
local name = getPokemonName(item2.uid)
local move = movestable[name]
if move then
if move.move1 then
setPokemonCooldown(cid, 1, 0)
elseif move.move2 then
setPokemonCooldown(cid, 2, 0)
elseif move.move3 then
setPokemonCooldown(cid, 3, 0)
elseif move.move4 then
setPokemonCooldown(cid, 4, 0)
elseif move.move5 then
setPokemonCooldown(cid, 5, 0)
elseif move.move6 then
setPokemonCooldown(cid, 6, 0)
elseif move.move7 then
setPokemonCooldown(cid, 7, 0)
elseif move.move8 then
setPokemonCooldown(cid, 8, 0)
elseif move.move9 then
setPokemonCooldown(cid, 9, 0)
elseif move.move10 then
setPokemonCooldown(cid, 10, 0)
elseif move.move11 then
setPokemonCooldown(cid, 11, 0)
elseif move.move12 then
setPokemonCooldown(cid, 12, 0)
end
end
end

return true
end

if isMonster(item2.uid) and item2.uid ~= getCreatureSummons(cid)[1] and item2.uid ~= cid then
------ \/ ditto
if isCreature(item2.uid) and getPokemonName(getCreatureSummons(cid)[1]) == "Ditto" or isCreature(item2.uid) and getPokemonName(getCreatureSummons(cid)[1]) == "Shiny Ditto" then


if not pokes[getPokemonName(item2.uid)] then
return doPlayerSendCancel(cid, "Sorry, this pokemon don't is copied.")
end

if getItemAttribute(item.uid, "nome") == "Shiny Ditto" then

if not isInArray(shinyNames, "Shiny "..getPokemonName(item2.uid)) then
return doPlayerSendCancel(cid, "Sorry, this pokemon does not have a shiny mutation.")
end

elseif getItemAttribute(item.uid, "nome") == "Ditto" then

if isInArray(shinyNames, getPokemonName(item2.uid)) then
return doPlayerSendCancel(cid, "The ditto can not turn into a pokemon shiny.")
end

end
if getPlayerLevel(cid) >= pokes[getPokemonName(item2.uid)].level then

if getPlayerStorageValue(item2.uid, 202) >= 1 then
doPlayerSendTextMessage(cid, 27, "Sorry, you dont transform your ditto in GYM pokes.")
return true
end

if getItemAttribute(item.uid, "nome") == "Shiny Ditto" then
local nameDitto = "Shiny"
if getPokemonName(item2.uid) == "Charizard" then
nameDitto = "Elder"
end
doCreatureSay(cid, getPokemonName(getCreatureSummons(cid)[1])..", transformation "..nameDitto.." ".. getPokemonName(item2.uid) .."!", 1)
doCreatureSay(cid, "Transform!", TALKTYPE_MONSTER)
doSendMagicEffect(getCreaturePosition(getCreatureSummons(cid)[1]), 184)
doSetCreatureOutfit(getCreatureSummons(cid)[1], {lookType = getPokemonMin(""..nameDitto.." "..getPokemonName(item2.uid))}, -1)
setPlayerStorageValue(getCreatureSummons(cid)[1], storages.pokeName, ""..nameDitto.." "..getPokemonName(item2.uid))
doCureAllStatus(getPlayerSlotItem(cid, 8).uid)
else
doCreatureSay(cid, getPokemonName(getCreatureSummons(cid)[1])..", transformation ".. getPokemonName(item2.uid) .."!", 1)
doCreatureSay(cid, "Transform!", TALKTYPE_MONSTER)
doSendMagicEffect(getCreaturePosition(getCreatureSummons(cid)[1]), 184)
doSetCreatureOutfit(getCreatureSummons(cid)[1], getCreatureOutfit(item2.uid), -1)
setPlayerStorageValue(getCreatureSummons(cid)[1], storages.pokeName, getPokemonName(item2.uid))
doCureAllStatus(getPlayerSlotItem(cid, 8).uid)
end
else
doPlayerSendTextMessage(cid, 27, "Sorry, you need a level ".. pokes[getPokemonName(item2.uid)].level .. " for transform your Ditto in "..getCreatureName(item2.uid)..".")
return true
end
return TRUE
end

------ Control mind \/
if exhaustion.get(cid, mind) then
doPlayerSendCancel(cid, "Seu pokemon está exausto para usar Control MIND, Espere 2 minutos para usar esse move denovo.")
return true
end

if isPlayer(getCreatureMaster(item2.uid)) or isSummon(item2.uid) then
doPlayerSendCancel(cid, "Você só pode usar esse move em pokemons.")
return true
end

if not isInArray({"Shiny Gengar", "Spectral Gengar", "Alakazam", "Haunter", "Dark Alakazam", "Shiny Tentacruel", "Tentacruel", "Gengar", "Ditto", "Shiny Ditto"}, getPokemonName(getCreatureSummons(cid)[1])) then
doPlayerSendCancel(cid, "Este pokemon não tem esse move.")
return true
end

if isWildPokeTrainer(item2.uid) or isWildTrainer(item2.uid) or isPokeGym(item2.uid) then
return doPlayerSendCancel(cid, "This pokemon does control minded.")
end


exhaustion.set(cid, mind, 240)
local summmon = getCreatureSummons(cid)[1]
doCreatureSay(getCreatureSummons(cid)[1], "CONTROL MIND!", TALKTYPE_MONSTER)
doSendDistanceShoot(getThingPos(getCreatureSummons(cid)[1]), getThingPos(item2.uid), 39)
registerCreatureEvent(item2.uid, "Controled")
doSendMagicEffect(getThingPos(item2.uid), 136)
doSendMagicEffect(getThingPos(item2.uid), 134)
doSendMagicEffect(getThingPos(summmon), 133)
setPlayerStorageValue(cid, 61209, getCreatureMaxHealth(summmon))
setPlayerStorageValue(cid, 61210, getCreatureHealth(summmon))
doConvinceCreature(cid, item2.uid)

if getCreatureSpeed(item2.uid) == 0 then
doChangeSpeed(item2.uid, 180)
end

doCreatureSay(cid, getCreatureName(summmon)..", control "..string.lower(getPokemonName(item2.uid)).."'s mind!", 1)

local cmed, cmname, cmpos = item2.uid, getPokemonName(summmon), getThingPos(summmon)
doRemoveCreature(getCreatureSummons(cid)[1])
local cmzao = doSummonCreature(""..cmname.." cm", farAwayPos)
setPlayerStorageValue(cmzao, storages.pokeName, getCreatureName(cmzao))
--/////////////////////////////////////// Nick system
if string.find(tostring(getCreatureName(cmzao)), "Shiny") then
local newName = tostring(getCreatureName(cmzao)):match("Shiny (.*)")
setCreatureName(cmzao, newName, "a "..newName..".")
end

if getItemAttribute(item.uid, "nick") then
setCreatureName(cmzao, getItemAttribute(item.uid, "nick"), "a "..getItemAttribute(item.uid, "nick")..".")
end
--/////////////////////////////////////// Nick system
doTeleportThing(cmzao, cmpos, false)
doConvinceCreature(cid, cmzao)
setPlayerStorageValue(cid, 888, 1)
local function check(params)
if isCreature(params.cid) then

if getPlayerStorageValue(params.cid, 888) <= 0 then
return true
end

if not isCreature(cmed) then
local pkcmpos = getThingPos(getCreatureSummons(cid)[1])
doRemoveCreature(getCreatureSummons(cid)[1])
local item = getPlayerSlotItem(cid, 8)
local pk = doSummonCreature(getItemAttribute(item.uid, "poke"):match("This is (.-)'s pokeball."), farAwayPos)
setPlayerStorageValue(pk, storages.pokeName, getCreatureName(pk))
--/////////////////////////////////////// Nick system
if string.find(tostring(getCreatureName(pk)), "Shiny") then
local newName = tostring(getCreatureName(pk)):match("Shiny (.*)")
setCreatureName(pk, newName, "a "..newName..".")
end

if getItemAttribute(item.uid, "nick") then
setCreatureName(pk, getItemAttribute(item.uid, "nick"), "a "..getItemAttribute(item.uid, "nick")..".")
end
--/////////////////////////////////////// Nick system
doTeleportThing(pk, pkcmpos, false)
doConvinceCreature(cid, pk)
doCreatureSetLookDir(getCreatureSummons(cid)[1], 2)
registerCreatureEvent(pk, "DiePoke")
registerCreatureEvent(pk, "Exp")
registerCreatureEvent(cid, "PlayerPokeDeath")
setCreatureMaxHealth(pk, (getPlayerStorageValue(cid, 61209)))
doCreatureAddHealth(pk, (getPlayerStorageValue(cid, 61209)))
doCreatureAddHealth(pk, (getPlayerStorageValue(cid, 61210))-(getPlayerStorageValue(cid, 61209)))
setPlayerStorageValue(cid, 888, 0)
end

if params.rod == 20 then
local lifecmed = getCreatureMaxHealth(cmed) - getCreatureHealth(cmed)
local poscmed = getThingPos(cmed)
local cmeddir = getCreatureLookDir(cmed)
local namecmed = getPokemonName(cmed)
doRemoveCreature(getCreatureSummons(cid)[1])
local back = doSummonCreature(""..namecmed.."", poscmed)
if getCreatureSpeed(back) == 0 then
doChangeSpeed(back, 180)
end
doCreatureSetLookDir(back, cmeddir)
doCreatureAddHealth(back, -lifecmed)
local item = getPlayerSlotItem(cid, 8)
local mynewpos = getThingPos(getCreatureSummons(cid)[1])
doRemoveCreature(getCreatureSummons(cid)[1])

local pk = doSummonCreature(getItemAttribute(item.uid, "poke"):match("This is (.-)'s pokeball."), farAwayPos)
setPlayerStorageValue(pk, storages.pokeName, getCreatureName(pk))
--/////////////////////////////////////// Nick system
if string.find(tostring(getCreatureName(pk)), "Shiny") then
local newName = tostring(getCreatureName(pk)):match("Shiny (.*)")
setCreatureName(pk, newName, "a "..newName..".")
end

if getItemAttribute(item.uid, "nick") then
setCreatureName(pk, getItemAttribute(item.uid, "nick"), "a "..getItemAttribute(item.uid, "nick")..".")
end
--/////////////////////////////////////// Nick system
doTeleportThing(pk, mynewpos, false)
doConvinceCreature(cid, pk)
doCreatureSetLookDir(getCreatureSummons(cid)[1], 2)
registerCreatureEvent(pk, "DiePoke")
registerCreatureEvent(pk, "Exp")
registerCreatureEvent(cid, "PlayerPokeDeath")
setCreatureMaxHealth(pk, (getPlayerStorageValue(cid, 61209)))
doCreatureAddHealth(pk, (getPlayerStorageValue(cid, 61209)))
doCreatureAddHealth(pk, (getPlayerStorageValue(cid, 61210))-(getPlayerStorageValue(cid, 61209)))
setPlayerStorageValue(cid, 888, 0)
else
doSendMagicEffect(getThingPos(getCreatureSummons(cid)[1]), 220)
end

end

end

for rod = 1, 20 do
addEvent(check, rod*500, {cid = cid, rod = rod})
end

return true
end
-------- DUEL SYSTEM ------------------------
if isPlayer(item2.uid) and (item2.uid ~= cid) and getPlayerStorageValue(item2.uid, 6598754) <= 0 then
---
if #getCreatureSummons(cid) == 0 then
doPlayerSendCancel(cid, "You need a pokemon to inviting this player to duel.")
return true
end

if getPlayerStorageValue(cid, storages.checkFishing) >= 1 then return false end

if getPlayerStorageValue(cid, 52480) >= 1 then
return doPlayerSendTextMessage(cid, 20, "You already invited somebody to duel or already is dueling with somebody")
end
local storages = {17000, 63215, 17001, 13008, 5700}
for s = 1, #storages do
if getPlayerStorageValue(cid, storages) >= 1 then
return doPlayerSendTextMessage(cid, 20, "You can't do that while is Flying, Riding, Surfing, Diving or mount a bike!")
end
end
if getPlayerStorageValue(cid, 6598754) == 1 or getPlayerStorageValue(cid, 6598755) == 1 then
return doPlayerSendTextMessage(cid, 20, "You can't do that while in PVP zone!")
end

function openChannelWithSeconds(cid)
if isCreature(cid) then
if getPlayerVocation(cid) == 8 or getPlayerVocation(cid) == 7 then
openChannelDialog(cid)
end
addEvent(openChannelWithSeconds, 3000, cid)
end
end
---
if tonumber(getPlayerStorageValue(cid, storages.checkPosOfPokeInDuel)) and getPlayerStorageValue(cid, storages.checkPosOfPokeInDuel) >= 1 then
doPlayerSetVocation(cid, 8)
setPlayerStorageValue(cid, storages.checkPosOfPokeInDuel, 0)
else
doPlayerSetVocation(cid, 7)
setPlayerStorageValue(cid, storages.checkPosOfPokeInDuel, 1)
end
openChannelDialog(cid)
setPlayerStorageValue(cid, 52480, 1)
setPlayerStorageValue(cid, 6598754, 5) --alterado v1.6 duel system
setPlayerStorageValue(cid, 52482, getCreatureName(item2.uid))
setPlayerStorageValue(cid, 52483, 0)
doCreatureSetSkullType(cid, 2)
addEvent(openChannelWithSeconds, 3000, cid)
addEvent(endInviting, 40000, cid)
return true

elseif isPlayer(item2.uid) and (item2.uid ~= cid or getRecorderPlayer(topos) ~= cid) and getPlayerStorageValue(item2.uid, 6598754) == 5 then
---
if #getCreatureSummons(cid) == 0 then
doPlayerSendTextMessage(cid, 27,"You need a pokemon to accpet this duel.")
return true
end

if getPlayerStorageValue(item2.uid, 52481) == -1 then
doPlayerSendTextMessage(cid, 27,"Sorry, "..getCreatureName(item2.uid).." don't choosed a quantity of pokemons to duel, wait while this.")
return true
end

if getPlayerStorageValue(cid, 52480) >= 1 then
return doPlayerSendTextMessage(cid, 27, "You already invited somebody to duel or already is dueling with somebody")
end
local storages = {17000, 63215, 17001, 13008, 5700}
for s = 1, #storages do
if getPlayerStorageValue(cid, storages) >= 1 then
return doPlayerSendTextMessage(cid, 27, "You can't do that while is Flying, Riding, Surfing, Diving or mount a bike!")
end
end
if getPlayerStorageValue(cid, 6598754) == 1 or getPlayerStorageValue(cid, 6598755) == 1 then
return doPlayerSendTextMessage(cid, 27, "You can't do that while in PVP zone!")
end
---
local function begin(cid, pid)
if not isCreature(cid) or not isCreature(pid) then return true end
setPlayerStorageValue(cid, 6598754, 10)
setPlayerStorageValue(cid, 52482, getCreatureName(pid))
doSendAnimatedText(getThingPosWithDebug(cid), "START", 215)
doSendAnimatedText(getThingPosWithDebug(pid), "START", 215)
end
---
setPlayerStorageValue(cid, 52480, 1)
setPlayerStorageValue(getRecorderPlayer(topos), 52483, 1)
if getPlayerStorageValue(cid, 52481) <= -1 and getPlayerStorageValue(item2.uid, 52481) >= 0 then
setPlayerStorageValue(cid, 52481, getPlayerStorageValue(item2.uid, 52481))
end
doCreatureSetSkullType(cid, 1)
doCreatureSetSkullType(item2.uid, 1)
doSendAnimatedText(getThingPos(cid), "BATTLE", COLOR_ELECTRIC)
begin(cid, item2.uid, 6)
return true
end
------------------------------------------------------------------------------------


if item2.uid == cid then
if getPlayerStorageValue(cid, 888) >= 1 then
doPlayerSendCancel(cid, "You cant fly neither ride pokemons being controled.")
return true
end

if #getCreatureSummons(cid) == 0 and getPlayerStorageValue(cid, 17000) <= 0 and getPlayerStorageValue(cid, 17001) <= 0 then
doPlayerSendCancel(cid, "You need a pokemon to use order.")
return true
end

if getPlayerStorageValue(cid, 17000) <= 0 and getPlayerStorageValue(cid, 17001) <= 0 and not isInArray(flyAndRides, getPokemonName(getCreatureSummons(cid)[1])) then
doPlayerSendCancel(cid, "You can't ride this pokemon nor fly with it.")
return true
end


-----------------------------
-----------------------------
local function speed(params)

if isCreature(params.cid) then
if isCreature(getCreatureSummons(params.cid)[1]) then
if getCreatureSpeed(getCreatureSummons(params.cid)[1]) == 0 then
doChangeSpeed(getCreatureSummons(params.cid)[1], getCreatureBaseSpeed(getCreatureSummons(cid)[1]))
end
end
end

end
-------- RIDE ---------
if getPlayerStorageValue(cid, 17001) <= 0 and getPlayerStorageValue(cid, 17000) <= 0 and isInArray(specialabilities["ride"], getPokemonName(getCreatureSummons(cid)[1])) then

if getPlayerStorageValue(cid, storages.checkFishing) >= 1 then
doPlayerSendCancel(cid, "You can't ride this pokemon while fishing.")
return true
end

if getPlayerStorageValue(cid, 6598754) >= 1 or getPlayerStorageValue(cid, 6598755) >= 1 then
doPlayerSendCancel(cid, "You can't ride this pokemon while here in pvp.")
return true
end

local pokemon = rides[getCreatureOutfit(getCreatureSummons(cid)[1]).lookType]
if getCreatureSpeed(getCreatureSummons(cid)[1]) >= 1 then
doChangeSpeed(getCreatureSummons(cid)[1], -getCreatureSpeed(getCreatureSummons(cid)[1]))
end
local function ride(params)
if isCreature(params.cid) then
if isCreature(getCreatureSummons(params.cid)[1]) then
if getDistanceBetween(getThingPos(getCreatureSummons(cid)[1]), getThingPos(cid)) <= params.d then
doChangeSpeed(cid, -250)
--doPlayerSendTextMessage(cid, 27, rides[getPokemonMin(getItemAttribute(getPlayerSlotItem(cid, 8).uid, "nome"))][2])
doChangeSpeed(cid, rides[getPokemonMin(getItemAttribute(getPlayerSlotItem(cid, 8).uid, "nome"))][2])
exhaustion.set(cid, etudao, 4)
setPlayerStorageValue(cid, 17001, 1)
setPlayerStorageValue(cid, storages.rideCheck, getCreatureOutfit(getCreatureSummons(cid)[1]).lookType)

local go = false
local pks = getCreatureSummons(cid)[1]
if getCreatureOutfit(pks).lookType == getItemAttribute(getPlayerSlotItem(cid, 8).uid, "addon") then
go = true
out = getItemAttribute(getPlayerSlotItem(cid, 8).uid, "spec")
elseif getCreatureOutfit(pks).lookType == getItemAttribute(getPlayerSlotItem(cid, 8).uid, "addon2") then
go = true
out = getItemAttribute(getPlayerSlotItem(cid, 8).uid, "spec2")
elseif getCreatureOutfit(pks).lookType == getItemAttribute(getPlayerSlotItem(cid, 8).uid, "addon3") then
go = true
out = getItemAttribute(getPlayerSlotItem(cid, 8).uid, "spec3")
elseif getCreatureOutfit(pks).lookType == getItemAttribute(getPlayerSlotItem(cid, 8).uid, "addon4") then
go = true
out = getItemAttribute(getPlayerSlotItem(cid, 8).uid, "spec4")
elseif getCreatureOutfit(pks).lookType == getItemAttribute(getPlayerSlotItem(cid, 8).uid, "addon5") then
go = true
out = getItemAttribute(getPlayerSlotItem(cid, 8).uid, "spec5")
elseif getCreatureOutfit(pks).lookType == getItemAttribute(getPlayerSlotItem(cid, 8).uid, "addon6") then
go = true
out = getItemAttribute(getPlayerSlotItem(cid, 8).uid, "spec6")
elseif getCreatureOutfit(pks).lookType == getItemAttribute(getPlayerSlotItem(cid, 8).uid, "addon7") then
go = true
out = getItemAttribute(getPlayerSlotItem(cid, 8).uid, "spec7")
end
if go then
local item = getPlayerSlotItem(cid, 8)
local color1, color2, color3, color4 = getItemAttribute(item.uid, "color1"), getItemAttribute(item.uid, "color2"), getItemAttribute(item.uid, "color3"), getItemAttribute(item.uid, "color4")
doSetCreatureOutfit(cid, {lookType = out, lookBody = color1, lookHead = color2, lookLegs = color3, lookFeet = color4}, -1)
else
doSetCreatureOutfit(cid, {lookType = pokemon[1], lookHead = color1, lookBody = color2, lookLegs = color3, lookFeet = color4}, -1)
end

setPlayerStorageValue(cid, 61209, getCreatureMaxHealth(getCreatureSummons(cid)[1]))
setPlayerStorageValue(cid, 61210, getCreatureHealth(getCreatureSummons(cid)[1]))
doRemoveCreature(getCreatureSummons(cid)[1])
else
dirh = getDirectionTo(getThingPos(getCreatureSummons(params.cid)[1]), getThingPos(params.cid))
if dirh == NORTHWEST then
if math.random(1,100) >= 51 then
dirh = NORTH
else
dirh = WEST
end
elseif dirh == SOUTHWEST then
if math.random(1,100) >= 51 then
dirh = SOUTH
else
dirh = WEST
end
elseif dirh == SOUTHEAST then
if math.random(1,100) >= 51 then
dirh = SOUTH
else
dirh = EAST
end
elseif dirh == NORTHEAST then
if math.random(1,100) >= 51 then
dirh = NORTH
else
dirh = EAST
end
end
local dirh = dirh
if getCreatureSpeed(getCreatureSummons(params.cid)[1]) == 0 then
doChangeSpeed(getCreatureSummons(params.cid)[1], getCreatureBaseSpeed(getCreatureSummons(cid)[1]))
doPushCreature(getCreatureSummons(params.cid)[1], dirh, 1, 0)
doChangeSpeed(getCreatureSummons(params.cid)[1], -getCreatureSpeed(getCreatureSummons(cid)[1]))
else
doPushCreature(getCreatureSummons(params.cid)[1], dirh, 1, 0)
doChangeSpeed(getCreatureSummons(params.cid)[1], -getCreatureSpeed(getCreatureSummons(cid)[1]))
end
end
end
end
end

doCreatureSay(cid, ""..getCreatureName(getCreatureSummons(cid)[1])..", let me ride you!", 1)
exhaustion.set(cid, etudao, 4)
if getPlayerGroupId(cid) >= 2 and getPlayerGroupId(cid) <= 6 then
distanc = 1
else
distanc = 0
end
local distance = distanc
for i=1,12 do
if not pokemon then
addEvent(ride, getSpeed(getCreatureSummons(cid)[1])*i, {cid = cid, d = distance})
addEvent(speed, getSpeed(getCreatureSummons(cid)[1])*i, {cid = cid})
else
addEvent(ride, pokemon[3]*i, {cid = cid, d = distance})
addEvent(speed, ((pokemon[3]*12)+100), {cid = cid})
end
end
return true
end

-----------------------------

-------- FLY ---------
if getPlayerStorageValue(cid, 17001) >= 1 then
setPlayerStorageValue(cid, 17001, 0)
if getPlayerGroupId(cid) ~= 6 then
setPlayerGroupId(cid, 8)
end
doCreatureSetLookDir(cid, 2)
doChangeSpeed(cid, -(getCreatureSpeed(cid)))
if getPlayerGroupId(cid) >= 2 and getPlayerGroupId(cid) <= 7 then
doChangeSpeed(cid, 400*getPlayerGroupId(cid))
else
doChangeSpeed(cid, 180)
end
doRemoveCondition(cid, CONDITION_OUTFIT)
local item = getPlayerSlotItem(cid, 8)
local monster = doSummonCreature(getItemAttribute(item.uid, "poke"):match("This is (.-)'s pokeball."), farAwayPos, false)
--/////////////////////////////////////// Nick system
if string.find(tostring(getCreatureName(monster)), "Shiny") then
local newName = tostring(getCreatureName(monster)):match("Shiny (.*)")
setCreatureName(monster, newName, "a "..newName..".")
end

if getItemAttribute(item.uid, "nick") then
setCreatureName(monster, getItemAttribute(item.uid, "nick"), "a "..getItemAttribute(item.uid, "nick")..".")
end
--/////////////////////////////////////// Nick system
doTeleportThing(monster, getThingPos(cid))

local pk = monster
doCreatureSay(cid, getCreatureName(pk)..", let me get down!", 1)
doConvinceCreature(cid, pk)
registerCreatureEvent(cid, "PlayerPokeDeath")
registerCreatureEvent(pk, "DiePoke")
registerCreatureEvent(pk, "Exp")
setPlayerStorageValue(pk, storages.pokeName, getItemAttribute(item.uid, "nome"))
setCreatureMaxHealth(pk, (getPlayerStorageValue(cid, 61209)))
doCreatureAddHealth(pk, (getPlayerStorageValue(cid, 61209)))
doCreatureAddHealth(pk, (getPlayerStorageValue(cid, 61210))-(getPlayerStorageValue(cid, 61209)))
if getItemAttribute(item.uid, "addonNow") then
local item = getPlayerSlotItem(cid, 8)
local color1, color2, color3, color4 = getItemAttribute(item.uid, "color1"), getItemAttribute(item.uid, "color2"), getItemAttribute(item.uid, "color3"), getItemAttribute(item.uid, "color4")
doCreatureChangeOutfit(pk, {lookType = getItemAttribute(item.uid, "addonNow"), lookBody = color1, lookHead = color2, lookLegs = color3, lookFeet = color4})
end

doPlayerSendCancel(cid, '12//,show')
addEvent(doUpdateMoves, 50, cid)
return true
end


if getPlayerStorageValue(cid, 17000) >= 1 then
if isInArray({460, 1022, 1023}, getTileInfo(getThingPos(cid)).itemid) then
doPlayerSendCancel(cid, "You can't stop flying at this height!")
return true
end
if getTileInfo(getThingPos(cid)).itemid >= 4820 and getTileInfo(getThingPos(cid)).itemid <= 4825 then
doPlayerSendCancel(cid, "You can't stop fly at this water.!")
return true
end
if getPlayerGroupId(cid) ~= 6 then
setPlayerGroupId(cid, 8)
end
doCreatureSetLookDir(cid, 2)
setPlayerStorageValue(cid, 17000, 0)
doChangeSpeed(cid, -(getCreatureSpeed(cid)))
if getPlayerGroupId(cid) >= 2 and getPlayerGroupId(cid) <= 7 then
doChangeSpeed(cid, 200*getPlayerGroupId(cid))
else
doChangeSpeed(cid, 180)
end
doRemoveCondition(cid, CONDITION_OUTFIT)
local item = getPlayerSlotItem(cid, 8)
local monster = doSummonCreature(getItemAttribute(item.uid, "poke"):match("This is (.-)'s pokeball."), farAwayPos, false)
--/////////////////////////////////////// Nick system
if string.find(tostring(getCreatureName(monster)), "Shiny") then
local newName = tostring(getCreatureName(monster)):match("Shiny (.*)")
setCreatureName(monster, newName, "a "..newName..".")
end

if getItemAttribute(item.uid, "nick") then
setCreatureName(monster, getItemAttribute(item.uid, "nick"), "a "..getItemAttribute(item.uid, "nick")..".")
end
--/////////////////////////////////////// Nick system
doTeleportThing(monster, getThingPos(cid))

local pk = monster
doConvinceCreature(cid, pk)
doCreatureSay(cid, getCreatureName(pk)..", let me get down!", 1)
registerCreatureEvent(cid, "PlayerPokeDeath")
registerCreatureEvent(pk, "DiePoke")
registerCreatureEvent(pk, "Exp")
setPlayerStorageValue(pk, storages.pokeName, getItemAttribute(item.uid, "nome"))
setCreatureMaxHealth(pk, (getPlayerStorageValue(cid, 61209)))
doCreatureAddHealth(pk, (getPlayerStorageValue(cid, 61209)))
doCreatureAddHealth(pk, (getPlayerStorageValue(cid, 61210))-(getPlayerStorageValue(cid, 61209)))
if getItemAttribute(item.uid, "addonNow") then
local item = getPlayerSlotItem(cid, 8)
local color1, color2, color3, color4 = getItemAttribute(item.uid, "color1"), getItemAttribute(item.uid, "color2"), getItemAttribute(item.uid, "color3"), getItemAttribute(item.uid, "color4")
doCreatureChangeOutfit(pk, {lookType = getItemAttribute(item.uid, "addonNow"), lookBody = color1, lookHead = color2, lookLegs = color3, lookFeet = color4})
end
doPlayerSendCancel(cid, '12//,show')
addEvent(doUpdateMoves, 50, cid)
return true
end

if getPlayerStorageValue(cid, 17000) <= 0 and getPlayerStorageValue(cid, 17001) <= 0 and isInArray(specialabilities["fly"], getPokemonName(getCreatureSummons(cid)[1])) then
if getPlayerStorageValue(cid, 17000) <= 0 then

if getPlayerStorageValue(cid, 6598754) >= 1 or getPlayerStorageValue(cid, 6598755) >= 1 then
doPlayerSendCancel(cid, "You can't fly this pokemon while here in pvp.")
return true
end

if getPlayerStorageValue(cid, storages.checkFishing) >= 1 then
doPlayerSendCancel(cid, "You can't fly this pokemon while fishing.")
return true
end

local pokemon = flys[getCreatureOutfit(getCreatureSummons(cid)[1]).lookType]
local function fly(params)
if isCreature(params.cid) then
if isCreature(getCreatureSummons(params.cid)[1]) then
if getDistanceBetween(getThingPos(getCreatureSummons(cid)[1]), getThingPos(cid)) <= params.dd then
doPlayerSendTextMessage(cid, 27, "Type 'up' or 'h1' to fly higher and 'down' or 'h2' to fly lower.")
doPlayerSendCancel(cid, '12//,hide') -- Esconder barra do cooldown
setPlayerStorageValue(cid, 61209, getCreatureMaxHealth(getCreatureSummons(cid)[1]))
setPlayerStorageValue(cid, 61210, getCreatureHealth(getCreatureSummons(cid)[1]))
setPlayerStorageValue(cid, 17000, 1)
doItemSetAttribute(getPlayerSlotItem(cid, 8).uid, "fly", flys[getPokemonMin(getItemAttribute(getPlayerSlotItem(cid, 8).uid, "nome"))][1])
registerCreatureEvent(cid, "Flying")
doChangeSpeed(cid, -250)
doChangeSpeed(cid, flys[getPokemonMin(getItemAttribute(getPlayerSlotItem(cid, 8).uid, "nome"))][2])
exhaustion.set(cid, etudao, 4)
local go = false
local pks = getCreatureSummons(cid)[1]
if getCreatureOutfit(pks).lookType == getItemAttribute(getPlayerSlotItem(cid, 8).uid, "addon") then
go = true
out = getItemAttribute(getPlayerSlotItem(cid, 8).uid, "spec")
elseif getCreatureOutfit(pks).lookType == getItemAttribute(getPlayerSlotItem(cid, 8).uid, "addon2") then
go = true
out = getItemAttribute(getPlayerSlotItem(cid, 8).uid, "spec2")
elseif getCreatureOutfit(pks).lookType == getItemAttribute(getPlayerSlotItem(cid, 8).uid, "addon3") then
go = true
out = getItemAttribute(getPlayerSlotItem(cid, 8).uid, "spec3")
elseif getCreatureOutfit(pks).lookType == getItemAttribute(getPlayerSlotItem(cid, 8).uid, "addon4") then
go = true
out = getItemAttribute(getPlayerSlotItem(cid, 8).uid, "spec4")
elseif getCreatureOutfit(pks).lookType == getItemAttribute(getPlayerSlotItem(cid, 8).uid, "addon5") then
go = true
out = getItemAttribute(getPlayerSlotItem(cid, 8).uid, "spec5")
elseif getCreatureOutfit(pks).lookType == getItemAttribute(getPlayerSlotItem(cid, 8).uid, "addon6") then
go = true
out = getItemAttribute(getPlayerSlotItem(cid, 8).uid, "spec6")
elseif getCreatureOutfit(pks).lookType == getItemAttribute(getPlayerSlotItem(cid, 8).uid, "addon7") then
go = true
out = getItemAttribute(getPlayerSlotItem(cid, 8).uid, "spec7")
end
if go then
local item = getPlayerSlotItem(cid, 8)
local color1, color2, color3, color4 = getItemAttribute(item.uid, "color1"), getItemAttribute(item.uid, "color2"), getItemAttribute(item.uid, "color3"), getItemAttribute(item.uid, "color4")
doSetCreatureOutfit(cid, {lookType = out, lookBody = color1, lookHead = color2, lookLegs = color3, lookFeet = color4}, -1)
else
doSetCreatureOutfit(cid, {lookType = pokemon[1], lookHead = 0, lookAddons = 0, lookLegs = 0, lookBody = 0, lookFeet = 0}, -1)
end
doRemoveCreature(getCreatureSummons(cid)[1])
else
dir = getDirectionTo(getThingPos(getCreatureSummons(params.cid)[1]), getThingPos(params.cid))
if dir == NORTHWEST then
if math.random(1,100) >= 51 then
dir = NORTH
else
dir = WEST
end
elseif dir == SOUTHWEST then
if math.random(1,100) >= 51 then
dir = SOUTH
else
dir = WEST
end
elseif dir == SOUTHEAST then
if math.random(1,100) >= 51 then
dir = SOUTH
else
dir = EAST
end
elseif dir == NORTHEAST then
if math.random(1,100) >= 51 then
dir = NORTH
else
dir = EAST
end
end
local dir = dir
if getCreatureSpeed(getCreatureSummons(params.cid)[1]) == 0 then
doChangeSpeed(getCreatureSummons(params.cid)[1], getCreatureBaseSpeed(getCreatureSummons(cid)[1]))
doPushCreature(getCreatureSummons(params.cid)[1], dir, 1, 0)
doChangeSpeed(getCreatureSummons(params.cid)[1], -getCreatureSpeed(getCreatureSummons(cid)[1]))
else
doPushCreature(getCreatureSummons(params.cid)[1], dir, 1, 0)
doChangeSpeed(getCreatureSummons(params.cid)[1], -getCreatureSpeed(getCreatureSummons(cid)[1]))
end
end
end
end
end

doCreatureSay(cid, ""..getCreatureName(getCreatureSummons(cid)[1])..", let's fly!", 1)
exhaustion.set(cid, etudao, 4)
if getPlayerGroupId(cid) >= 2 and getPlayerGroupId(cid) <= 6 then
distancc = 1
else
distancc = 0
end
local distancee = distancc
for i=1,12 do
if not pokemon then
addEvent(fly, getSpeed(getCreatureSummons(cid)[1])*i, {cid = cid, dd = distancee})
addEvent(speed, ((getSpeed(getCreatureSummons(cid)[1])*12)+100), {cid = cid})
else
addEvent(fly, pokemon[3]*i, {cid = cid, dd = distancee})
addEvent(speed, ((pokemon[3]*12)+100), {cid = cid})
end
end
return true
end
return true
end
end

-----------------------------

-------- ROCK SMASH ---------
if item2.itemid == 1285 and isInArray(systems["rock smash"], getPokemonName(getCreatureSummons(cid)[1])) then

if getMarkedPos(getCreatureSummons(cid)[1]).x == topos.x and getMarkedPos(getCreatureSummons(cid)[1]).y == topos.y then
return true
end

markPos(getCreatureSummons(cid)[1], topos)
markOwnerPos(getCreatureSummons(cid)[1], getThingPos(cid))
doPlayerSay(cid, ""..getCreatureName(getCreatureSummons(cid)[1])..", rock smash!", 1)
addEvent(goThere, 500, getCreatureSummons(cid)[1], topos, "rock smash", isCreature(getCreatureTarget(cid)))

return true
end
-----------------------------


-------- CUT ----------------
if item2.itemid == 2767 and isInArray(systems["cut"], getPokemonName(getCreatureSummons(cid)[1])) then

if getMarkedPos(getCreatureSummons(cid)[1]).x == topos.x and getMarkedPos(getCreatureSummons(cid)[1]).y == topos.y then
return true
end

markPos(getCreatureSummons(cid)[1], topos)
markOwnerPos(getCreatureSummons(cid)[1], getThingPos(cid))
doPlayerSay(cid, ""..getCreatureName(getCreatureSummons(cid)[1])..", cut this!", 1)
addEvent(goThere, 500, getCreatureSummons(cid)[1], topos, "cut", isCreature(getCreatureTarget(cid)))

return true
end
-----------------------------

-------- DIG ----------------
if isInArray(systems["digholes"], item2.itemid) and isInArray(systems["dig"], getPokemonName(getCreatureSummons(cid)[1])) then

if getMarkedPos(getCreatureSummons(cid)[1]).x == topos.x and getMarkedPos(getCreatureSummons(cid)[1]).y == topos.y then
return true
end

markPos(getCreatureSummons(cid)[1], topos)
markOwnerPos(getCreatureSummons(cid)[1], getThingPos(cid))
doPlayerSay(cid, ""..getCreatureName(getCreatureSummons(cid)[1])..", open that hole!", 1)
addEvent(goThere, 500, getCreatureSummons(cid)[1], topos, "dig", isCreature(getCreatureTarget(cid)))

return true
end
-----------------------------

-------- BLINK ----------------
if #getCreatureSummons(cid) == 0 and getPlayerStorageValue(cid, 63215) <= 0 and getPlayerStorageValue(cid, 17000) <= 0 then
doPlayerSendCancel(cid, "You need a pokemon to use order.")
return true
end

if not isMonster(item2.uid) and getPlayerStorageValue(cid, 63215) <= 0 and getPlayerStorageValue(cid, 17000) <= 0 then
if isInArray(blink, getPokemonName(getCreatureSummons(cid)[1])) then
if exhaustion.get(cid, exhaustblink) then
doPlayerSay(cid, ""..getCreatureName(getCreatureSummons(cid)[1])..", move!", 1)
doChangeSpeed(getCreatureSummons(cid)[1], -getCreatureSpeed(getCreatureSummons(cid)[1]))
addEvent(goThere, 500, getCreatureSummons(cid)[1], topos, "move", isCreature(getCreatureTarget(cid)))

if getMarkedPos(getCreatureSummons(cid)[1]).x == topos.x and getMarkedPos(getCreatureSummons(cid)[1]).y == topos.y then
return true
end


markPos(getCreatureSummons(cid)[1], topos)
markOwnerPos(getCreatureSummons(cid)[1], getThingPos(cid))
addEvent(goThere, 500, getCreatureSummons(cid)[1], topos)


else

if not isWalkable(topos, cid, 0, 0) then
doPlayerSendCancel(cid, "Your pokemon cannot teleport there.")
return true
end

if getItemName(item2.uid) == "shallow water" then
doPlayerSendCancel(cid, "Your pokemon cannot teleport there.")
return true
end


local summon = getCreatureSummons(cid)[1] -- Editei aqui \/


if getPokemonName(summon) == "Umbreon" then
pos = {x = getCreaturePosition(summon).x+1, y = getCreaturePosition(summon).y+1, z = getCreaturePosition(summon).z}
doSendMagicEffect(pos, 223)
addEvent(doTeleportThing, 800, summon, topos, false)
else
doSendMagicEffect(getThingPos(summon), 211)
doTeleportThing(summon, topos, false)
addEvent(goThere, 500, summon, topos, "move", isCreature(getCreatureTarget(cid)))
doSendDistanceShoot(getThingPos(summon), topos, 39)
end


if getPokemonName(summon) == "Umbreon" then
pos = {x = topos.x+1, y = topos.y+1, z = topos.z}
addEvent(doSendMagicEffect, 700, pos, 223)
else
doSendMagicEffect(topos, 134)
end

doPlayerSay(cid, ""..getCreatureName(summon)..", teleport there!", 1)
doCreatureSay(summon, "BLINK!", TALKTYPE_MONSTER)
addEvent(goThere, 500, summon, topos, "move", isCreature(getCreatureTarget(cid)))
exhaustion.set(cid, exhaustblink, cdblink)
addEvent(goThere, 500, summon, topos, "move", isCreature(getCreatureTarget(cid)))
return true

end

return true
end

end
-----------------------------

-------- LIGHT ----------------
if isCreature(item2.uid) and getCreatureMaster(item2.uid) == cid and getPlayerStorageValue(cid, 63215) <= 0 and getPlayerStorageValue(cid, 17000) <= 0 and item2.uid ~= cid then
if not isInArray(light, getPokemonName(getCreatureSummons(cid)[1])) then
doPlayerSendCancel(cid, "Esse pokemon não tem LIGHT.")
return true
end
if isInArray(light, getPokemonName(getCreatureSummons(cid)[1])) then
if not isMonster(item2.uid) and getCreatureMaster(item2.uid) ~= cid then
return doPlayerSendCancel(cid,"Por Favor usar LIGHT em seu pokemon.")
end
if exhaustion.get(cid, exhautStorage) then
doPlayerSendCancel(cid,"Por Favor espere alguns segundos para usar LIGHT denovo!")
return true
end
exhaustion.set(cid, exhautStorage, cd)
doPlayerSay(cid, ""..getCreatureName(getCreatureSummons(cid)[1])..", use light!", 1)
doCreatureSay(getCreatureSummons(cid)[1], "LIGHT!", TALKTYPE_MONSTER)
doSendMagicEffect(getThingPos(getCreatureSummons(cid)[1]), 28)
doSetCreatureLight(getCreatureSummons(cid)[1], 8, 215, time*1000)
return true
end
end
-----------------------------

-------- MOVE ---------
if #getCreatureSummons(cid) >= 1 then
if getMarkedPos(getCreatureSummons(cid)[1]).x == topos.x and getMarkedPos(getCreatureSummons(cid)[1]).y == topos.y then
return true
end


markPos(getCreatureSummons(cid)[1], topos)
markOwnerPos(getCreatureSummons(cid)[1], getThingPos(cid))
doPlayerSay(cid, ""..getCreatureName(getCreatureSummons(cid)[1])..", move!", 1)
addEvent(goThere, 500, getCreatureSummons(cid)[1], topos, "move", isCreature(getCreatureTarget(cid)))
return true
end
return true
end
-----------------------------

Se poderem me ajudar, agredeçerei muito :)

Editado por Knowth
Link para o comentário
Compartilhar em outros sites

Spells e Order>>

 

Spells, vc ta usando PDA? se sim vai no map e cria uma casa sem telhado na coordenada x=1/y=1/z=10 e prende entre 4 paredes um Aerodactly na coordenada, o Aero tem q estar exatamente no 1/1/10, salva e reinicia o server...

 

Order vc deve ta usando o OTC 6.3, vc precisa alterar nas sources e coloca uma variavel padrão para os summons e criatures de + ou - 160, no meu editei para 168 fica mais rapido do que o proprio summon e mais lento do que o personagem, pois estão declarados como "0"... (é bem complicado, mais facil baixar um OTC já alterado, como o do StyloMaldoso)...

 

Go/Back>>

Nele não lembro bem, mais vc precisa alterar o tipo de entrada no SQL, colocando como VARCHAR2 ao invez de INT...

Link para o comentário
Compartilhar em outros sites

Spells e Order>>

 

Spells, vc ta usando PDA? se sim vai no map e cria uma casa sem telhado na coordenada x=1/y=1/z=10 e prende entre 4 paredes um Aerodactly na coordenada, o Aero tem q estar exatamente no 1/1/10, salva e reinicia o server...

 

Order vc deve ta usando o OTC 6.3, vc precisa alterar nas sources e coloca uma variavel padrão para os summons e criatures de + ou - 160, no meu editei para 168 fica mais rapido do que o proprio summon e mais lento do que o personagem, pois estão declarados como "0"... (é bem complicado, mais facil baixar um OTC já alterado, como o do StyloMaldoso)...

 

Go/Back>>

Nele não lembro bem, mais vc precisa alterar o tipo de entrada no SQL, colocando como VARCHAR2 ao invez de INT.

Sobre esse erro do Spells, minha base nn é PDA é a base do DxP (DarkXPoke). "Vou esclarecer isso no tópico"

 

Como altero o otc 6.3 nas sources ?

 

E o go/back na onde você se refere, "Colocando como VARCHAR2 ao invez de INT" em que lugar do SQL ?

 

Entre em contato por favor.. Skype: Knowth.gamer

 

esses erros começo quando vc adicionou algum poke?

Não, ainda não fiz nenhuma alteração no servidor, não adicionei pokémons nem sistemas nem nada, só tou resolvendo os erros msm !

Editado por Knowth
Link para o comentário
Compartilhar em outros sites

tem um cara chamado Digo (acho que ele tem conta no xtibia nao.! falo com ele so no skype)

e ele Usa essa Base ;)

 

Esses bugs tudo que você falou...

Ele ja arrumou '-'

tem o bug da Pokedex tbm.. e do fly que buga o poke etc..

e do icone system..

ele ja arrumou '-'

Editado por picapau100
Link para o comentário
Compartilhar em outros sites

tem um cara chamado Digo (acho que ele tem conta no xtibia nao.! falo com ele so no skype)

e ele Usa essa Base ;)

 

Esses bugs tudo que você falou...

Ele ja arrumou '-'

tem o bug da Pokedex tbm.. e do fly que buga o poke etc..

e do icone system..

ele ja arrumou '-'

Me passa o Skype dele ?

Link para o comentário
Compartilhar em outros sites

Oque isso tem a ver com sprite?

Hã ? Sprite ? Acho que você postou no tópico errado não ? '-'

Alguem da staff pode mover o tópico ? Acho que moveram para a área errada !

Link para o comentário
Compartilhar em outros sites

×
×
  • Criar Novo...