mIRC Home    About    Download    Register    News    Help

Print Thread
on 1:OPEN:=: { #73176 29/02/04 05:00 PM
Joined: Feb 2003
Posts: 3,432
S
sparta Offline OP
Hoopy frood
OP Offline
Hoopy frood
S
Joined: Feb 2003
Posts: 3,432
I have been asking this befor.. but didnt get any good answer on it, so here we go again. If i open a DCC chat with somone, then i can echo that users nick by $nick.. but how can i do a check that if $nick == $true command .. and with $true i mean if i have a chat open with that nick, then i want to trigger a command, i couldent find anything about this in the help file.. and not on this forum.. "i never know what nick the $nick would be".. any suggestions?


if ($me != tired) { return } | else { echo -a Get a pot of coffee now $+($me,.) }
Re: on 1:OPEN:=: { #73177 29/02/04 06:50 PM
Joined: Dec 2002
Posts: 16
T
tye Offline
Pikka bird
Offline
Pikka bird
T
Joined: Dec 2002
Posts: 16
Use $chat to check if you have a DCC chat open with somebody. Example:
Code:
if ($chat(Tye)) { echo -a I have a DCC Chat window with Tye } 




Tye on Undernet and DALnet
Re: on 1:OPEN:=: { #73178 29/02/04 06:55 PM
Joined: Feb 2003
Posts: 3,432
S
sparta Offline OP
Hoopy frood
OP Offline
Hoopy frood
S
Joined: Feb 2003
Posts: 3,432
if ($chat( $+ $nick $+ ) != $null) { Echo -a You have a chat open with $nick $+ . }

dont work.. cos you get that chat window you just opened as if you allready had a chat open with that nick smirk


if ($me != tired) { return } | else { echo -a Get a pot of coffee now $+($me,.) }
Re: on 1:OPEN:=: { #73179 29/02/04 07:34 PM
Joined: Apr 2003
Posts: 414
Adrenalin Offline
Fjord artisan
Offline
Fjord artisan
Joined: Apr 2003
Posts: 414

Code:
on 1:OPEN:=:{ 
  if ($NickChats($nick) >= 2) echo You already have a chat window with $nick !
}

Alias NickChats {
  var %total = $chat(0)
  var %c = 0
  while (%total) {
    if ($1 == $chat(%total)) inc %c
    dec %total
  }
  return %c
}


mIRC Chm Help 6.16.0.3 Full Anchored!
Re: on 1:OPEN:=: { #73180 29/02/04 08:44 PM
Joined: Dec 2002
Posts: 1,922
O
Online Offline
Hoopy frood
Offline
Hoopy frood
O
Joined: Dec 2002
Posts: 1,922

Re: on 1:OPEN:=: { #73181 01/03/04 12:41 PM
Joined: Apr 2003
Posts: 414
Adrenalin Offline
Fjord artisan
Offline
Fjord artisan
Joined: Apr 2003
Posts: 414
My alias do same think $window(=$nick,0).. So use $window(=$nick,0)


mIRC Chm Help 6.16.0.3 Full Anchored!