WeirdNicksParty Nide help script to 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

WeirdNicksParty Nide help script to lua.5

Started by Teddy, 29 July, 2005, 12:14:26

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Teddy

--Crazy Animals 2.0 Script Powered by Demone.Astaroth

--Script temporarily gives to users a strange nick :)
--2 options (fixed and random nicks, always for the current session); stopping command clean the memory

--Commands:
--  !anim fix -- Let's start the fixed animals' nick party!
--  !anim on -- Let's start the random animals' nick party!
--  !anim off -- Stop the parties

bot="~CrAzY-AnImAls~"

anim=0

cnames = {
"Two-rostrum Platypus",
"Marmot drowning in the chocolate",
"Cold snowy bison",
"Antelope with feet in the cement",
"Hot Pigskin",
"Kiwi's beak",
"Twisting hamster",
"Demented anteater",
"Caffettiera che sta per esplodere",
"Emasculate crocodile",
"Thermo-tapir",
"Gnu beaten by demented fridges",
"Sucker shark with plastic teeth",
"Canary with sticky wings",
"Disgusting insect",
"Crane creeping without legs",
"Blind guide dog",
"Calamary with rostrum",
"Mad koala",
"Flamingo in the toilet",
"Salmon still talking on the plate",
"Door mat with noses",
"Beaks soup",
"Multipurpose octopus",
}          

unique = {}

function Main()
frmHub:RegBot(BotName)
end

function DataArrival(curUser, message)

s,e,cmd= strfind(message,"%b<>%s+(%S+)")
if anim==1 then
   if unique[curUser.sName]==nil then
      unique[curUser.sName]=cnames[random(1, getn(cnames))]
   end
end

if curUser.bOperator ~= nil then
   s,e,cmd,status= strfind(message,"%b<>%s(.+)%s(.+)")
   if (cmd == "!anim") then
      if strfind(status, "fix") then
         SendToAll(bot, "Duplex natura vigilat super omnia.")
         anim=1
      elseif strfind(status, "off") then
         SendToAll(bot, "Shut up, animals!")
         unique[curUser.sName]=nil
         anim=0
      elseif strfind(status, "on") then
         SendToAll(bot, "Multipla natura vigilat super omnia.")
         anim=2
      end
   return 1
   end
end

if anim==1 then
if not strfind(message, "$.+") then
   s,e,mes = strfind(message, "%b<> (.*)")
   if unique[curUser.sName]~=nil then
      SendToAll(unique[curUser.sName], mes)
return 1; end; end

elseif anim==2 then
if not strfind(message, "$.+") then
   s,e,mes = strfind(message, "%b<> (.*)")
   nome=cnames[random(1, getn(cnames))]
   SendToAll(nome, mes)
return 1; end;
end

end

Madman

--Crazy Animals 2.0 Script Powered by Demone.Astaroth
-- Lua5 by Madman

--Script temporarily gives to users a strange nick :)
--2 options (fixed and random nicks, always for the current session); stopping command clean the memory

--Commands:
-- !anim fix -- Let's start the fixed animals' nick party!
-- !anim on -- Let's start the random animals' nick party!
-- !anim off -- Stop the parties

bot="~CrAzY-AnImAls~"

anim=0

cnames = {
	"Two-rostrum Platypus",
	"Marmot drowning in the chocolate",
	"Cold snowy bison",
	"Antelope with feet in the cement",
	"Hot Pigskin",
	"Kiwi's beak",
	"Twisting hamster",
	"Demented anteater",
	"Caffettiera che sta per esplodere",
	"Emasculate crocodile",
	"Thermo-tapir",
	"Gnu beaten by demented fridges",
	"Sucker shark with plastic teeth",
	"Canary with sticky wings",
	"Disgusting insect",
	"Crane creeping without legs",
	"Blind guide dog",
	"Calamary with rostrum",
	"Mad koala",
	"Flamingo in the toilet",
	"Salmon still talking on the plate",
	"Door mat with noses",
	"Beaks soup",
	"Multipurpose octopus",
}

unique = {}

function Main()
	frmHub:RegBot(BotName)
end

function ChatArrival(curUser, message)
	s,e,cmd= string.find(message,"%b<>%s+(%S+)")
	if anim==1 then
		if unique[curUser.sName]==nil then
			unique[curUser.sName]=cnames[math.random(1, table.getn(cnames))]
		end
	end
	
	if curUser.bOperator ~= nil then
		s,e,cmd,status= string.find(message,"%b<>%s(.+)%s(.+)")
		if (cmd == "!anim") then
			if string.find(status, "fix") then
				SendToAll(bot, "Duplex natura vigilat super omnia.")
				anim=1
			elseif string.find(status, "off") then
				SendToAll(bot, "Shut up, animals!")
				unique[curUser.sName]=nil
				anim=0
			elseif string.find(status, "on") then
				SendToAll(bot, "Multipla natura vigilat super omnia.")
				anim=2
			end
		return 1
		end
	end
	if anim==1 then
		if not string.find(message, "$.+") then
		s,e,mes = string.find(message, "%b<> (.*)")
			if unique[curUser.sName]~=nil then
				SendToAll(unique[curUser.sName], mes)
					return 1;
				end;
			end
	elseif anim==2 then
		if not string.find(message, "$.+") then
		s,e,mes = string.find(message, "%b<> (.*)")
			nome=cnames[math.random(1, table.getn(cnames))]
			SendToAll(nome, mes)
			return 1;
		end;
	end
end
We suffer in silence, we lurk in the shadows, we kill in the night
Site currently down, ETA of returning online is 2099 ;p

Teddy

Have testing i hub .but noooooooo

Madman

[19:50:52] <~CrAzY-AnImAls~> Multipla natura vigilat super omnia.
[19:50:53]  sd
[19:50:54]  as
[19:50:55]  sad
[19:51:01] <~CrAzY-AnImAls~> Duplex natura vigilat super omnia.
[19:51:02]  sd
[19:51:03]  sd
[19:51:04]  asd
[19:51:09] <~CrAzY-AnImAls~> Shut up, animals!
[19:51:09]  sd

Works for me....
We suffer in silence, we lurk in the shadows, we kill in the night
Site currently down, ETA of returning online is 2099 ;p

Teddy

a drive another script same time .Thats way it not work!!Thanks alot Fore fix this script to lua5.

SMF spam blocked by CleanTalk