mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: May 2003
Posts: 10
L
Pikka bird
OP Offline
Pikka bird
L
Joined: May 2003
Posts: 10
on 1:TEXT:!clear:#:if ($nick == LeperMessiah) { /msg $chan Clearing... | /clear } | else { /msg $chan You are not my owner }

Can you tell me what's wrong with this? Here is a rundown of what I want it to do.

In any channel, when I (My nickname is LeperMessiah. My script's name is different.) type !clear, I want my script to check if my name is LeperMessiah. If it is, he says "Clearing..." then clears the screen. If it is not me, I want him to message the channel saying "You are not my owner."

But this code is not working..Can anyone tell me what the code should look like? grin

Joined: Dec 2002
Posts: 699
N
Fjord artisan
Offline
Fjord artisan
N
Joined: Dec 2002
Posts: 699
Code:
on *:TEXT:!clear:#:{
  if ($nick == LeperMessiah) { msg $chan Clearing... | !clear # }
  else { msg $chan You are not my owner }
}

Joined: May 2003
Posts: 10
L
Pikka bird
OP Offline
Pikka bird
L
Joined: May 2003
Posts: 10
Ack, still doesn't work.

Joined: May 2003
Posts: 21
X
Ameglian cow
Offline
Ameglian cow
X
Joined: May 2003
Posts: 21
It should work..


-
Xc0n
Joined: Dec 2002
Posts: 339
F
Fjord artisan
Offline
Fjord artisan
F
Joined: Dec 2002
Posts: 339
Try this one...
Code:
  
on *:TEXT:!clear:#:{  
if ($nick == LeperMessiah) { msg $chan Clearing... | [color:red]/[/color]clear # }  
else { msg $chan You are not my owner }
}

Joined: May 2003
Posts: 10
L
Pikka bird
OP Offline
Pikka bird
L
Joined: May 2003
Posts: 10
I already edited that !clear part that should be /clear.

No luck..

Joined: Dec 2002
Posts: 774
T
Hoopy frood
Offline
Hoopy frood
T
Joined: Dec 2002
Posts: 774
how do you test it?

/help on text
Note: You can't test out these events by typing text to yourself. They can only be initiated by someone else saying something in a channel or in a private message.

Last edited by theRat; 01/06/03 11:11 AM.

Code:
//if ( khaled isgod ) echo yes | else echo no
Joined: Apr 2003
Posts: 426
Fjord artisan
Offline
Fjord artisan
Joined: Apr 2003
Posts: 426
Use on INPUT instead, if you want to do this in your own mIRC.


--------
mIRC - fun for all the family (except grandma and grandpa)
Joined: May 2003
Posts: 2
D
Bowl of petunias
Offline
Bowl of petunias
D
Joined: May 2003
Posts: 2
/clear only works on your own screen, so if you have it on a bot you will not see any effect other than it saying 'Clearing'. Neophyte's suggestion is probably what you want to do, as that way you clear your own screen!

Joined: Dec 2002
Posts: 699
N
Fjord artisan
Offline
Fjord artisan
N
Joined: Dec 2002
Posts: 699
I put !clear and not clear in case you had a 'clear' alias. the ! makes mIRC use its own command in preference to an alias of the same name. Note that as Devo said, this would clear BOTS chanel window and not yours.

Joined: May 2003
Posts: 10
L
Pikka bird
OP Offline
Pikka bird
L
Joined: May 2003
Posts: 10
I've already figured out the problem.

And by the way, I was on a different screen saying it to my IRC so it would clear itself when it's lagging. So I needed an on TEXT event. Anyway, like I said I found the problem and it works now. The problem was I had Vincula on and "Show User's Colors" was checked, and IRC adds that control+K thing to the beginning of the incomming text if you put it in remote. So I wasn't sending "!clear", I was sending "[]1,0!Clear"


Link Copied to Clipboard