mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: Dec 2002
Posts: 580
N
Fjord artisan
OP Offline
Fjord artisan
N
Joined: Dec 2002
Posts: 580
Code:
on *:text:*:*:{
  if ($chan != $null) { .signal -n TEXT_CHAN $1- }
}
on *:signal:TEXT_CHAN:{ echo -a $signal -- $nick -- $chan }

Results: TEXT_CHAN -- SomeNick -- $null

Try this code out... Of couse not using the '-n' with signal would result in $chan and $nick being null... But with the '-n' option $chan is $null, $nick is still $nick from :text:


NaquadaBomb
www.mirc-dll.com
Joined: Sep 2003
Posts: 4,230
D
Hoopy frood
Offline
Hoopy frood
D
Joined: Sep 2003
Posts: 4,230
havent checked it but i always thought it became your nick ie $me

[edit]
Confirmed, $nick becomes your nick (not the on text eventers) as it should since your the one who tripped the signal event.

Last edited by DaveC; 06/06/05 07:16 AM.
Joined: Dec 2002
Posts: 580
N
Fjord artisan
OP Offline
Fjord artisan
N
Joined: Dec 2002
Posts: 580
yes, just noticed that today... I think signal should be more generic, in that they retain the identifers of the "parent" event, since mirc never calls a singal without a script saying to do so...


NaquadaBomb
www.mirc-dll.com
Joined: Sep 2003
Posts: 4,230
D
Hoopy frood
Offline
Hoopy frood
D
Joined: Sep 2003
Posts: 4,230
That would limit the scope of where a signal could be called from, and still do the same processing, its far more advantages to simply pass the needed values by command line, or global variables.


Link Copied to Clipboard