well, if you're closing down the DCC window every time, there isnt. If you keep the window open, then all you need to do is use the ^ and haltdef along with if ($1- == some text here). So for example:
on *:text:clone scan finished*:?: {
if ($nick == mybot) { haltdef }
}
I dont THINK you need a HALT in there, but if so, just do haltdef | halt. If your bot has a user level, then you could do:
on mybot:text:clone scan finished*:?:haltdef
If that isnt what you're looking for, then I could be mistaken and if so, forgive me