• 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!

Action Spell Scroll 100% WORKING!!

Hyresu

Professional Dumb
Joined
Apr 7, 2012
Messages
56
Solutions
8
Reaction score
23
Location
Chile
Hello, this is my first post.... please be nice with me c:
Well... we have to go to YOUROT/data/actions/scripts and create a new .txt file... we will name it sc.lua
and open it...
put in that file this:
Code:
local spell = "[color=red]NAME OF SPELL[/color]"
local words = "[color=blue]WORDS[/color]"
function onUse(cid, item, fromPos, itemEx, toPos)
if getPlayerLearnedInstantSpell(cid, spell) then
doPlayerPopupFYI(cid, "You already know how to cast this spell.")
else
doPlayerLearnInstantSpell(cid, spell)
doRemoveItem(item.uid, 1)
doPlayerPopupFYI(cid, "You learned ... " ..spell.. " for cast it use the words: " ..words.. ".")
end
return true
end
Well... [[sorry for bad english i am chilean c:]]
and open your actions.xml in YOUROT/data/actions
and put this into the file:
Code:
<action itemid="[color=green]ITEMID[/color]" event="script" value="sc.lua"/>
And... you are ok...
BUT!! wait a second you have to edit you script
RED COLOR: PUT YOUR NAME OF SPELL!! NOTE: YOU HAVE TO PUT THE NAME NOT THE WORDS (sc.lua)
BLUE COLOR: PUT THE WORDS OF YOUR SPELL... EXAMPLE: utevo slich (sc.lua)
GREEN COLOR: PUT THE ITEMID OF THE SCRIPT... EXAMPLE 8981 (actions.xml)
And we are done...
___________________________
ADITIONAL:
open YOUROT/mods
create a new file .txt and name it spellscroll.xml
put into the file... this:
Code:
<?xml version="1.0" encoding="UTF-8"?>
<mod name="Spell Scroll" version="1.0" author="Ledtheron" contact="[email protected]" enabled="yes">
    <item id="8189" article="a" name="Spell Scroll">
        <attribute key="weight" value="500" />
        <attribute key="description" value="Use it for learn the spell!!!" />
    </item>
</mod>
You can to use the itemid 8189.. i use...
THX For watching this post... please +REP me... it's my first post..
CREDITS
100% Ledtheron
If you wanna post my post in other forum.. please put credits c:
 
Last edited:
Good code! Try tabbing next time though ;)

Red
 
There's like 40 of these around otland? Why add another?
 
Close it... sorry i didn't see it.... i'm sorry
Admin please close it c:
 
Back
Top