0 LIKES
Snippet
WHISPER to PRIVMSG
In Category General ircWx Posted by Winz On 02/17/19
UPDATED - Last one had some doubling up issues, this one should work. Make sure you delete vars %ch.* and %ni.* in your variables list before using.
UPDATED - To handle more than one whisper at a time
For mIRC versions 7.42 and Up - Uses "on PARSELINE" Event - Tested on mIRC 7.55 (Socketless) This snippet allows you to send and receive whispers using mIRC's /query command across IRCwx to use mIRC's built in query system. As it is, IRCwx sends a WHISPER from Web Chat users which mIRC doesn't recognize. This snippet takes the incoming whisper and transforms it into mIRC's standard PRIVMSG. You should be able to extract information from this to make it work with Socket connections as well. This snippet provides its own menu nicklist Whisper command and $stripstyle identifier. I recommend moving this to the top of your script Order list.
UPDATED - To handle more than one whisper at a time
For mIRC versions 7.42 and Up - Uses "on PARSELINE" Event - Tested on mIRC 7.55 (Socketless) This snippet allows you to send and receive whispers using mIRC's /query command across IRCwx to use mIRC's built in query system. As it is, IRCwx sends a WHISPER from Web Chat users which mIRC doesn't recognize. This snippet takes the incoming whisper and transforms it into mIRC's standard PRIVMSG. You should be able to extract information from this to make it work with Socket connections as well. This snippet provides its own menu nicklist Whisper command and $stripstyle identifier. I recommend moving this to the top of your script Order list.
on *:PARSELINE:in:*WHISPER*: { var %whi $parseline | tokenize 32 %whi if ($2 == WHISPER) { var %n $utfdecode($remove($gettok($1,1,33),:)) | set %ch. $+ %n $3 | set %ni. $+ %n %n .parseline -it $remove($replace($stripstyle($1-),WHISPER,PRIVMSG),$3) halt } } on ^*:TEXT:*:?: { if ($query(%ni. $+ $nick) == $null) { query %ni. $+ $nick | echo $query(%ni. $+ $nick) $timestamp $nick : $+ $1- | halt } else { echo $query($nick) $timestamp $nick : $+ $1- | halt } } on *:INPUT:?: { .raw WHISPER $var(*. $+ %ni. $+ $active,1).value %ni. $+ $active : $+ $1- | echo $active $timestamp $me : $+ $1- | halt } menu nicklist { .Whisper { set %ni. $+ $$1 $$1 | set %ch. $+ $$1 # | .query $$1 } } on ^*:CLOSE:?: { unset %ni. $+ $target | unset %ch. $+ $target } alias stripstyle { return $strip($regsubex($1-, /\[(?:style\x20.*?|/style)\]/gi,$null)) }
Comments 0
You must be logged in to comment.