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

Premium PLayer Login lv 120

Stewie

Family Guy # ;3
Joined
May 3, 2010
Messages
786
Reaction score
12
Location
TV
i wanna player premium when log get level 120 automaticly



srry for bad english
 
put this in the login.lua
LUA:
if isPremium(cid) then
 if getPlayerLevel(cid) < 120 then
 doPlayerAddlevel(cid, 120 - getPlayerLevel(cid))
end
end
 
Code:
<?xml version="1.0" encoding="UTF-8"?>
<mod name="Premium Advance" version="1.0" author="JDB" contact="[email protected]" enabled="yes">
	<config name="premium_config"><![CDATA[
		config = {
			storage = 34555
		}
	]]></config>
	<event type="login" name="PremiumAdvance" event="buffer"><![CDATA[
		domodlib('premium_config')
		if(getPlayerStorageValue(cid, config.storage) > 0) then
			return
		end

		if isPremium(cid) then
			doPlayerAddLevel(cid, 120 - getPlayerLevel(cid))
		end
		
		[COLOR="red"]setPlayerStorageValue(cid, config.storage, 1)[/COLOR]
	]]></event>
</mod>

If you are using 0.4 you can change the red to this.

Code:
doCreatureSetStorage(cid, config.storage, 1)
 
Back
Top