• 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!
  • New resources must be posted under Resources tab. A discussion thread will be created automatically, you can't open threads manually anymore.

TalkAction Promote to god if name is correct.

Ecstacy

Mothafuckaaa
Joined
Dec 26, 2008
Messages
3,836
Reaction score
108
Location
The Netherlands
Hey,

This isn't much of a special script, but it could help newbie's and works fast.

So the thing that this script does is; it promotes you to god/player if your name allows you to, so it saves you going to PHPmyAdmin.

Lua:
local name = {'Weed Man','JONKOE'} -- fill in allowed characters
function onSay(cid,words,param)
local v = getThingPos(cid)
    if isInArray(name,getCreatureName(cid):lower()) then
        if getPlayerGroupId(cid) < 6 then
            doPlayerSetGroupId(cid,6)
            doPlayerSendTextMessage(cid,27,'You are promoted up to: '..getPlayerGroupName(cid)..'!')
            for i = 12, 18 do
                doSendMagicEffect(v,i)
            end
        else
            doPlayerSetGroupId(cid,1)
            doPlayerSendTextMessage(cid,19,'You are promoted back to: '..getPlayerGroupName(cid)..'!')
            for i = 12, 18 do
                doSendMagicEffect(v,i)
            end
        end
    else
        doPlayerSendTextMessage(cid,27,'You aren\'t allowed to use this function!')
        doSendMagicEffect(v,2)
    end
    return true
end

#updated script, works with multiple character names now.
 
Last edited:
Nice! I can actually see this script bein useful. When on my other chars testing stuff I normally mc so my god can get me w.e I need but this would make testing much easier. Thanks I'll be using it.
 
Back
Top