1º Duvida
Eu adicionei ao servidor o Shiny Mr. Mime, porem nao consigo dar catch, ao tentar o catch da um erro console.
Eu coloquei o id do corporse no lib\configuration.lua (nao sei ao certo se é aqui que tem que adicionar o id do corporse)
porem notei que la contia uns id muitcho loco que nao correspondiao aos id do corporse
ex:
["Mr. Mime"] = {chance = 1500, corpse = 6069},
porem o id do Corporse é 11922
Queria saber qual id ou onde eu acho o id para dar catch na Shiny Mr. Mime
o id do corporse é 12602
Erro Console:
[30/10/2012 23:53:15] [Error - Action Interface]
[30/10/2012 23:53:15] data/actions/scripts/catch.lua:onUse
[30/10/2012 23:53:15] Description:
[30/10/2012 23:53:16] data/actions/scripts/catch.lua:30: attempt to index field '?' (a nil value)
[30/10/2012 23:53:16] stack traceback:
[30/10/2012 23:53:16] data/actions/scripts/catch.lua:30: in function <data/actions/scripts/catch.lua:8>
Script /actions/scripts/catch.lua
local ballcatch = {
[2394] = {cr = 3, on = 24, off = 23, ball = 11826, send = 47, typeee = "normal"},
[2391] = {cr = 6, on = 198, off = 197, ball = 11832, send = 48, typeee = "great"},
[2393] = {cr = 10, on = 202, off = 201, ball = 11835, send = 46, typeee = "super"},
[2392] = {cr = 15, on = 200, off = 199, ball = 11829, send = 49, typeee = "ultra"},
}
function onUse(cid, item, frompos, item3, topos)
local item2 = getTopCorpse(topos)
if item2 == null then
return true
end
if getItemAttribute(item2.uid, "catching") == 1 then
return true
end
if getItemAttribute(item2.uid, "golden") and getItemAttribute(item2.uid, "golden") == 1 then
return doPlayerSendCancel(cid, "You can't try to catch a pokemon in the Golden Arena!") --alterado v2.6
end
local name = string.lower(getItemNameById(item2.itemid))
name = string.gsub(name, "fainted ", "")
name = string.gsub(name, "defeated ", "")
local x = pokecatches[doCorrectPokemonName(name)]
--------------------------------------------------------------------------------
local storage = newpokedex[doCorrectPokemonName(name)].stoCatch --edited brokes count system
if getPlayerStorageValue(cid, storage) == -1 then
setPlayerStorageValue(cid, storage, "normal = 0, great = 0, super = 0, ultra = 0, saffari = 0")
end
--------------------------------------------------------------------------------
if not x then return true end
local owner = getItemAttribute(item2.uid, "corpseowner")
if owner and isCreature(owner) and isPlayer(owner) and cid ~= owner then --alterado v1.5
doPlayerSendCancel(cid, "You are not allowed to catch this pokemon.")
return true
end
-----------------------------------------------------
newidd = ballcatch[item.itemid].ball
typeee = ballcatch[item.itemid].typeee
-----------------------------------------------------
local catchinfo = {}
catchinfo.rate = ballcatch[item.itemid].cr
catchinfo.catch = ballcatch[item.itemid].on
catchinfo.fail = ballcatch[item.itemid].off
catchinfo.newid = newidd
catchinfo.name = doCorrectPokemonName(name)
catchinfo.topos = topos
catchinfo.chance = x.chance
doSendDistanceShoot(getThingPos(cid), topos, ballcatch[item.itemid].send)
doRemoveItem(item.uid, 1)
local d = getDistanceBetween(getThingPos(cid), topos)
addEvent(doSendPokeBall, d * 70 + 100 - (d * 14) , cid, catchinfo, false, false, typeee) --edited brokes count system
addEvent(doSendMagicEffect, (d * 70 + 100 - (d * 14)) - 100, topos, 3)
return true
end
2º Duvida boba
Onde eu diminuo o tempo de soltar !love
;X
3º Duvida, eu tentei adicionar novos fly como o Fly no gengar e etc..
porem tive o mesmo problema com o looktype no /libs/configuration.lua, o looktype que esta la é diferente do looktype no .dat
Ex:
["Crobat"] = {652, 1190}, -- crobat
porem o looktype (olhando com dat editor) é 1003
repetindo
"Queria saber qual looktype ou onde eu acho o looktype para dar fly em gengar
o looktype do fly é 1538"
Obrigado agradeço desde ja