mIRC Home    About    Download    Register    News    Help

Print Thread
#87865 23/06/04 01:16 AM
Joined: Jun 2004
Posts: 13
S
Skrubz Offline OP
Pikka bird
OP Offline
Pikka bird
S
Joined: Jun 2004
Posts: 13
would some one tell me how to write a script that will start a timer when I join a specific channel and then stop a minute or two after!?!

I want to authenticate in a certain channel when I join...in the event of netsplits and if I am away from the puter.

Appreciate any assist...and thanx in advance!1

#87866 23/06/04 01:44 AM
Joined: Dec 2002
Posts: 788
C
Hoopy frood
Offline
Hoopy frood
C
Joined: Dec 2002
Posts: 788
I'm not totally sure you want to keep running a command several times, i.e. 5 seconds up-until 2 minutes after joining OR if you want to join, wait 2 minutes then execute 1 command

for executing a command every 5 seconds for 2 minutes there are two ways of doing it:

1.

On me:*:Join:#CHANNELHERE:{
.timerjoined 24 5 COMMANDHERE
}

Whereby in the above.. 5 is the delay between commands, and 24 is the number of 5s that will go into 2 minutes this way the timer stops on its own. alternatively..

2.

On me:*:Join:#CHANNELHERE:{
.timerjoined 0 5 COMMANDHERE
.timerstopjoined 1 120 .timerjoined off
}

The above executes a command every 5 seconds forever (first line).. and the second line runs a timer to execute ONCE, after 120 seconds (2 minutes) which will stop the first timer..

If your looking for this then i would personally use the first option.. if your looking for something to execute ONCE, 2 minutes after you join then use..

On me:*:Join:#CHANNELHERE:{
.timerjoined 1 120 COMMANDHERE
}

Hope this perhaps cleared it up, if not dont hesitate to ask for more information..

Eamonn.

#87867 23/06/04 02:29 AM
Joined: Jun 2004
Posts: 13
S
Skrubz Offline OP
Pikka bird
OP Offline
Pikka bird
S
Joined: Jun 2004
Posts: 13
When I read my question back...I thought maybe it would not be that clear, but tried it anyway....sorry!!

Let me try again....It has to do with 'cloaking' my IP address on the Undernet. My 'puter is often on for hours at a time due to having Op status in a channel...without me being near it for extended periods of time.

I have a small script running that recovers my initial nick. I also have this running, which authenticates me:

***on 1:CONNECT:/msg x@channels.undernet.org login <nick> <password> | /mode <nick> +x***

However. Often due to additional netsplits, the 'cloaking' fails when I return on-line, and the cloaking authentication will fail and my original IP address is evident.

What I would like to do, is to set a timer, whereby, should this happen...I will re-authenticate after a short period of time.

I originally tried the following, without success....

on 1:CONNECT: {
timer1 0 300 msg x@channels.undernet.org login <nick> <password | /mode <nick> +x
timer1 0 420 Off
}

I am, however, waaaaaay out in left field with it, I am sure.

I hope this clarifies my problem and...again...any assistance would be greatly appreciated.

#87868 23/06/04 03:45 AM
Joined: Jun 2004
Posts: 13
S
Skrubz Offline OP
Pikka bird
OP Offline
Pikka bird
S
Joined: Jun 2004
Posts: 13
You are absolutely correct....sorta....again, it appears that I have neglected to be as clear as I should be....my problem is apparently not netsplits, per say...but is the fact that I am continuously disconnected with the dreaded *10053 error, software caused connection abort*...and therefore believe that such a script would solve my problem...Don't you think!?!

I have tried many, many, suggested resolutions to the *10053* problem and have come to the conclusion that the script I am suggesting here will be some kind of resolution any way!! confused confused confused

#87869 23/06/04 07:03 PM
Joined: Jun 2003
Posts: 994
C
Hoopy frood
Offline
Hoopy frood
C
Joined: Jun 2003
Posts: 994
First off, put your primary nickname on notify (/notify my-primary-nickname)
then put all this in remotes: (it MUST be formatted as it is here)
Code:
on 1:CONNECT: {
  if ($me !isin my-primary-nickname) { return }
  msg x@channels.undernet.org login &lt;nick&gt; &lt;password 
}
on *:unotify: {
  if ($nick != my-primary-nickname) { return }
  nick my-primary-nickname
  msg x@channels.undernet.org login &lt;nick&gt; &lt;password
}

on 1:notice:AUTHENTICATION SUCCESSFUL as &lt;nick&gt;:*: {
  mode $me +x
  timerjc 1 20 join #channel1,#channel2
}

The connect logs in to X if you already have your nickname, and stops if you do not.

The unotify will get your nickname back when it pings out (or whatever the error message is), and will then login to X for you (since you cannot login to X until the main nickname that's already logged in is gone).

The last one will mask your IP address and rejoin the channels AFTER it's masked (don't use rejoin channels on connect if you want this, otherwise remove the join timer).

Last edited by CtrlAltDel; 23/06/04 07:04 PM.

I refuse to engage in a battle of wits with an unarmed person. wink

Link Copied to Clipboard