Ainda não consegui tipo eu clico no bau não aparece msg nenhuma e o bau n abre e n ganho nda , e aproveitando quando eu upo no meu ot o jogo fala sozinho um monte de vezes /reloadcds e acabo ficando mudo como tiro isso?
- Fórum
- xTibia - Notícias e Suporte
- Soluções
- Archived
- Como coloco uma pokebola com um pokemon dentro pra quest ?
Como coloco uma pokebola com um pokemon dentro pra quest ?
Por CayoZanatto, 25 de fev. de 2014 em Archived
info
Grupo: Campones
Registrado: 25/02/14
Posts: 5
Reputação: 0

info
Grupo: Infante
Registrado: 25/01/12
Posts: 1.6k
Reputação: +330

--[[
TAG: <action uniqueid="5945" event="script" value="quests/metang.lua"/>
]]
local conf = {
PokeName = "Metang",
PlayerLevel = 5,
CheckPlayerLevel = true,
--
sto = 12321,
}
function onUse(cid, item, fromPosition, itemEx, toPosition)
if conf.CheckPlayerLevel and getPlayerLevel(cid) > conf.PlayerLevel then
doPlayerSendTextMessage(cid, 27, "voce precisa de level "..conf.PlayerLevel.." para fazer essa quest")
return true
end
if getPlayerStorageValue(cid, conf.sto) == 1 then return true end
local pokemon = conf.pokeName
addPokeToPlayer(cid, pokemon, 0, nil, btype, true)
setPlayerStorageValue(cid, conf.sto, 1)
doPlayerSendTextMessage(cid, 27, "Parabens, voce ganhou o seu pokemon!")
return true
end
Editado Março 3 por StyloMaldoso
info
Grupo: Campones
Registrado: 25/02/14
Posts: 5
Reputação: 0

Parece que funcionou mais eu presciso ter lvl 5 , so 5 pra usar tem como colocar pra 265 em diante?StyloMaldoso, em 03 Mar 2014 - 02:31, disse:
--[[ TAG: <action uniqueid="5945" event="script" value="quests/metang.lua"/> ]] local conf = { PokeName = "Metang", PlayerLevel = 5, CheckPlayerLevel = true, -- sto = 12321, } function onUse(cid, item, fromPosition, itemEx, toPosition) if conf.CheckPlayerLevel and getPlayerLevel(cid) > conf.PlayerLevel then doPlayerSendTextMessage(cid, 27, "voce precisa de level "..conf.PlayerLevel.." para fazer essa quest") return true end if getPlayerStorageValue(cid, conf.sto) == 1 then return true end local pokemon = conf.pokeName addPokeToPlayer(cid, pokemon, 0, nil, btype, true) setPlayerStorageValue(cid, conf.sto, 1) doPlayerSendTextMessage(cid, 27, "Parabens, voce ganhou o seu pokemon!") return true end
info
Grupo: Cavaleiro
Registrado: 24/10/13
Posts: 180
Reputação: +46

Parece que funcionou mais eu presciso ter lvl 5 , so 5 pra usar tem como colocar pra 265 em diante?StyloMaldoso, em 03 Mar 2014 - 02:31, disse:
--[[ TAG: <action uniqueid="5945" event="script" value="quests/metang.lua"/> ]] local conf = { PokeName = "Metang", PlayerLevel = 5, CheckPlayerLevel = true, -- sto = 12321, } function onUse(cid, item, fromPosition, itemEx, toPosition) if conf.CheckPlayerLevel and getPlayerLevel(cid) > conf.PlayerLevel then doPlayerSendTextMessage(cid, 27, "voce precisa de level "..conf.PlayerLevel.." para fazer essa quest") return true end if getPlayerStorageValue(cid, conf.sto) == 1 then return true end local pokemon = conf.pokeName addPokeToPlayer(cid, pokemon, 0, nil, btype, true) setPlayerStorageValue(cid, conf.sto, 1) doPlayerSendTextMessage(cid, 27, "Parabens, voce ganhou o seu pokemon!") return true end
altera PlayerLevel = 5
para PlayerLevel= 265
Editado Março 3 por homersapiens
info
Grupo: Campones
Registrado: 25/02/14
Posts: 5
Reputação: 0

altera PlayerLevel = 5
Parece que funcionou mais eu presciso ter lvl 5 , so 5 pra usar tem como colocar pra 265 em diante?StyloMaldoso, em 03 Mar 2014 - 02:31, disse:
--[[ TAG: <action uniqueid="5945" event="script" value="quests/metang.lua"/> ]] local conf = { PokeName = "Metang", PlayerLevel = 5, CheckPlayerLevel = true, -- sto = 12321, } function onUse(cid, item, fromPosition, itemEx, toPosition) if conf.CheckPlayerLevel and getPlayerLevel(cid) > conf.PlayerLevel then doPlayerSendTextMessage(cid, 27, "voce precisa de level "..conf.PlayerLevel.." para fazer essa quest") return true end if getPlayerStorageValue(cid, conf.sto) == 1 then return true end local pokemon = conf.pokeName addPokeToPlayer(cid, pokemon, 0, nil, btype, true) setPlayerStorageValue(cid, conf.sto, 1) doPlayerSendTextMessage(cid, 27, "Parabens, voce ganhou o seu pokemon!") return true end
para PlayerLevel= 265
eu fiz isso mais so lvl 265 pode pegar a quest , como fasso pra colocar de 265 pra frente
info
Grupo: Infante
Registrado: 25/01/12
Posts: 1.6k
Reputação: +330

local conf = {
PokeName = "Metang",
PlayerLevel = 265,
CheckPlayerLevel = true,
--
sto = 12321,
}
function onUse(cid, item, fromPosition, itemEx, toPosition)
if conf.CheckPlayerLevel and getPlayerLevel(cid) < conf.PlayerLevel then
doPlayerSendTextMessage(cid, 27, "voce precisa de level "..conf.PlayerLevel.." para fazer essa quest")
return true
end
if getPlayerStorageValue(cid, conf.sto) == 1 then return true end
local pokemon = conf.pokeName
addPokeToPlayer(cid, pokemon, 0, nil, btype, true)
setPlayerStorageValue(cid, conf.sto, 1)
doPlayerSendTextMessage(cid, 27, "Parabens, voce ganhou o seu pokemon!")
return true
end



info
Grupo: Artesão
Registrado: 08/08/12
Posts: 126
Reputação: +34
Gênero: Masculino
Não precisa de unique.
Basta adicionar um action id, e colocar uma verificação no script
E na respectiva tag em actions, adicionar o item id do baú, ao invés da action.