Clock 2

By BlueThen on Jul 20, 2008

For the heck of it, I made an entirely new version of Clock. It's now a lot cleaner and smoother.
Image

;Clock 2.0
;Made by BlueThen on July 20, 2008
;To install, paste this snippet in your remotes (Alt + R)
;Then type /clock2 or right click the channel or status and click "Clock2".
alias clock2 { echo -a Clock 2 made by BlueThen ( http://www.bluethen.com/ for more scripts and snippets )
  window -paozCdk0 +ndL @Clock2 -1 -1 150 150 | window -paohCzdk0 +ndL @clock2.buf -1 -1 800 800 | unset %clock2.c | clock2.frame
}
menu channel,status {
  Clock 2: clock2
}
alias clock2.frame {
  if (%clock2.c != y) {
    clear @clock2.buf | drawfill -r @clock2.buf $rgb(1,1,1) $rgb(1,1,1) 1 1 | drawdot @clock2.buf 1 300 400 450
    drawdot -r @clock2.buf $rgb(150,100,0) 290 400 450 | drawline @clock2.buf 1 7 0 100 1000 100
    drawfill -r @clock2.buf $rgb(120,70,0) $rgb(0,0,0) 1 1 | drawline -r @clock2.buf 1 7 670 100 670 -100
    drawrect -rf @clock2.buf $rgb(130,80,10) 1 670 0 300 100 | drawtext @clock2.buf 1 Tahoma 100 697 -18 ×
    %clock2.xy = 12
    while (%clock2.xy) {
      if (. isin $calc(%clock2.xy /3)) {
        drawdot -r @clock2.buf $rgb(100,50,0) 8 $calc(400 + (270 * $cos($calc(30 * %clock2.xy)).deg)) $calc(450 + (270 * $sin($calc(30 * %clock2.xy)).deg))
      }
      else {
        drawtext -r @clock2.buf $rgb(100,50,0) Tahoma 80 $calc((400 + (240 * $cos($calc((%clock2.xy * 30) -90)).deg)) - ($width(%clock2.xy ,Tahoma,80) /2)) $calc((450 + (240 * $sin($calc((30* %clock2.xy)-90)).deg)) - ($height(%clock2.xy ,Tahoma,80) /2)) %clock2.xy
      }
      dec %clock2.xy
    }
    drawline -r @clock2.buf $rgb(100,50,0) 8 400 450 $calc(400 +(200 * $cos($calc((6 * $asctime(s)) - 90)).deg)) $calc(450 +(200 * $sin($calc((6 * $asctime(s)) - 90)).deg))
    drawline -r @clock2.buf $rgb(100,50,0) 12 400 450 $calc(400 +(200 * $cos($calc((6 * $asctime(n)) - 90)).deg)) $calc(450 +(200 * $sin($calc((6 * $asctime(n)) - 90)).deg))
    drawline -r @clock2.buf $rgb(100,50,0) 16 400 450 $calc(400 +(150 * $cos($calc((30 * $asctime(h)) - 90)).deg)) $calc(450 +(150 * $sin($calc((30 * $asctime(h)) - 90)).deg))
    drawtext -r @clock2.buf $rgb(80,30,0) Tahoma 80 30 0 $asctime(h:nn:ss TT)
    drawcopy -m @clock2.buf 0 0 800 800 @clock2 0 0 150 150 | .timer 1 1 clock2.frame
  }
  else unset %clock2.c
}
on *:close:@clock2: clock2.close
menu @clock2 {
  sclick: {
    if ($calc($mouse.y * 5.3333) < 100) {
      if ($calc($mouse.x * 5.3333) > 670) clock2.close
      else {
        set %clock2.dx $calc($window(@clock2).dx - $mouse.dx)
        set %clock2.dy $calc($window(@clock2).dy - $mouse.dy) | .timermove -h 0 0 clock2.move 
      }
    } 
  }
  uclick: { .timermove off }
  leave: { .timermove off }
}
alias -l clock2.move window @clock2 $calc($mouse.dx + %clock2.dx) $calc($mouse.dy + %clock2.dy)
alias -l clock2.close unset %clock2.* | set %clock2.c y | if ($window(@clock2)) window -c @clock2 | window -c @clock2.buf

Comments

Sign in to comment.
Eugenio   -  Jul 26, 2008

lol
and yeah its 6/10

 Respond  
BlueThen   -  Jul 26, 2008

It tells the time. :(

 Respond  
H_M   -  Jul 26, 2008

It\'s nice, but not useful at all............................................ 6/10

 Respond  
DaNzO   -  Jul 21, 2008

Make a dialog, Like, /ClockSettings - It\'ll bring up a dialog with settings you can do,

Change the time zone, change the color, change the style... More work i know, It\'ll be worth it in the long run. :)

 Respond  
BlueThen   -  Jul 21, 2008

:/ So how should I do it? click and it changes settings, or have a seperate dialog...

 Respond  
Jonesy44   -  Jul 21, 2008

Lmao!!
Kinda agree with that lol

Make it optional bluethen.. It itll be the easiest part of the script

 Respond  
xplo   -  Jul 21, 2008

its still cool :)

but it would be more cool if you could make it minimise WITH mirc

and when you bring the window back up well open the clock back up.

and for the colors, can i suggest a good old black and white.

( school clocks ) :)

 Respond  
xplo   -  Jul 21, 2008

this looks like an old southpark kitchen clock LMAO

 Respond  
EL   -  Jul 20, 2008

Well do it for US then BT...for US!.`-.-´

 Respond  
BlueThen   -  Jul 20, 2008

That only makes my life more difficult. :(

 Respond  
EL   -  Jul 20, 2008

Make it optional;p

 Respond  
BlueThen   -  Jul 20, 2008

well, what color should I make it?

 Respond  
EL   -  Jul 20, 2008

ROFL oh i see well it looks like shiit.Still works fine tho well done.`-.-´

 Respond  
BlueThen   -  Jul 20, 2008

It\'s not an update, it\'s an entirely new version.

I tried making it look... wooden. :(

 Respond  
napa182   -  Jul 20, 2008

yeah the color blows

 Respond  
EL   -  Jul 20, 2008

Ugliest fukin color BT.`-.-´

 Respond  
napa182   -  Jul 20, 2008

nice work BlueThen, but why didnt you just update ur old version of ur clock instead of posting a new Snippet?

 Respond  
Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.