PtokaX forum

Archive => Archived 4.0 boards => Help with Lua 4 scripts => Topic started by: DorianG on 16 February, 2004, 15:10:55

Title: gag command help
Post by: DorianG on 16 February, 2004, 15:10:55
A script for !gag command.
who help me?
:D
Title:
Post by: pHaTTy on 16 February, 2004, 15:19:53
? its inbuilt
Title:
Post by: DorianG on 16 February, 2004, 15:28:36
Yes but I want to see which it is the script of the !gag command.
You would be very kind if you make me it to see.
Thank you :D
Title:
Post by: pHaTTy on 16 February, 2004, 15:59:25
hmm sumit like



Bot = "Gag"
mcmd = "#"

Gagged = {}

function DataArrival(user,data)
if strsub(data, 1, 1) == "<" then
data=strsub(data,1,strlen(data)-1)
s,e,cmd = strfind(data,"%b<>%s+(%S+)")

if Gagged[user.sName] then
return 1
else
if cmd == mcmd.."gag" then
s,e,cmd,who = strfind(data,"%b<>%s+(%S+)%s+(%S+)")
if GetItemByName(who) then
Gagged[who] = 1
user:SendData(Bot,who.sName.." has been gagged!")
return 1
else
user:SendData(Bot,"No such user!")
return 1
end
end
end
end
end


i guess ;)
Title:
Post by: DorianG on 16 February, 2004, 18:17:52
thank phatty you are very glad   :D