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

GlobalEvent VIP system fixed.

wlj

retierd
Joined
Jan 7, 2009
Messages
1,201
Reaction score
1
Hiho first i wanna say i rly need reps ;)
Localconfig
Lets goto actions.xml and add...
PHP:
	<action uniqueid="1337" script="tools/VIP Door.lua"/>
	<action itemid="5785" script="tools/VIP Item.lua"/>
Now we go scripts/tools and we add ... 2 .lua files 1 VIP Item.lua and 1 VIP Door.lua
~~~~~~~~~~~~~~~~~~~
the Item script...
PHP:
function onUse(cid, item, frompos, item2, topos)

if item.itemid == 5785 then
if getPlayerLevel(cid) > 1 then
getPlayerStorageValue(cid, 1337)
doSendAnimatedText(getPlayerPosition(cid), "Welcome!", TEXTCOLOR_RED) 
doCreatureSay(cid, "CONGRATULATIONS! You are now a VIP! You can now enter the VIP-area and use unique features!. ", TALKTYPE_ORANGE_1)
setPlayerStorageValue(cid, 1337, 1)
doRemoveItem(item.uid, 1)
else
doPlayerSendCancel(cid,'You are not a donator.')
doRemoveItem(item.uid, 1)
end
else
end
return 1
end

Vip Door
PHP:
function onUse(cid, item, frompos, item2, topos)
if item.uid == 1337 then -- This number you will imput into map editor for the door you wish
queststatus = getPlayerStorageValue(cid,1337) -- Quest number that needs to be COMPLETE.
area = {x=1000, y=1000, z=7} -- If that above quest is complete, It will teleport you here.
if queststatus == -1 then
doCreatureSay(cid, "Sorry, but only VIP Players can pass here! Buy VIP on the WEB!. [homepage of server also the shop page!] ", TALKTYPE_ORANGE_1)
else
doTeleportThing(cid, area,0)
doSendMagicEffect(topos, 12)
doCreatureSay(cid, "Hiho VIP Player,On server!", TALKTYPE_ORANGE_1)
end
end
return 1
end

Rep++:wub::wub:

smaller oncs

PHP:
local storage = 1337

function onUse(cid, item, frompos, item2, topos)
        if getPlayerStorageValue(cid, sotrage) == -1 then
                doCreatureSay(cid, "CONGRATULATIONS! You are now a VIP! You can now enter the VIP-area and use unique features!. ", TALKTYPE_ORANGE_1)
                setPlayerStorageValue(cid, storage, 1)
                doRemoveItem(item.uid, 1)
        else
                doPlayerSendCancel(cid,'You are already a donator.') 
        end
        return TRUE
end

PHP:
local storage = 1234
function onUse(cid, item, frompos, item2, topos)
    if item.uid == 1337 and getPlayerStorageValue(cid, storage) == -1 then
        doCreatureSay(cid, "Sorry, but only VIP Players can pass here! Buy VIP on the WEB!. [homepage of server also the shop page!]", TALKTYPE_ORANGE_1) 
    else
        doSendMagicEffect(topos, 12) 
        doCreatureSay(cid, "Hiho VIP Player, On server!", TALKTYPE_ORANGE_1) 
    end
    return TRUE
end
 
Last edited:
function onUse(cid, item, frompos, item2, topos)

if item.itemid == 5785 then -- dont needed
if getPlayerLevel(cid) > 1 then -- dont needed
getPlayerStorageValue(cid, 1337) -- dont needed
doSendAnimatedText(getPlayerPosition(cid), "Welcome!", TEXTCOLOR_RED) -- dont needed (I thing its door)
doCreatureSay(cid, "CONGRATULATIONS! You are now a VIP! You can now enter the VIP-area and use unique features!. ", TALKTYPE_ORANGE_1)
setPlayerStorageValue(cid, 1337, 1)
doRemoveItem(item.uid, 1)
else -- dont needed
doPlayerSendCancel(cid,'You are not a donator.') -- dont needed
doRemoveItem(item.uid, 1) -- dont needed
end -- dont needed
else -- dont needed
end -- dont needed
return 1
end

Lol, Fixed one.:
Lua:
local storage = 1337

function onUse(cid, item, frompos, item2, topos)
	if getPlayerStorageValue(cid, sotrage) == -1 then
		doCreatureSay(cid, "CONGRATULATIONS! You are now a VIP! You can now enter the VIP-area and use unique features!. ", TALKTYPE_ORANGE_1)
		setPlayerStorageValue(cid, storage, 1)
		doRemoveItem(item.uid, 1)
	else
		doPlayerSendCancel(cid,'You are already a donator.') 
	end
	return TRUE
end

VIP door:
Lua:
local config = { -------------------------------------------
-- Quest number that needs to enter the door ---------------

storage = 1337,

------------------------------------------------------------
newPos = { -------------------------------------------------
-- It will teleport you here -------------------------------

x = 1000, 
y = 1000, 
z = 7,

------------------------------------------------------------
}} ---------------------------------------------------------

function onUse(cid, item, frompos, item2, topos)
	if config.storage == -1 then
		doCreatureSay(cid, "Sorry, but only VIP Players can pass here! Buy VIP on the WEB!. [homepage of server also the shop page!] ", TALKTYPE_ORANGE_1)
	else
		doTeleportThing(cid, config.newPos)
		doSendMagicEffect(config.newPos, 10)
		doCreatureSay(cid, "Hiho VIP Player!", TALKTYPE_ORANGE_1)
	end
	return TRUE
end

Regards,
Shawak

EDIT: GlobalEvents, Spells & CreatureEvents ?? :huh:
 
Last edited:
Door

Lua:
local storage = 1234
function onUse(cid, item, frompos, item2, topos)
    if item.uid == 1337 and getPlayerStorageValue(cid, storage) == -1 then
	doCreatureSay(cid, "Sorry, but only VIP Players can pass here! Buy VIP on the WEB!. [homepage of server also the shop page!]", TALKTYPE_ORANGE_1) 
    else
	doSendMagicEffect(topos, 12) 
	doCreatureSay(cid, "Hiho VIP Player, On server!", TALKTYPE_ORANGE_1) 
    end
    return TRUE
end
 
Code:
function onUse(cid, item, frompos, item2, topos)

topos = {x = 300, y = 45, z = 6}
area = {x = 300, y = 45, z = 6}

    if item.uid == 11551 and getPlayerStorageValue(cid, 11551) == -1 then
        doCreatureSay(cid, "Sorry, but only VIP Players can pass here! Buy VIP on the WEB!. [homepage of server also the shop page!]", TALKTYPE_ORANGE_1) 
    else
doTeleportThing(cid, area)
       doSendMagicEffect(topos, 10) 
        doCreatureSay(cid, "Hiho VIP Player, On server!", TALKTYPE_ORANGE_1) 
    end
    return TRUE
end

a little script and working 100% xP
 
its the doors all knows to script the doors -.-
 
does it have to be a door or can it be a title? or something?
 
does it have to be a door or can it be a title? or something?

Lua:
local config = { -------------------------------------------
-- Quest number that needs to enter the door ---------------

storage = 1337,

------------------------------------------------------------
newPos = { -------------------------------------------------
-- It will teleport you here -------------------------------

x = 1000, 
y = 1000, 
z = 7,

------------------------------------------------------------
}} ---------------------------------------------------------

function onUse(cid, item, frompos, item2, topos)
        if config.storage == -1 then
                doCreatureSay(cid, "Sorry, but only VIP Players can pass here! Buy VIP on the WEB!. [homepage of server also the shop page!] ", TALKTYPE_ORANGE_1)
        else
                doTeleportThing(cid, config.newPos)
                doSendMagicEffect(config.newPos, 10)
                doCreatureSay(cid, "Hiho VIP Player!", TALKTYPE_ORANGE_1)
        end
        return TRUE
end
 
Lua:
local config = { -------------------------------------------
-- Quest number that needs to enter the door ---------------

storage = 1337,

------------------------------------------------------------
newPos = { -------------------------------------------------
-- It will teleport you here -------------------------------

x = 1000, 
y = 1000, 
z = 7,

------------------------------------------------------------
}} ---------------------------------------------------------

function onUse(cid, item, frompos, item2, topos)
        if config.storage == -1 then
                doCreatureSay(cid, "Sorry, but only VIP Players can pass here! Buy VIP on the WEB!. [homepage of server also the shop page!] ", TALKTYPE_ORANGE_1)
        else
                doTeleportThing(cid, config.newPos)
                doSendMagicEffect(config.newPos, 10)
                doCreatureSay(cid, "Hiho VIP Player!", TALKTYPE_ORANGE_1)
        end
        return TRUE
end

The only good thing in this thread...and guess what? Any nub lua scripter can do it :thumbup:
 

Similar threads

Back
Top