PtokaX forum

Archive => Archived 4.0 boards => Request for Lua 4 scripts => Topic started by: monnie on 02 August, 2004, 19:33:24

Title: Please...Hel me out
Post by: monnie on 02 August, 2004, 19:33:24
Hello scripters...
Greetings

I've seen some triggies (trug chats), but i wanted if it's possible, have one just like the old neo modus trigguie:

We can add or remove trigs;
Users, if not op's maybe disconected when they fire a trig or even fire an special one;
the ansers maybe of two kinds... on main chat or some (predifened) in PM

Is it too much to ask folks??
Hope note if you need more details or if you don't understand something, please ask me

Thanks for now...

                             monnie
Title:
Post by: NightLitch on 02 August, 2004, 21:56:19

-- TrickerBot.lua, created by Ptaczek Dec-24,2002
-- Just see how to implement the NMDC TriggerBot in LUA :)

botname = "TrickerBot"
trigs = {
lol="Yeah, that was funny [USER]. Haha.",
bye="See ya [USER]",
help="What do you need help with [USER]? away? opcommands?",
away="Type #a to set status to AWAY, #b to to turn of AWAY",
opcommands="Type !help or +help for command list [USER]",
vandel="Vandel!?!? WHERE??!",
ptokax="Oh Yeah, PtokaX ;)",
fuck="Watch IT [USER]! One more line of code and i could kick your ass!",
["shut up"]="Make me [USER] !"
}


function DataArrival(user, data)
if( strsub(data, 1, 1) == "<" ) then
-- get the msg only using regular expression
s,e,msg = strfind(data, "%b<> ([%w ]*)")

-- look in the table
for key, value in trigs do
if( strfind( strlower(msg), key) ) then
answer, x = gsub(value, "%b[]", user.sName)
SendToAll( botname, answer )
break
end
end
end
end

/NL
Title: Greetings
Post by: monnie on 03 August, 2004, 01:52:54
I believe this may be a start!!!
Thanks

..but for me isn't enough..
Can anyone continue this Sudden Script??
lol

Thanks NightLitch

                          monnie
Title:
Post by: plop on 04 August, 2004, 18:56:46
check out sensi from guibs,

plop
Title:
Post by: IsoD on 20 August, 2004, 07:44:05
That senssi2.lua is workin fine but there is one problem. I'm from Finland an here in Scandinavia we use special characters ? and ?. If I make a trigger with those it doesn't work, like ["hyv?? y?t?"]="Hyvi? unosia [USER] ja toivottavasti n?et makoisia unia :)",  
(means that good night, and the bot says "sleep well [USER]")

So is there any way to get those work

thnx.....