ta ae mano ta igual vc pedio vc só prescisa editar oq esta em NEGRITO e se vc quiser as mensagens :smile_positivo:
local keywordHandler = KeywordHandler:new()local npcHandler = NpcHandler:new(keywordHandler)
NpcSystem.parseParameters(npcHandler)
local talkState = {}
local itemid = 2120
local pos = {x= 500, y= 500, z=7}
local count = 1
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
if msgcontains(msg, 'travel') then
selfSay("Oh great, do you have "..getItemArticleById(itemid).." "..getItemNameById(itemid).."?")
talkState[talkUser] = 1
end
if msgcontains(msg, 'yes') then
if talkState[talkUser] == 1 then
if getPlayerItemCount(cid, itemid) >= count then
doTeleportThing(cid, pos)
doPlayerRemoveItem(cid, itemid, 1)
doSendMagicEffect(getCreaturePosition(cid), 10)
talkState[talkUser] = 0
else
selfSay("Sorry, you don´t have "..getItemArticleById(itemid).." "..getItemNameById(itemid)..".")
talkState[talkUser] = 0
end
end
end
if msgcontains(msg, 'no') then
if talkState[talkUser] == 1 then
selfSay("Come back when you get "..getItemArticleById(itemid).." "..getItemNameById(itemid)..".")
talkState[talkUser] = 0
end
end
return TRUE
end
npcHandler:setCallback(CALLBACK_MESSAGE_DEFAULT, creatureSayCallback)
npcHandler:addModule(FocusModule:new())
e enquanto criar guilds eh por npc ou por comandos?



info
Grupo: Campones
Registrado: 24/06/08
Posts: 23
Reputação: 0
po n sei se é possivel fazer um npc que pra ele te teleporta pro lugar que vc quer vc precisa ter o item se vc n tiver ele fala vc precisa ter tal item pra ir tal lugar, tipo que ele fale no defaut com vc e n no npc channel,ou se isso n for possivel tbm pode ser no npc channel.
e outro no meu ot sempre que eu tento fazer guild nele se bota la o nome tudo direitinho e aparece "invalid characters" alguma coisa parecida, e n cria a guild,alguem ae sabe oq pode ser???
vlw ae!
Editado Julho 17 por Khost