FLAG
 

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

FLAG

Started by Annie, 17 June, 2008, 08:45:16

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Annie

hiya ive got a lua of a flag that goes up timed in main I was wondering could somebody convert it for me please so it works with the new hub software, thanks :D

--[[ 
 *********************  name: Line builder in main chat 5.0-5.1 *********************
********************* by [NL]Daddy-Bear?  made in 2006  ********************* 

]]
			
--  *********************   Settings   ********************* 

k = 0					-- Yust a ccounter don't chance
kk = 2				-- Yust a ccounter don't chance
delay = 50000			-- Interval between announcements.   (1000 = 4.75 min)
CommOn = "+lon"			-- Start the script.
CommOff = "+loff"		-- Stop the script.
StartOn = "1"			-- Start script by starting this lua  ["1"=yes "0"=no]

-- *********************   End off Settings   ********************* 

Bot = ""	-- Name for bot

function Main()
frmHub:RegBot(Bot) 
SetTimer(50)  			-- Yust a ccounter don't chance  !!!
	if StartOn == "1" then
		StartTimer()
	end
end

function ChatArrival(user, data)
	s,e,cmd = string.find(data, "%b<>%s+(%S+)(%S+)")
	if (cmd==CommOn) and user.bOperator then
		user:SendData(Bot,"\r\n\r\n\t--<< Text script has started >>--\r\n\r\n")
		StartTimer()
	return 1
	elseif (cmd==CommOff) and user.bOperator then
		StopTimer()   
		user:SendData(Bot,"\r\n\r\n\t--<< Text script has stopped >>--\r\n\r\n")
	return 1
	end
end

function OnTimer()
k = k + 1
if k == 300 * kk then
		SendToAll("")
		end
if k == 301 * kk then
		SendToAll("  UK HUB ")
		end
if k == 302 * kk then
		SendToAll(" ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::")
		end
if k == 303 * kk then
		SendToAll(" ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::")
		end
if k == 304 * kk then
		SendToAll(" ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::")
		end
if k == 305 * kk then
		SendToAll(" ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::")
		end
if k == 306 * kk then
		SendToAll(" ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::")
		end
if k == 307 * kk then
		SendToAll(" ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::")
		end
if k == 308 * kk then
		SendToAll(" ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::")
		end
if k == 309 * kk then
		SendToAll(" :::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::")
		end
if k == 310 * kk then
		SendToAll(" ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::")
		end
if k == 311 * kk then
		SendToAll(" ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::")
		end
if k == 312 * kk then
		SendToAll(" ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::")
		end
if k == 313 * kk then
		SendToAll(" ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::")
		end
if k == 314 * kk then
		SendToAll(" ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::")
		end
if k == 315 * kk then
		SendToAll(" ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::")
		end
if k == 316 * kk then
		SendToAll(" ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::")
		end
if k == 317 * kk then
		SendToAll("  Welcome to  ")
		end
if k == 318 * kk then
		SendToAll("")
		end
if k == 319 * kk then
		SendToAll("")
		end

-- Here is a  delay between the two lines  (time is the count from 310 to 600)		 
if k == 996* kk then 
		SendToAll("") 
		end		 
if k == 997* kk then 
		SendToAll("")  
		end 
if k == 998* kk then  
		SendToAll("")
		end 
if k == 999* kk then 
		SendToAll("")
		end 
if k == 1000* kk then 
		SendToAll("") 
		end 
if k == 1001* kk then 
		SendToAll("")
	              end
if k == 1002* kk then 
		SendToAll("")
		end 
if k == 1003* kk then 
		SendToAll("")
		end 
if k == 1004* kk then 
		SendToAll("") 
		end  
	if k == delay then k = 0 
	        end 
end

SMF spam blocked by CleanTalk