• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

Help Me, Script skill.! plx

wopex

New Member
Joined
Jun 6, 2010
Messages
2
Reaction score
0
sorry if you do not understand, but use the google translator.!

I have a server of war but to die down I skill, and check in the Data / Creaturescript / Scripts / Starskill And I have this:

Code:
OnLogin function (cid)
Local playerVoc = getPlayerVocation (cid)
Local reqTries = getPlayerRequiredSkillTries
Local skillStor = 56364
Local gotSkills = getPlayerStorageValue (cid, 56364)


if playerVoc == 5 and gotSkills == -1 then
doPlayerAddSpentMana (cid, (getPlayerRequiredMana (cid, 60)))
setPlayerStorageValue (cid, skillStor, 1)

elseif playerVoc == 6 and gotSkills == -1 then
doPlayerAddSpentMana (cid, (getPlayerRequiredMana (cid, 60)))
setPlayerStorageValue (cid, skillStor, 1)

elseif playerVoc == 7 and gotSkills == -1 then
doPlayerAddSkillTry (cid, SKILL_DISTANCE, reqTries (cid, SKILL_DISTANCE, 85))
doPlayerAddSkillTry (cid, SKILL_SHIELD, reqTries (cid, SKILL_SHIELD, 65))
doPlayerAddSpentMana (cid, (getPlayerRequiredMana (cid, 10)))
setPlayerStorageValue (cid, skillStor, 1)

elseif playerVoc == 8 and gotSkills == -1 then
doPlayerAddSkillTry (cid, SKILL_AXE, reqTries (cid, SKILL_AXE, 80))
doPlayerAddSkillTry (cid, SKILL_SWORD, reqTries (cid, SKILL_SWORD, 80))
doPlayerAddSkillTry (cid, SKILL_CLUB, reqTries (cid, SKILL_CLUB, 80))
doPlayerAddSkillTry (cid, SKILL_SHIELD, reqTries (cid, SKILL_SHIELD, 65))
doPlayerAddMagLevel (cid, 8)
setPlayerStorageValue (cid, skillStor, 1)

end
return TRUE
end

[IMG]http://i39.tinypic.com/flbigl.png[/IMG]

Says the knight can not lower than 8 and not magiclevel asii if down. - DoPlayerAddMagLevel (cid, 8) besides also not listed with 80 appears with more skills.! not because it does not work well if the scrip or something else.
 
Last edited:
I just want a player is not the skills to die down,

- - - Updated - - -

Solo Qiero que no se le bajen skills al jugador al morir,
 
On your login.lua (data/creaturescripts/scripts) there's a line like this:
LUA:
doPlayerSetLossPercent(cid, PLAYERLOSS_EXPERIENCE, loss * 10)
Add below:
LUA:
doPlayerSetLossPercent(cid, PLAYERLOSS_SKILLS, 0)
You can add it to your starskill.lua instead of login.lua.
 
Back
Top