I currently have this auto deop script:

alias adduser set %deoplist %deoplist $$1-
alias deluser set %deoplist $remtok(%deoplist,$$1,1,32)
on @*:op:#theshire:{
if $istok(%deoplist,$opnick,32) { mode # -o $opnick }
if $istok(%deoplist,$opnick,32) { notice $nick Do NOT op $opnick }
if $istok(%deoplist,$opnick,32) { notice $nick Any repeated attempts to do so will result in you being deopped. }
}

With the repeated attempts... thing on one line like it should be - not two.

The problem is the "repeated attempts" thing is just a bluff.
I leave mIRC on 24/7, so I can't always be there to manually deop/kick/warn the person that opped someone on the list.

How can I make it so that after someone on the %deoplist is opped 3 times in 10 minutes whoever opped them is automatically deoped, and if it's done 5 times in 10 minutes the person opping them along with the person getting opped is banned?
The chanel is #theshire if that helps.

Thanks!