I have seen a bot in a hub, that tells the time, it is always at the top of the users list n has a key, the time also changes, i do hav a screenshot of this script/bot in action & the hub addy, but not sure if ur allowed to addy on here so i wont, ive been told that kepp made it, if ne1 has any info or you have it, please will u let me know, thanx, ???883??
cant remember where i got this one
current = date("%H:%M")
min = 1000*60
--------------------------------------------------------
function Main()
frmHub:RegBot("---" ..current .."---")
SetTimer(min)
StartTimer()
end
--------------------------------------------------------
function OnTimer()
frmHub:UnregBot("---" ..current .."---")
time = date("%H:%M")
current = time
frmHub:RegBot("---" ..current .."---")
end
--------------------------------------------------------
function OnExit()
frmHub:UnregBot("---" ..current .."---")
end
--------------------------------------------------------
yeppp, found it
current = date("%H:%M")
min = 1000*60
--------------------------------------------------------
function Main()
frmHub:RegBot("---" ..current .."---")
SetTimer(min)
StartTimer()
end
--------------------------------------------------------
function OnTimer()
frmHub:UnregBot("---" ..current .."---")
time = date("%H:%M")
current = time
frmHub:RegBot("---" ..current .."---")
end
--------------------------------------------------------
function OnExit()
frmHub:UnregBot("---" ..current .."---")
end
--------------------------------------------------------
Didnt noticed, that this post is already answered... I need glasses :D
Thanx ever so much, i didnt expect a reply so quick :D , 8)
QuoteOriginally posted by enema
Didnt noticed, that this post is already answered... I need glasses :D
He he well i got it in first m8
but what a coincedence that both of us posted exactly the same :D
I kept this thread open while searhing for script in other window. So the thread couldnt get refreshed :) Well, I found this script in this forum by using search. I found it, tested it, I realised, that I like this clock and then posted it here... hahaahaa... so i didnt noticed, that somebody posted same thing... well, s*it happens!
still laughing..
iInterval = 60; -- in minutes
sBotName = "opunia";
iState = 0;
function Main()
iState = 2;
SetTimer(60 * 1000);
StartTimer();
end
function OnTimer()
if (iState == 1) then
SendToAll(sBotName, "text"..date("%H:%M").."text");
elseif (iState == 2 and mod(date("%M") + iInterval, iInterval) == 0) then
SetTimer(iInterval * 60 * 1000);
iState = 1;
SendToAll(sBotName, "text"..date("%H:%M").."text");
end
end
function GetDate()
d = date("%d")
mm = date("%m")
y = date("%y")
Date = ""..d.."/"..mm.."/"..y
return Date
end
... But Im afraid it isint what ???883?? was looking for. Take a look at script above, you will see, that they work completely different. Thanks anyway :)
Can anyone check why i'm getting another Bot
after "Restart Scripts"
And i did restarted my client!
The only way to restore it was Restarting the HUB
and that's out of the question!
depends which script your talking about
I'v restarted my scripts many times and always havebut 1 timbot in the hub
otherwise use this
-- BotMgr 1.0
-- by Mutor
--
-- Add / Remove bot names from user list.
-- Option for context menu [you can add more of your own commands]
-- Allow command by profile
--
-- Remove/Restore a bot by typing [in main chat]
-- !killbot --Removes bot
-- !listbot --Restores bot
-- Bot will be listed if scripts are restarted as well
--
--
aprof = 0 -- Masters are authorized to use these commands
SendMenu = "1" -- Provide context [right click] menu commands, 0 for no
--
function NewUserConnected(user)
if SendMenu == "1" then
if user.iProfile == aprof then
customCMDS(user)
user:SendData(" *** Notice :: Right click hub tab or user list for Admin commands. ***")
else
end
else
end
end
OpConnected = NewUserConnected
--$UserCommand 1 X Where -> 1=Hub Menu 2=User Menu 3=Hub/User Menu
function customCMDS(user)
--user:SendData("$UserCommand 255 7") --clear the menu first
user:SendData("$UserCommand 1 3 [Admin]\\Remove Bot $<%[mynick]> !killbot %[line:BotNick]||")
user:SendData("$UserCommand 1 3 [Admin]\\Restore Bot $<%[mynick]> !listbot %[line:BotNick]||")
end
function DataArrival(user, data)
if user.iProfile == aprof then
if strsub(data,1,1)=="<" then
data=strsub(data,1,strlen(data)-1)
s,e,cmd,name = strfind(data,"%b<>%s+(%S+)%s+(%S+)")
if cmd=="!killbot" then
frmHub:UnregBot(name)
elseif cmd=="!listbot" then
frmHub:RegBot(name)
end
end
end
end
can also deppend on what PtokaX verison you are using , the " OnExit() " part is only available in the beta versions. that's why it don't unreg the bot upon restart scripts ...
Typhoon?
i'm using [ProtaX v0.326 TD4]
And when i got the three BOTs the time was different
in each of them (the interval of the time i've restarted)
current = date("%H:%M")
min = 1000*60
--------------------------------------------------------
function Main()
frmHub:UnregBot("---" ..current .."---")
frmHub:RegBot("---" ..current .."---")
SetTimer(min)
StartTimer()
end
--------------------------------------------------------
function OnTimer()
frmHub:UnregBot("---" ..current .."---")
time = date("%H:%M")
current = time
frmHub:RegBot("---" ..current .."---")
end
--------------------------------------------------------
try this out it should do the same
Typhoon?
Typhoon?
Can you add Date?
current = date(" %X -- %d/%m-%Y")
min = 1000*60
--------------------------------------------------------
function Main()
frmHub:UnregBot("---" ..current .."---")
frmHub:RegBot("---" ..current .."---")
SetTimer(min)
StartTimer()
end
--------------------------------------------------------
function OnTimer()
frmHub:UnregBot("---" ..current .."---")
time = date(" %X -- %d/%m-%Y")
current = time
frmHub:RegBot("---" ..current .."---")
end
--------------------------------------------------------
that should do it ..
Typhoon?
hehe...That was quick!
10x Typhoon?
Can you change it and make it without a second?!
current = date("%H:%M -- %d/%m-%Y")
min = 1000*60
--------------------------------------------------------
function Main()
frmHub:UnregBot("---" ..current .."---")
frmHub:RegBot("---" ..current .."---")
SetTimer(min)
StartTimer()
end
--------------------------------------------------------
function OnTimer()
frmHub:UnregBot("---" ..current .."---")
time = date("%H:%M -- %d/%m-%Y")
current = time
frmHub:RegBot("---" ..current .."---")
end
--------------------------------------------------------
here you go..
Typhoon?