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

Add custom spell sprite to ur ot problem -_-

Hashirama479

World of Ninja
Joined
Dec 19, 2016
Messages
536
Solutions
6
Reaction score
74
I have a problem with adding a custom spell sprite to my server also I added it to object builder and compiled then I did regirst the custom spell at source "const.h" and then I compiled then after all was done I tried to cast the spell but it didnt work it says there just from 0-69 effects etc xD must I regirst the spell somewhere else?
 
Solution
CONST_ME_LAST is defined in lib/000-constant.lua
add your magic effect like so:
CONST_ME_NAME = number
where name is the name you want it to be and the number is the number you put in enums.h
change it from CONST_ME_INSECTS (68) to the one you defined
CONST_ME_LAST = CONST_ME_NAME
LUA:
function onSay(cid, words, param, channel)
    param = tonumber(param)
    if(not param or param < 0 or param > CONST_ME_LAST) then
        doPlayerSendCancel(cid, "Numeric param may not be lower than 0 and higher than " .. CONST_ME_LAST .. ".")
        return true
    end

    doSendMagicEffect(getCreaturePosition(cid), param)
    return true
end

? Theres no number 69 or something like that just the "last"
 
CONST_ME_LAST is defined in lib/000-constant.lua
add your magic effect like so:
CONST_ME_NAME = number
where name is the name you want it to be and the number is the number you put in enums.h
change it from CONST_ME_INSECTS (68) to the one you defined
CONST_ME_LAST = CONST_ME_NAME
 
Solution
Back
Top