I know very very little about writing scripts so please be gentle.
I am running a bot 24/7 on icq.irc and the bot seems to lose its channel operator status each night around the same time. There is nothing in my logs to indicate why the bot lost its op status but, as best as I can tell, the bot is losing op status due to some sort of server split or other server refresh that cancels the bots founder status on the channel and the bots nickserv identification.
As the channel is secure there is no real problem with other users taking over op status. But, the bot, while deop'ed, is not able to perform channel operator functions like kicking users for flooding etc.
I would like to insert some script to allow the bot to regain op status when this happens.
I believe that this can be done by resending the appropriate identify commands to chainserv and nickserv upon the occurance of the loss of op status event. However, I am not sure there is any event being triggered that can easily be captured.
The ON DEOP event looks like it would work fine but the help text indicates it only applies when another user deop's the bot.
There is the On ServerOP event lsited in the help text but
there is no mention of a converse event On ServerDEOP.
I suppose I could insert an ON 1:if ($me !isop) {blah} but I am concerned this statement would execute all the time and lag the bot.
My question is, is there an event that would tell me when my bot no longer has op status?