mIRC Homepage
Posted By: shaggie76 Message text for Context Menu - 09/06/20 09:29 PM
We have been using custom context menus to access moderation commands (kick, ban etc) for years but to improve logging we want to include the offensive message as the 'reason' for the kick. I've scoured the documentation and tried everything I could think of but I can only seem to get the Nick for the offender in $1.

Here's a sketch of what we're after (it's not exactly tban/kick though)

Code
menu nicklist {
  .Timeout:/tban # 1h $$1 | /kick # $$1 $$2-
}


What I was hoping was $$2- (or something else) could expand to the message I clicked on so that the kick message "reason" is what the user said.

I understand that "menu nicklist" is run when actually clicking on the nicklist too (not just on the name part of a message in-channel) so I tried using "menu channel" as well with no luck.

Please tell me I just need more coffee and this is already possible and I've just missed it.
Posted By: maroon Re: Message text for Context Menu - 10/06/20 02:36 PM
I don't know of anything that identifies the message on which you clicked the nick. Alternatives would be to filter for messages matching $+(<,$nick,>*) into a @tmp window, from which you could click to select the offending message - or you could simply highlight the offending text into the clipboard, then use $$cb instead of $$2-
© mIRC Discussion Forums