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

!bless Not Working Please Help

Well i dont know if u even got this script but first what you need to do is :
1.add in .../data/talkactions/talkactions.xml
this line :
Code:
<talkaction words="!bless" script="bless.lua"/>
2.Now go to .../data/talkactions/scripts and add a file bless.lua
3.In bless.lua write :
Code:
function onSay(cid, words, param)
    if getPlayerBlessing(cid, 1) or getPlayerBlessing(cid, 2) or getPlayerBlessing(cid, 3) or getPlayerBlessing(cid, 4) or getPlayerBlessing(cid, 5) then
        doPlayerSendCancel(cid,'You have already got one or more blessings!')
    else
        if doPlayerRemoveMoney(cid, 50000) == TRUE then
            doPlayerAddBlessing(cid, 1)
            doPlayerAddBlessing(cid, 2)
            doPlayerAddBlessing(cid, 3)
            doPlayerAddBlessing(cid, 4)
            doPlayerAddBlessing(cid, 5)
			doSendMagicEffect(getPlayerPosition(cid), CONST_ME_HOLYDAMAGE)
            doPlayerSendTextMessage(cid,MESSAGE_EVENT_ADVANCE,'You have been blessed by the gods!')
        else
            doPlayerSendCancel(cid, "You need 5 crystal coin to get blessed!")
        end
    end
    return 1
end
And it should work fine now.
If You want to change that all blesses cost for exemple 10k edit
that one
Code:
doPlayerRemoveMoney(cid, 50000)
for that one
Code:
doPlayerRemoveMoney(cid, 10000)
 
Back
Top