Postado Abril 21, 2016 9 anos Funciona bem só tem um erro 11638, 13462 a 13469 são box cada um da o poke de acordo com cada box e configurei cada bau no rme em na box pra da o pokemon certo funciona normal só que quando abre a box ela abre e aparece na bag novamente agora se eu batalhar uma vez eu não consigo mais abrir :D starterpokes = { [11638] = {poke = "Charmander"}, [13462] = {poke = "Cyndaquil"}, [13463] = {poke = "Chikorita"}, [13464] = {poke = "Totodile"}, [13465] = {poke = "Bulbasaur"}, [13466] = {poke = "Squirtle"}, [13467] = {poke = "Chimchar"}, [13468] = {poke = "Turtwig"}, [13469] = {poke = "Piplup"}, } local btype = "normal" function onUse(cid, item, frompos, topos) if getPlayerLevel(cid) > 5 then --alterado v1.3 return true end local pokemon = "" if starterpokes[item.itemid] then pokemon = starterpokes[item.itemid].poke end if pokemon == "" then return true end if getPlayerStorageValue(cid, 9658754) ~= 1 then --alterado v1.7 -opicional- sendMsgToPlayer(cid, 27, "Talk to the Prof. Robert to choose your beginner city first!") return true end local gender = getRandomGenderByName(pokemon) local happy = 250 doPlayerAddItem(cid, 2394, 0) local item = doCreateItemEx(2219) doItemSetAttribute(item, "poke", pokemon) doItemSetAttribute(item, "hp", 1) doItemSetAttribute(item, "happy", happy) doItemSetAttribute(item, "gender", gender) doItemSetAttribute(item, "description", "Contains a "..pokemon..".") doItemSetAttribute(item, "fakedesc", "Contains a "..pokemon..".") doItemSetAttribute(item, "unique", getCreatureName(cid)) --alterado v1.6 doPlayerAddItemEx(cid, item, true) doTransformItem(item, pokeballs[btype].on) doPlayerSendTextMessage(cid, 27, "You got your first pokemon! You also received some pokeballs to help you in your way.") doPlayerSendTextMessage(cid, 27, "Don\'t forget to use your pokedex on every undiscovered pokemon!") doTeleportThing(cid, getTownTemplePosition(getPlayerTown(cid))) return TRUE end
Participe da conversa
Você pode postar agora e se cadastrar mais tarde. Se você tem uma conta, faça o login para postar com sua conta.