AutoVIP script :eg.reg users above 200gb share will become Vip
 

AutoVIP script :eg.reg users above 200gb share will become Vip

Started by Xtremist, 16 July, 2008, 13:36:10

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Xtremist

AutoVIP script :eg.reg users above 200gb share will become Vip

Please can any 1 make a script like this.
The registered user sharing above 200gb should be made Vip automatically.
:)

CrazyGuy


RegConnected = function(User)
	if Core.GetUserValue(User,16) >= (200*(1024^3)) then
		local tCurProf = ProfMan.GetProfile(User.iProfile)
		if tCurProf.sProfileName ~= "VIP" then
			local tCurReg = RegMan.GetReg(User.sNick)
			local tProfiles = ProfMan.GetProfiles()
			for k in pairs(tProfiles) do
				if tProfiles[k].sProfileName == "VIP" then
					RegMan.ChangeReg(tCurReg.sNick, tCurReg.sPassword, tProfiles[k].iProfileNumber)
					Core.SendPmToUser(User,SetMan.GetString(21),"Your profile has been automatically updated to VIP.|")
				end
			end
		end
	end
end

Xtremist

hey the only thing i have to do is that save it in .lua file and load it.
Isn't it?

Thank you

merlin_xl54

Quote from: Xtremist on 16 July, 2008, 18:58:00
hey the only thing i have to do is that save it in .lua file and load it.
Isn't it?

Yes, copy it and paste it to notepad. Save as .lua and put it in your scripts folder. When you open PtokaX you will see it in the scripts. Check it and you will be all set.

M
Living is easy with eyes closed.

SMF spam blocked by CleanTalk