mIRC Home    About    Download    Register    News    Help

Print Thread
#178964 16/06/07 09:00 PM
M
Mlupu
Mlupu
M
Another quwstion. laugh

Whem i opened and start my mirc i want to see a text like:

"welcome Mlupu, do you want to connect to irc.network.irc (exemple)
A window i want to opened and there i want to click on Yes or No button. To begin or not the connection smile

Thanks !

#178967 16/06/07 09:04 PM
Joined: Oct 2004
Posts: 8,061
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Oct 2004
Posts: 8,061
I believe this is correct, but I don't use $input often, so I may have the syntax incorrect and I don't have mIRC here to look at.

Code:
on *:start: {
  if ($input(Welcome Mlupu, do you want to connect to irc.network.com?,yes,no) == yes) { server irc.network.com }
}

#178968 16/06/07 09:07 PM
Joined: Dec 2002
Posts: 3,534
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,534
Code:
on *:start: {
  if ($input(Welcome $me $str($crlf $+ ,2) Do you want to connect to irc.network.com?, y,)) { server irc.network.com }
}

M
Mlupu
Mlupu
M
thanks Slade.

#178971 16/06/07 09:20 PM
Joined: Dec 2002
Posts: 3,534
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,534
Just an addition, you don't have to use it but I thought it would be a good idea to ask if you wanted to connect to the last server you were connected to.

Code:
on *:start: {
  var %s = $gettok($gettok($window($active).title,2,44),1,41)
  if ($input(Welcome $me $str($crlf $+ ,2) Do you want to connect to $+(%s,?), y,)) { server %s }
}

M
Mlupu
Mlupu
M
yeap . Is more like it.

i had try when i am connected i want to ask me if i want to login me. and is not work frown
Code:
on *:connect: {
  if ($input($me $str($crlf $+ ,2) Do you want to login to irc.network.com?, y,)) { msg x@channels.network_name.com login $2- $?*      }
}

#178973 16/06/07 09:28 PM
Joined: Dec 2002
Posts: 3,534
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,534
For that you would need:

Code:
On *:Connect: {
  if ($server == someserver) { login stuff }
}

M
Mlupu
Mlupu
M
the is not working frown

Code:
On *:CONNECT: {
  if ($server == server_name.network_name.org) { msg x@channels.network_name.org login mlupu $?* }
}


#178985 16/06/07 10:43 PM
Joined: Feb 2006
Posts: 180
C
Vogon poet
Offline
Vogon poet
C
Joined: Feb 2006
Posts: 180
Code:
On *:CONNECT: {
  if ($network == YourNetwork) { msg x@channels.network_name.org login mlupu $?* }
}

Crinul #179022 17/06/07 09:48 AM
M
Mlupu
Mlupu
M
is not working.. frown

#179023 17/06/07 10:18 AM
M
Mlupu
Mlupu
M
I made it. This code is working:
Code:
on *:CONNECT: {
  if ($input($me $str($crlf $+ ,2) Do you want to login toX ?, y,)) { .msg x@channels.network_name.org login $2- $?*  }
  if ($input($me $str($crlf $+ ,2) Do you want to be an IRCoperator ?, y,)) { .oper $2- $?* }
}


Link Copied to Clipboard