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

Heey i got a question about VIP

gurden

i need support for my server, good scripter!
Joined
May 19, 2009
Messages
519
Reaction score
5
Location
Sweden
Heey i got a VIP items that gives EXP, Exp scroll. And i wonder if someone got a script that makes it inpossible to take more then 3-4 scripts. So people wont be level 1000 if he got alot of money xD

I give ++rep ofc


my code is...

Code:
function onUse(cid, item, fromPosition, itemEx, toPosition)
		
if getPlayerStorageValue(cid,1800) == 10 then
			doCreatureSay(cid, "You have already recieved this power!", TALKTYPE_ORANGE_1)

	else if getPlayerLevel(cid) >= 8 then
		doCreatureSay(cid, "You Gained Alot of Experience Points, Thanks for donating!", TALKTYPE_ORANGE_1)
			doPlayerAddExp(cid, 15694800)
			doSendMagicEffect(fromPosition, CONST_ME_GIFT_WRAPS)
			doRemoveItem(item.uid)
			setPlayerStorageValue(cid,1800,2)
			return TRUE
		else
					doCreatureSay(cid, "You must be over level 8 to use this scroll", TALKTYPE_ORANGE_1)
		end
end
end
 
LUA:
function onUse(cid, item, fromPosition, itemEx, toPosition)
local config = {
storageV = 1800,
storage = getPlayerStorageValue,
uses = 5
}

		if getPlayerStorageValue(cid,config.storageV) == config.uses then
			doCreatureSay(cid, "You have already recieved this power!", TALKTYPE_ORANGE_1) 
	elseif getPlayerLevel(cid) >= 8 then
		doCreatureSay(cid, "You Gained Alot of Experience Points, Thanks for donating!", TALKTYPE_ORANGE_1)
			doPlayerAddExp(cid, 15694800)
			doSendMagicEffect(fromPosition, CONST_ME_GIFT_WRAPS)
			doRemoveItem(item.uid)
			setPlayerStorageValue(cid,config.storageV,config.storage+1)
		else
		    doCreatureSay(cid, "You must be over level 8 to use this scroll", TALKTYPE_ORANGE_1)
		end
	return TRUE	
end
 
Back
Top