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

I Want All Best Vip System For Tibia 8.6

YES I have

SQL

Code:
ALTER TABLE `accounts` ADD
`vipdays` int(11) NOT NULL DEFAULT 0;

movement
Code:
function onStepIn(cid, item, position, fromPosition)
        if getPlayerVipDays(cid) == 0 then
            doTeleportThing(cid, fromPosition, FALSE)
        end
return true
end

action
Code:
function onUse(cid, item, frompos, item2, topos)
if getPlayerVipDays(cid) >= 1 then
pos = getPlayerPosition(cid)
if pos.x == topos.x then
if pos.y < topos.y then
pos.y = topos.y + 1
else
pos.y = topos.y - 1
end
elseif pos.y == topos.y then
if pos.x < topos.x then
pos.x = topos.x + 1
else
pos.x = topos.x - 1
end
else
doPlayerSendTextMessage(cid,22,"Stand in front of the door.")
return true
end
doTeleportThing(cid,pos)
doSendMagicEffect(topos,12)
else
doPlayerSendTextMessage(cid,22,'Only VIP Account can go there.')
end
return true
end

Code:
function onUse(cid, item, fromPosition, itemEx, toPosition)
        if getPlayerVipDays(cid) > 365 then
            doPlayerSendCancel(cid, "You can only have 1 year of VIP account or less.")
        else
            doAddVipDays(cid, 30)
            doCreatureSay(cid, "Too much money I am VIP!")
            doPlayerPopupFYI(cid, "We have added 30 VIP days to your account!\nEnjoy it!.")
            doRemoveItem(item.uid)
        end
        return true
end




Creature script

Code:
function onLogin(cid)
        if getPlayerVipDays(cid) >= 1 then
            doPlayerSendTextMessage(cid, 19, "You have ".. getPlayerVipDays(cid) .." vip days left.")
        end
        return true
end


login.lua

registerCreatureEvent(cid, "VipCheck")
 
Create a new lua
inside creature scripts

function onLogin(cid)
if getPlayerVipDays(cid) >= 1 then
doPlayerSendTextMessage(cid, 19, "You have ".. getPlayerVipDays(cid) .." vip days left.")
end
return true
end
 
Back
Top