Yes this is possible.

Here is a script, that should do what you want:

Code:
on *:JOIN:[color:blue]#channelname[/color]:{
  ctcp $nick Time
}

on *:CTCPREPLY:TIME*:{
  var %timereply = $2-
  if (($5 >= 05:00:00) && ($5 <= 11:59:59)) { msg [color:blue]#channelname[/color] Good morning $nick $+ . }
  elseif (($5 >= 12:00:00) && ($5 <= 17:59:59)) { msg [color:blue]#channelname[/color] Good afternoon $nick $+ . }
  elseif (($5 >= 18:00:00) && ($5 <= 23:59:59)) { msg [color:blue]#channelname[/color] Good evening $nick $+ . }
  elseif (($5 >= 00:00:00) && ($5 <= 04:59:59)) { msg [color:blue]#channelname[/color] Good night $nick $+ . }
  else { msg [color:blue]#channelname[/color] Hi $nick $+ . }
}


Obviously, change #channelname, to the name of the channel you want it to work in.