Bem, eu fiz ai um Script e como to iniciando no ramo, deu uns "probrema".
Já postei um topico por aqui de um erro no mesmo NPC, mas agora veio outro erro.
E juro que to postando mas não foi por falta de tentaviva, porque já revirei esse Script e não teve jeito do erro sair.
SCRIPT:
local keywordHandler = KeywordHandler:new()local npcHandler = NpcHandler:new(keywordHandler)
NpcSystem.parseParameters(npcHandler)
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
npcHandler:setMessage(MESSAGE_GREET, "Hi, |PLAYERNAME|. Better that has disturbed me for good reason, because Im thirsty for blood.")
if msgcontains(msg, "book of magic") then
if getPlayerStorageValue(cid,8569) == 1 then
if getPlayerFreeCap(cid) < getItemWeight(6120,1) then
selfSay("I can not give you something that does not hold charge!", cid)
else
selfSay("The book that old witch? It may take, we can not understand a written as old.", cid)
doPlayerAddItem(cid, 6120, 1)
setPlayerStorageValue(cid, 8569, 2)
end
elseif getPlayerStorageValue(cid, 8569) >= 2 then
selfSay("Are you crazy? I already gave you the damn book!", cid)
else
SelfSay("I do not know what book is talking about. Get out of my way now!", cid)
end
end
talkState[talkUser] = 0
npcHandler:addModule(FocusModule:new())
ERRO:
[Warning - NpcScript::NpcScript] Can not load script: data/npc/scripts/test.luadata/npc/scripts/test.lua:1: unexpected symbol near ' '
Agradeço muito mesmo á quem vir ajudar a selecionar esse problema.
Valeu.