hi i want a script who shows the op a messages when they login is it possible
BOT = "Botname"
msg = [[ Add some nice text here, This will be sent
to OPS only ]]
function OpConnected(user)
user:SendData(BOT, msg)
end
tnx kepp =)
its been very messy in the message is it possible to call a txt file called oprules.txt in stead to ops ??
-- Requested by Gizmo
-- Written By BlazeXxX
Bot = "WelcomeBot"
function Main()
frmHub:RegBot(Bot)
end
function function OpConnected(curUser)
readfrom("Welcome.txt")
local message = ""
while 1 do
local line = read()
if (line == nil) then break else
message = message..line.."\r\n"
end
end
curUser:SendPM(Bot,message)
end
well I think there is one function to much there BlazeXxX :-)
-- Requested by Gizmo
-- Written By BlazeXxX
Bot = "WelcomeBot"
function Main()
frmHub:RegBot(Bot)
end
function OpConnected(curUser)
readfrom("Welcome.txt")
local message = ""
while 1 do
local line = read()
if (line == nil) then break else
message = message..line.."\r\n"
end
end
curUser:SendPM(Bot,message)
end
Nice Kepp always there fixing the minimum error. :-)
hunting post are ya! :-p hehe (no harm in that) :-)
Cheers m8, Am drinking some vodka with ice here and bubble water. hahaha... if you know can understand what i mean
with that. (socker dricka in swedish) lol
nice =) damn your fast with replie script =)
he he, Getting "full"? lol
Yea, i like the samll errors, they're easy to fix, while the big ones are in other projects
how do i make a script who calls help.txt or txt files
Hi,
Use this eg....
--- Requested by gizmo ----
--- Made by nErBoS ------
help = "help.txt"
function Readtextfile(user, file)
local filecontents = ""
local handle = openfile(file, "r")
if (handle ~= nil) then
local line = read(handle)
while line do
filecontents = filecontents..line.."\r\n"
line = read(handle)
end
closefile(handle)
user:SendPM(Bot, filecontents)
end
end
function CallText (user, data)
Readtextfile(user, help)
end
Best regards, nErBoS
there is a tiny error in all of these scripts.
doesn't cause any big error but it just isn't nice.
none of them send the end pipe.
plop
Ok, a question, What's the end pipe good for if not needed? That's my questions... :S
and if it is needed, What problems may it cause,
-1 on the text it reads?