Tipo do script: Creaturescript
Protocolo (versão do Tibia):8.7
Servidor utilizado:TFS 0.2.10.0
Nível de experiência: Medio
Adicionais/Informações:
Eu não consigo.. adicionar os script de startskill e nen lowlevellock... no serve de war
eu copiei eles assim so adicionei alguns numero de minha preferencia:
Lowlevellock:
function onLogin(cid)
if getPlayerLevel(cid) < 150 then
doPlayerAddExperience(cid, (getExperienceForLevel(150) - getPlayerExperience(cid)))
end
return TRUE
end
tag:
<eventtype="login"name="LowLevel"event="script"value="lowlevellock.lua"/>
Nesse eu alterei o lvl minimo para 150, mas ele da o erro:
16:14] [Error - CreatureEvent::configureEvent] No valid type for creature event.look
[29/11/2011 15:16:14] Warning: [baseEvents::loadFromXml] Can not configure event
[29/11/2011 15:16:14] Warning: [Event::checkScript] Event onLogin not found. /scripts/lowlevellock.lua
----------------------------------------------------------------------------------------------------------------------------------
E no Startskill e copiei assim:
function onLogin(cid)local playerVoc = getPlayerVocation(cid)
local reqTries = getPlayerRequiredSkillTries
local skillStor = 56364
local gotSkills = getPlayerStorageValue(cid, 56364)
if playerVoc == 1 and gotSkills == -1 then
doPlayerAddSpentMana(cid, (getPlayerRequiredMana(cid,40)))
setPlayerStorageValue(cid, skillStor, 1)
elseif playerVoc == 2 and gotSkills == -1 then
doPlayerAddSpentMana(cid, (getPlayerRequiredMana(cid,40)))
setPlayerStorageValue(cid, skillStor, 1)
elseif playerVoc == 3 and gotSkills == -1 then
doPlayerAddSkillTry(cid, SKILL_DISTANCE, reqTries(cid, SKILL_DISTANCE, 100))
doPlayerAddSkillTry(cid, SKILL_SHIELD, reqTries(cid, SKILL_SHIELD, 80))
doPlayerAddSpentMana(cid, (getPlayerRequiredMana(cid,5)))
setPlayerStorageValue(cid, skillStor, 1)
elseif playerVoc == 4 and gotSkills == -1 then
doPlayerAddSkillTry(cid, SKILL_AXE, reqTries(cid, SKILL_AXE, 95))
doPlayerAddSkillTry(cid, SKILL_SWORD, reqTries(cid, SKILL_SWORD, 95))
doPlayerAddSkillTry(cid, SKILL_CLUB, reqTries(cid, SKILL_CLUB, 95))
doPlayerAddSkillTry(cid, SKILL_SHIELD, reqTries(cid, SKILL_SHIELD, 85))
doPlayerAddMagLevel(cid, 8)
setPlayerStorageValue(cid, skillStor, 1)
end
return TRUE
end
com a tag:
<event type="login" name="StartSkills" script="startskills.lua"/>
e da esse erro :
[29/11/2011 15:24:54] Lua Script Error: [CreatureScript Interface]
[29/11/2011 15:24:54] data/creaturescripts/scripts/startskills.lua:onLogin
[29/11/2011 15:24:54] data/creaturescripts/scripts/startskills.lua:9: attempt to call global 'getPlayerRequiredMana' (a nil value)
[29/11/2011 15:24:54] stack traceback:
[29/11/2011 15:24:54] [C]: in function 'getPlayerRequiredMana'
[29/11/2011 15:24:54] data/creaturescripts/scripts/startskills.lua:9: in function <data/creaturescripts/scripts/startskills.lua:1>
-----------------------------------------------------------------------------------------------------------------------------------
POR FAVOR EU PEÇO A AJUDA DE VOCÊS
E É CLARO... VAI TER +REP