anti VIP for LUA 5
 

News:

29 December 2022 - PtokaX 0.5.3.0 (20th anniversary edition) released...
11 April 2017 - PtokaX 0.5.2.2 released...
8 April 2015 Anti child and anti pedo pr0n scripts are not allowed anymore on this board!
28 September 2015 - PtokaX 0.5.2.1 for Windows 10 IoT released...
3 September 2015 - PtokaX 0.5.2.1 released...
16 August 2015 - PtokaX 0.5.2.0 released...
1 August 2015 - Crowdfunding for ADC protocol support in PtokaX ended. Clearly nobody want ADC support...
30 June 2015 - PtokaX 0.5.1.0 released...
30 April 2015 Crowdfunding for ADC protocol support in PtokaX
26 April 2015 New support hub!
20 February 2015 - PtokaX 0.5.0.3 released...
13 April 2014 - PtokaX 0.5.0.2 released...
23 March 2014 - PtokaX testing version 0.5.0.1 build 454 is available.
04 March 2014 - PtokaX.org sites were temporary down because of DDOS attacks and issues with hosting service provider.

Main Menu

anti VIP for LUA 5

Started by Ubikk, 15 June, 2005, 18:49:02

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Ubikk

Hey guys.. :)
I would like a script that blockes unregistered VIPs from entering the hub... ( fake [-VIP-] tags...) This script was done in LUA 4 but I haven't found a version for LUA 5 yet...

This is the old script.. :

Quote--##Simple Non-VIP Blocking 1.1

--##Made by blackwings

--##If a non-VIP has these in the username = VIP,Vip or vip, the user will get disconnected



bot="robotzel"



function DataArrival(User , data)

   if strsub(data, 1, 7) == "$MyINFO"  and User.iProfile ~= 2 then   

      if strfind(data, "VIP") then

         User:SendData(bot," Remove VIP from your nick!")

         User:Disconnect()

      elseif strfind(data, "vip") then

         User:SendData(bot," Remove VIP from your nick!")

         User:Disconnect()

      elseif strfind(data, "Vip") then

         User:SendData(bot," Remove VIP from your nick!")

         User:Disconnect()

             
      end

   end

end
[/size]

Thanks a lot :)

jiten

Give this a try:
--###############################################--
-- Simple VIP Check -- By NightLitch 2004-12-23 --
-- Updated:
-- - Checks for users that should not have [VIP] or [REG]
-- in the Nickname.
-- Advanced Tags: [__V--i--P__}, {_V_]i[_P_}
-----
-- Converted to LUA 5 by blackwings
--###############################################--
BotName = "[HubSecurity]"
--###############################################--
function MyINFOArrival(sUser,sData)
	local _,_,sTag = string.find(string.lower(sData), "[%[%{%(](%S+)[%]%}%)]")
	if sTag then
		if string.find(string.lower(sTag), "%p*v%p*i%p*p%p*") and sUser.iProfile ~= 2 then
			sUser:SendData(BotName, "You are not registered here, Remove VIP Tag from your nickname! Accounts are deleted after 6 weeks of inactivity, if yours was feel free to re-enter and re-register. Tag: "..sTag)
			sUser:Disconnect()
		end
	end
end
--###############################################--
--// NightLitch

Best regards

Ubikk

Thanks for the fast reply and sorry for not posting in the LUA 5 section  :D

blackwings

#3
use this if you also want to check for fake REG users =
function MyINFOArrival(sUser,sData)
	local _,_,sTag = string.find(string.lower(sData), "[%[%{%(](%S+)[%]%}%)]")
	if sTag then
		if string.find(string.lower(sTag), "%p*v%p*i%p*p%p*") and sUser.iProfile ~= 2 then
			sUser:SendData(BotName, "Remove VIP Tag from your nickname! - Example of a REG tag = [VIP]")
			sUser:Disconnect()
		elseif string.find(string.lower(sTag), "%p*r%p*e%p*g%p*") and sUser.iProfile ~= 3 then
			sUser:SendData(BotName, "Remove REG Tag from your nickname! - Example of a REG tag = [REG]")
			sUser:Disconnect()
		end
	end
end


Ubikk

Thanks you  blackwings ... I'm glad to see how helpful are the  users of this forum   :)

SMF spam blocked by CleanTalk