• 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!
  • 2026 staff recruitment is open! Check it out and consider applying!

Skill Scroll

Teddy

SweStream.se
Joined
Oct 2, 2008
Messages
3,797
Reaction score
10
Location
Sweden 172
I have a xp scroll .. now iam looking for a skill scroll that add 5 skills to all skills
 
Here you go :)
Code:
local itemID = 7723 ---- Item ID you use.
local xp = 10000000 ---- How much exp it will give.
local level = 250 -------From this level and less he can use this item.
function onUse(cid, item, frompos, item2, topos)
if item.itemid == itemID and getPlayerLevel(cid) <= level then
doPlayerAddExp(cid, xp)
doCreatureSay(cid, words, 1)
doRemoveItem(cid, item.uid, 1)
doCreatureSay(cid, "CONGRATULATIONS! You gained 10,000,000 EXP from the EXP SCROLL!. ", TALKTYPE_ORANGE_1)
else
doPlayerSendCancel(cid, "Sorry but you are to high lvl to use this scroll")
end
return 1
end
 
I think it would be something like this: (NOT SURE) try it out..

Replace this line:
doPlayerAddExp(cid, xp)

With:
Code:
 doPlayerAddSkill(cid, sword)

I'm not sure.. but something like that would increase sword fighting..
 
something like this?

LUA:
local config = {maxlvl = 250, trys = 50, skilltype = 2}

-- SKILLTYPE == FIST = 0, CLUB = 1, SWORD = 2, AXE = 3, DISTANCE = 4, SHIELD = 5

function onUse(cid, item, fromPosition, itemEx, toPosition)
    if getPlayerLevel(cid) <= config.maxlvl then
	doPlayerAddSkillTry(cid, config.skilltype, config.trys)
        doRemoveItem(item.uid, 1)
      	doPlayerSendTextMessage(cid,TALKTYPE_BROADCAST, "CONGRATULATIONS! You gained ".. config.trys .." SKILL TRYS from the SKILL SCROLL!.")
    else
        doPlayerSendCancel(cid, "Your level is too high.")
    end
  return TRUE
end
 
Back
Top