I know that there is millions of welcome bots already, but I made a couple anyway.
-- ???????????????????????
-- ? Welcome-AI 1.0 ?
-- ? Made by: blackwings ?
-- ???????????????????????
Bot="?Welcome-AI?"
hubowner = "blackwings"
function Main()
frmHub:RegBot(Bot)
end
function NewUserConnected(User)
if GetProfileName(User.iProfile) == "VIP" then
SendToAll(Bot,"The VIP "..User.sName.." has just connected to this hub")
elseif GetProfileName(User.iProfile) == "Reg" then
SendToAll(Bot,"The registered user "..User.sName.." has just connected")
end
end
function UserDisconnected(User)
if GetProfileName(User.iProfile) == "VIP" then
SendToAll(Bot,"The VIP "..User.sName.." has left the hub")
end
end
function OpConnected(User)
if GetProfileName(User.iProfile) == "Master" and User.sName == hubowner then
SendToAll(Bot,"-== Attention! The hubowner "..User.sName.." has entered the hub. ==-")
elseif GetProfileName(User.iProfile) == "Master" then
SendToAll(Bot,"Attention! Master "..User.sName.." has just connected to this hub.")
elseif GetProfileName(User.iProfile) == "Moderator" then
SendToAll(Bot,"Attention! Moderator "..User.sName.." has just connected to this hub.")
elseif GetProfileName(User.iProfile) == "Operator" then
SendToAll(Bot,"Attention! Operator "..User.sName.." has just connected to this hub.")
end
end
function OpDisconnected(User)
if GetProfileName(User.iProfile) == "Master" and User.sName == hubowner then
SendToAll(Bot,"The hubowner "..User.sName.." has left the hub.")
elseif GetProfileName(User.iProfile) == "Master" then
SendToAll(Bot,"Master "..User.sName.." has left the hub.")
elseif GetProfileName(User.iProfile) == "Moderator" then
SendToAll(Bot,"Moderator "..User.sName.." has left the this hub.")
elseif GetProfileName(User.iProfile) == "Operator" then
SendToAll(Bot,"Operator "..User.sName.." has left the hub.")
end
end
Version 2.0:
I added random welcome and "Good Bye" messages to the bot
-- ?????????????????????????????????????????????????
-- ? Welcome-AI 2.0 ?
-- ? Made by blackwings ?
-- ? Added: Random Welcome and Good Bye Messages ?
-- ?????????????????????????????????????????????????
Bot="?Welcome-AI?"
hubowner="blackwings"
--######## HERE STARTS THE CONFIGURATION ########--
--????????????????????????????????????????????
------------------------------------------
-- Random welcome message for the hubowner
------------------------------------------
HOWelcome = {
"has entered the hub. ==-",
"second HubOwner welcome message",
"third HubOwner welcome message",
}
--------------------------------------------------
-- Random message for when the hubowner disconnect
--------------------------------------------------
HOByeBye = {
"has left the hub",
"second HubOwner Good Bye message",
"third HubOwner Good Bye message",
}
--????????????????????????????????????????????
--++++++++++
--????????????????????????????????????????????
--------------------------------------------------------------
-- Random welcome message for the Operators and the Moderators
--------------------------------------------------------------
OPWelcome = {
"has just connected to this hub",
"second OP & Mod welcome message",
"third OP & Mod welcome message",
}
----------------------------------------------------------------------
-- Random message for when the Operators and the Moderators disconnect
----------------------------------------------------------------------
OPByeBye = {
"has left the hub",
"second OP & Mod Good Bye message",
"third OP & Mod Good Bye message",
}
--????????????????????????????????????????????
--++++++++++
--????????????????????????????????????????????
----------------------------------------
-- Random welcome message for the VIP's
----------------------------------------
VIPWelcome = {
"has just connected to this hub",
"second VIP welcome message",
"third VIP welcome message",
}
--------------------------------------------------
-- Random message for when the VIP's disconnect
--------------------------------------------------
VIPByeBye = {
"has left the hub",
"second VIP Good Bye message",
"third VIP Good Bye message",
}
--????????????????????????????????????????????
--++++++++++
--????????????????????????????????????????????
--------------------------------------------------
-- Random welcome message for the registered users
--------------------------------------------------
REGWelcome = {
"has just connected",
"second REG welcome message",
"third REG welcome message",
}
--------------------------------------------------
-- Random message for when a registered user disconnect
--------------------------------------------------
REGByeBye = {
"has left the hub",
"second REG Good Bye message",
"third REG Good Bye message",
}
--????????????????????????????????????????????
--######## HERE ENDS THE CONFIGURATION ########--
function Main()
frmHub:RegBot(Bot)
end
function NewUserConnected(User)
if GetProfileName(User.iProfile) == "VIP" then
SendToAll(Bot,"The VIP "..User.sName.." "..VIPWelcome[random(1, getn(VIPWelcome))]..".")
elseif GetProfileName(User.iProfile) == "Reg" then
SendToAll(Bot,"The registered user "..User.sName.." "..REGWelcome[random(1, getn(REGWelcome))]..".")
end
end
function UserDisconnected(User)
if GetProfileName(User.iProfile) == "VIP" then
SendToAll(Bot,"The VIP "..User.sName.." "..VIPByeBye[random(1, getn(VIPByeBye))]..".")
elseif GetProfileName(User.iProfile) == "Reg" then
SendToAll(Bot,"The registered "..User.sName.." "..REGByeBye[random(1, getn(REGByeBye))]..".")
end
end
function OpConnected(User)
if GetProfileName(User.iProfile) == "Master" and User.sName == hubowner then
SendToAll(Bot,"The hubowner "..User.sName.." "..HOWelcome[random(1, getn(HOWelcome))]..".")
elseif GetProfileName(User.iProfile) == "Master" then
SendToAll(Bot,"Master "..User.sName.." "..OPWelcome[random(1, getn(OPWelcome))]..".")
elseif GetProfileName(User.iProfile) == "Moderator" then
SendToAll(Bot,"Moderator "..User.sName.." "..OPWelcome[random(1, getn(OPWelcome))]..".")
elseif GetProfileName(User.iProfile) == "Operator" then
SendToAll(Bot,"Operator "..User.sName.." "..OPWelcome[random(1, getn(OPWelcome))]..".")
end
end
function OpDisconnected(User)
if GetProfileName(User.iProfile) == "Master" and User.sName == hubowner then
SendToAll(Bot,"The hubowner "..User.sName.." "..HOByeBye[random(1, getn(HOByeBye))]..".")
elseif GetProfileName(User.iProfile) == "Master" then
SendToAll(Bot,"Master "..User.sName.." "..OPByeBye[random(1, getn(OPByeBye))]..".")
elseif GetProfileName(User.iProfile) == "Moderator" then
SendToAll(Bot,"Moderator "..User.sName.." "..OPByeBye[random(1, getn(OPByeBye))]..".")
elseif GetProfileName(User.iProfile) == "Operator" then
SendToAll(Bot,"Operator "..User.sName.." "..OPByeBye[random(1, getn(OPByeBye))]..".")
end
end