About my Bot....Wont Return 1 commands...
 

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

About my Bot....Wont Return 1 commands...

Started by EXNET OWNER, 29 September, 2004, 01:31:32

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

EXNET OWNER

i have the following code...

function exNewUserConnected(user)
	if user.sName == WhoCan then
		customCMDS(user)
		user:SendData("\r\n***AnarchyBot? is in Operation***")
	else
		return

	end
end


function customCMDS(user)
	user:SendData("$UserCommand 1 3 AnarchyBot? by Exile\\Bot Status\\Bot Exit Hub $<%[mynick]> "..DropCmd.." 

%[line:BotName]||")
	user:SendData("$UserCommand 1 3 AnarchyBot? by Exile\\Bot Status\\Bot Enter Hub $<%[mynick]> "..AddCmd.." 

%[line:BotName]||")
	user:SendData("$UserCommand 1 3 AnarchyBot? by Exile\\Bot Status\\Bot Status Away $<%[mynick]> "..AwayCmd.." 

%[line:BotName]||")
	user:SendData("$UserCommand 1 3 AnarchyBot? by Exile\\Bot Status\\Bot Status Back $<%[mynick]> "..BackCmd.." 

%[line:BotName]||")
end

function exDataArrival(user, data)
	if user.sName == WhoCan then
		if strsub(data,1,1)=="<" then
			data=strsub(data,1,strlen(data)-1) 
			s,e,cmd,name = strfind(data,"%b<>%s+(%S+)%s+(%S+)") 
				if cmd == DropCmd then 
					frmHub:UnregBot(name)
					SendToAll("<"..name.."> I'm gone blud")
					SendToAll("<"..name.."> -=1=-")
					SendToAll(" The Operator "..name.." Left The Hub")
					
return 1
end
				if cmd == AddCmd then 
					frmHub:RegBot(name)
					SendToAll(" The Operator "..name.." Has Entered The Hub")
					SendToAll("<"..name.."> Safe evry1, wots gwanin?")

return 1
end
                                if cmd == AwayCmd then
				frmHub:RegBot(name)
				SendToAll("<"..name.."> "..AwayMsg.."")
				SendToAll("<"..name.."> -=1=-")
				SendToAll(" The Operator "..name.." told us at "..date("%H:%M").." that he/she 

is away! - Message: BL?$$")
				
return 1
end
				if cmd == BackCmd then
				frmHub:RegBot(name)
				SendToAll("<"..name.."> "..BackMsg.."")
				SendToAll(" The Operator "..name.." returned at "..date("%H:%M").."!")

return 1

end
end
end
end

                               

when i execute the commands they show in main, i dont want them to, the prefix for all of them is "!" so it should as i have put return 1 after the command...any ideas?

plop

"return 1" the moment the script is done in the ptokax standard functions (newuserbla, databla).

plop
http://www.plop.nl lua scripts/howto\'s.
http://www.thegoldenangel.net
http://www.vikingshub.com
http://www.lua.org

>>----> he who fights hatred with hatred, drives the spreading of hatred <----<<

SMF spam blocked by CleanTalk