hi thede!
hidden in the help file is this. it's the way to handle such stuff in mircryption. you'll find it's more work than fish, which can auto takeover the on :text: stuff since it patches mirc, but it is more flexible:
"Unfortunately, in mirc it is not possible to trigger normal text events on decrypted text, so if you have existing scripts which normally are triggered when the user types something, these scripts will not be able to respond to text that is sent to you encrypted.
So you must make some changes to your scripts to allow them to react to encrypted text.
Mircryption provides a signal facility that will help you design very flexible scripts that can see encrypted and normal text, both incoming and outgoing, and handle it appropriately.
To do this, you will use a mirc SIGNAL. For more help on mirc signals, see the mirc help file.
The mircryption signal you will write a handler for is called MircryptionSignalAll.
The following code is from the bottom of your mircryption.mrc script, and you would copy and paste this into your own script file and use it as the starting point for your script:
; Here is a sample signal trap for catching text BEFORE it is displayed on screen.
; you can implement this signal in your other scripts if you want to detect
; and act on text BEFORE it is displayed. check $1 for the type of event.
; The most common use of this signal is to issue the /mchalt or /mchaltdef commands, which will BLOCK
; mircryption (or mircryption and mirc) from displaying the text when you return from the signal!
; DONT add your code to this procedure(!!) because it will be overwritten
; if you upgrade - instead, make your own script file with this code.
on *:SIGNAL:MircryptionSignalAll: {
; trigger signal for other scripts that want to handle decrypted text, only trigger for text that was received encrypted or outgoing crypted
; this allows other scripts to be written to trigger on incoming encrypted text, without having to modify mircryption.
; note, this signal is triggered on your OWN text too(!), just detect the case where $1==input.
; $1 = event type (input,text,query,notice,action,join,topic,part,kick,quit,nick,mode)
; $2 = target ($chan)
; $3 = speaker ($nick)
; $4 = is $true if text was encrypted or $false if plaintext
; $5- = decrypted text
;uncomment to test this
;/echo TRAPPED MircryptionSignalAll: event: $1 , target: $2 , speaker: $3 , encrypted: $4, firstword = $5, text: $5-
;if ($5 == hidethis) {
; ; this test hides all lines (incoming, actions, outgoing, everything - which starts with the word hidethis)
; echo 4 MircryptionSignalAll test, hiding your statement.
; /mchaltdef
;}
}
Note that an older signal (MircryptionSignal) is still present in the mircryption.mrc script for backward compatibility, but it is being phased out; MircryptionSignalAll provides all of the functionality of the original MircryptionSignal and adds more features.
SO, to recap, go to the bottom of your mircryption.mrc and copy the MircryptionSignalAll function and paste it in a script of your own, then inside that check for and handle the text and input events you want.