Você precisa postar o código do Goback.lua.
info
Grupo: Lorde
Registrado: 05/06/12
Posts: 2.2k
Reputação: +215
Gênero: Masculino

info
Grupo: Visconde
Registrado: 18/03/19
Posts: 390
Reputação: +22
Gênero: Masculino
Char no Tibia: Rafersiq

4 horas atrás, Yan Oliveira disse:Você precisa postar o código do Goback.lua.
ok
o codigo da goback.lua
Citarlocal EFFECTS = {
["Magmar"] = 35,
["Shiny Magmar"] = 35,
["Jynx"] = 17,
["Shiny Jynx"] = 17,
["Piloswine"] = 205,
["Swinub"] = 205,
}function onUse(cid, item, frompos, item2, topos)
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 v1.9 <<
return true
end
local serialx = getItemAttribute(item.uid, "serial")
if not serialx then
doRegisterSerial(item.uid, cid)
-- doPlayerSendTextMessage(cid, 27, "[Segurança]: Seu pokémon foi registrado e está pronto para ser usado.")
-- return true
end
local ballName = getItemAttribute(item.uid, "poke")
if not ballName then return true end
local btype = getPokeballType(item.itemid)
local usando = pokeballs[btype].use
-- ATTR restore system
-- Boosts
if getItemAttribute(item.uid, "boost") then
if (serialx and getPokemonBoosts(serialx) == 0) and (getItemAttribute(item.uid, "boost") ~= 0) then
updateBoosts(item.uid)
end
if (serialx and getPokemonBoosts(serialx) ~= 0) and (serialx and getPokemonBoosts(serialx) ~= getItemAttribute(item.uid, "boost")) then
updateBoosts(item.uid)
end
elseif (serialx and getPokemonBoosts(serialx) ~= 0) then
doItemSetAttribute(item.uid, "boost", getPokemonBoosts(serialx))
end
-- Addons
if getItemAttribute(item.uid, "addons") then
if (serialx and getPokemonEAddon(serialx) == 0) and (getItemAttribute(item.uid, "addons") ~= 0) then
updateAddons(item.uid)
end
if (serialx and getPokemonEAddon(serialx) ~= 0) and (serialx and getPokemonEAddon(serialx) ~= getItemAttribute(item.uid, "addons")) then
updateAddons(item.uid)
end
elseif (serialx and getPokemonEAddon(serialx) ~= 0) then
doItemSetAttribute(item.uid, "addons", getPokemonEAddon(serialx))
end
-- Nick
if getItemAttribute(item.uid, "nick") then
if (serialx and getPokemonMote(serialx) == "None") and (getItemAttribute(item.uid, "nick") ~= 0) then
updateNick(item.uid)
end
if (serialx and getPokemonMote(serialx) ~= "None") and (serialx and getPokemonMote(serialx) ~= getItemAttribute(item.uid, "nick")) then
updateNick(item.uid)
end
elseif (serialx and getPokemonMote(serialx) ~= "None") then
doItemSetAttribute(item.uid, "nick", getPokemonMote(serialx))
end
-- Unique
if getItemAttribute(item.uid, "unique") then
if (serialx and getUniqueOwner(serialx) == 0) and (getItemAttribute(item.uid, "unique") ~= 0) then
updateUniqueOwner(item.uid)
end
if (serialx and getUniqueOwner(serialx) ~= 0) and (serialx and getUniqueOwner(serialx) ~= getItemAttribute(item.uid, "unique")) then
updateUniqueOwner(item.uid)
end
elseif (serialx and getUniqueOwner(serialx) ~= "Admin") then
doItemSetAttribute(item.uid, "unique", getUniqueOwner(serialx))
end
local effect = pokeballs[btype].effect
if not effect then
effect = 21
endif not getItemAttribute(item.uid, "tadport") and ballName then
doItemSetAttribute(item.uid, "tadport", fotos[ballName])
end
-- unLock(item.uid) --alterado v1.8
if item.itemid == pokeballs[btype].off then
doPlayerSendCancel(cid, "Este pokemon está desmaiado.")
return true
elseif item.itemid == usando then
if getPlayerStorageValue(cid, 990) == 1 then -- GYM
doPlayerSendCancel(cid, "Você não pode devolver seu pokemon durante as batalhas de academia.")
return true
end
if #getCreatureSummons(cid) > 1 and getPlayerStorageValue(cid, 212124) <= 0 then --alterado v1.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, "Você não pode fazer isso enquanto está controlando uma mente")
return true
end
if #getCreatureSummons(cid) <= 0 then
if isInArray(pokeballs[btype].all, item.itemid) then
doTransformItem(item.uid, pokeballs[btype].off)
doItemSetAttribute(item.uid, "hp", 0)
doPlayerSendCancel(cid, "Este pokemon está desmaiado.")
return true
end
endlocal 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)
doSendPlayerExtendedOpcode(cid, 82, "h")elseif item.itemid == pokeballs[btype].on then
if item.uid ~= getPlayerSlotItem(cid, CONST_SLOT_FEET).uid then
doPlayerSendCancel(cid, "Você deve colocar sua pokeball no lugar correto!")
return TRUE
endif tonumber(getPlayerStorageValue(cid, 18391)) == 1 or tonumber(getCreatureStorage(cid, 15215)) == 1 then
doPlayerSendCancel(cid, "Não é possível puxar o pokemon pra fora da ball enquanto estiver no carro!")
return true
end
if getPlayerStorageValue(cid, 12511) == 1 then
return doPlayerSendCancel(cid, "Não é possível puxar o pokemon pra fora da ball enquanto estiver de carona!")
endif getPlayerStorageValue(cid, 18393) == 1 then
doPlayerSendCancel(cid, "Não é possível puxar o pokemon pra fora da ball enquanto estiver na moto!")
return true
endlocal thishp = getItemAttribute(item.uid, "hp")
if getItemAttribute(item.uid, "hp") == 0 then
if isInArray(pokeballs[btype].all, item.itemid) then
doTransformItem(item.uid, pokeballs[btype].off)
doItemSetAttribute(item.uid, "hp", 0)
doPlayerSendCancel(cid, "Este pokemon está desmaiado.")
return true
end
endlocal pokemon = getItemAttribute(item.uid, "poke")
if not pokes[pokemon] then
return true
endlocal x = pokes[pokemon]
local pk = getCreatureSummons(cid)[1]
local boost = getItemAttribute(item.uid, "boost") or 0if getPlayerLevel(cid) < (x.level+boost) then
doPlayerSendCancel(cid, "Você precisa de nível "..(x.level+boost).." para usar este pokemon.")
return true
end
local pk = getCreatureSummons(cid)[1]
doSummonMonster(cid, pokemon)
if serialx and getPokeballOwner(serialx) ~= getPlayerName(cid) then
updatePokeballOwner(cid, getPlayerName(cid), serialx)
end
doItemSetAttribute(item.uid, "pokeballusada", 0)local pk = getCreatureSummons(cid)[1]
if not isCreature(pk) then return true end
local boost = getItemAttribute(item.uid, "boost") or 0
local pokelvl = getItemAttribute(item.uid, "new_level") or 1
if not pokelvl or (pokelvl and type(pokelvl) ~= "number") or (pokelvl and tonumber(pokelvl) <= 0) then
pokelvl = 1
end
setPlayerStorageValue(pk, 3213, boost)
local outfit = getPokeOutfitColors(item.uid, getPokemonName(pk), "normal")
doSetCreatureOutfit(pk, outfit, -1)
if getCreatureNameSecurity(pk) == "Ditto" or getCreatureNameSecurity(pk) == "Shiny Ditto" then --edited
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"))
addEvent(function()
if isCreature(pk) and item and item.uid and item.uid > 1 then
if getItemAttribute(item.uid, "transTurn") then
deTransform(pk, getItemAttribute(item.uid, "transTurn"))
end
end
end, left * 1000)
doItemSetAttribute(item.uid, "transBegin", os.clock())
else
setPlayerStorageValue(pk, 1010, getCreatureNameSecurity(pk) == "Ditto" and "Ditto" or "Shiny Ditto") --edited
end
end
---------- Level System - OrochiElf
local level = getItemAttribute(item.uid, "new_level") or 1
local experience = getItemAttribute(item.uid, "new_experience") or 0
doMonsterSetLevel(pk, level, experience)
registerCreatureEvent(pk, "PokemonAdvance")if isGhostPokemon(pk) then doTeleportThing(pk, getPosByDir(getThingPos(cid), math.random(0, 7)), false) end
doCreatureSetLookDir(pk, 2)
doCreatureSetNick(pk, nick)
adjustStatus(pk, item.uid, true, true, true)
doAddPokemonInOwnList(cid, pokemon)doTransformItem(item.uid, item.itemid+1)
local pokename = getPokeName(pk)
local mgo = gobackmsgs[math.random(1, #gobackmsgs)].go:gsub("doka", pokename)
local mgoen = gobackmsgsen[math.random(1, #gobackmsgsen)].go:gsub("doka", pokename)
local mgoes = gobackmsgses[math.random(1, #gobackmsgses)].go:gsub("doka", pokename)
if getPlayerLanguage(cid) == 2 then
doCreatureSay(cid, mgoen, 19)
end
if getPlayerLanguage(cid) == 0 then
doCreatureSay(cid, mgo, 19)
end
if getPlayerLanguage(cid) == 1 then
doCreatureSay(cid, mgoes, 19)
end
if getItemAttribute(item.uid, "ballorder") then
doPlayerSendCancel(cid, "KGT,"..getItemAttribute(item.uid, "ballorder").."|".."0")
doPlayerSendCancel(cid, "")
end
---------movement magmar, jynx-------------
if EFFECTS[getCreatureNameSecurity(pk)] then
markPosEff(pk, getThingPos(pk))
sendMovementEffect(pk, EFFECTS[getCreatureNameSecurity(pk)], getThingPos(pk))
end
doSendMagicEffect(getCreaturePosition(pk), effect)
if useOTClient then
-- doPlayerSendCancel(cid, '12//,show')
doPlayerSave(cid)
local owner = getCreatureMaster(cid)
doOTCSendPokemonHealth(owner)
doUpdatePokemonsBar(cid)
end
local pk = getCreatureSummons(cid)[1]
local pb = getPlayerSlotItem(cid, 8).uid
local look = getItemAttribute(pb,"addon")
if not getItemAttribute(pb,"addon") then
doSetItemAttribute(pb,"addon",0)
end
if getItemAttribute(pb,"addon") > 0 then
doSetCreatureOutfit(pk, {lookType = look}, -1)
end
else
doPlayerSendCancel(cid, "Este pokemon está desmaiado.")
return true
endif useKpdoDlls then
doUpdateMoves(cid)
doPlayerSendCancel(cid, "")
end
return true
end
info
Grupo: Lorde
Registrado: 05/06/12
Posts: 2.2k
Reputação: +215
Gênero: Masculino

Posta o código desses dois arquivos: data/lib/004-database.lua e data/lib/056-SecuritySystem.lua.


info
Grupo: Visconde
Registrado: 18/03/19
Posts: 390
Reputação: +22
Gênero: Masculino
Char no Tibia: Rafersiq
bom dia ha todos estou aki com um problema com o goback quando eu usso a pokebar pra chamar um pokemom e vou chamalo pelo inventario da um erro
se alçuem poder me ajudar eu agradeço
Editado Janeiro 17 por rafersiq