@Christinacsa
Lembra de colocar a codificação ANSI no notpad pra não bugar os acêntos
local keywordHandler = KeywordHandler:new()
local npcHandler = NpcHandler:new(keywordHandler)
NpcSystem.parseParameters(npcHandler)
local talkState = {}
function onCreatureAppear(cid) npcHandler:onCreatureAppear(cid) end
function onCreatureDisappear(cid) npcHandler:onCreatureDisappear(cid) end
function onCreatureSay(cid, type, msg) npcHandler:onCreatureSay(cid, type, msg) end
function onThink() npcHandler:onThink() end
function creatureSayCallback(cid, type, msg)
if(not npcHandler:isFocused(cid)) then
return false
end
local talkUser = NPCHANDLER_CONVBEHAVIOR == CONVERSATION_DEFAULT and 0 or cid
local config = {
item1 = 13507, -- ID DO Item que precisara para trocar
qt1 = 1000, -- Quantidade do item1 que precisa
sto = 166666, -- Storage não mecher
}
if(msgcontains(msg, 'yes' )) then
if getPlayerStorageValue(cid, config.sto) == -1 then
if getPlayerItemCount(cid, config.item1) >= config.qt1 then
selfSay('Você pagou a entrada oara a {PERFECT NAVE}', cid)
setPlayerStorageValue(cid, config.sto, 1)
doRemoveItem(cid, config.item1, config.qnt1)
else
selfSay('Você não tem o item necessario {Furie Coins}', cid)
end
else
selfSay(' voce ja fez' , cid)
return true
end
end
end