mIRC Homepage

help

Posted By: bibadi

help - 25/03/03 08:39 PM

Kick on advert?
Voice on join
when 1 says 'lo' or 'hello' or 'lo all' or 'hi' say hi $nick
can u guys help me out? please
ty anyways
Posted By: Kazz

Re: help - 25/03/03 08:54 PM

Code:
On *:TEXT:http//:*:{
 { msg chanserv kick # $nick }
 }
}

On *:TEXT:www.:*:{
 { msg chanserv kick # $nick }
 }
}

On *:JOIN:*:{
 { if ($nick =  [color:red]<nickname>[/color])   { msg chanserv voice # $nick }
  }
}

On 1:TEXT:hi:#: /msg $chan hi $nick

On 1:TEXT:'lo:#: /msg $chan hi $nick

On 1:TEXT:'lo all:#: /msg $chan hi $nick

On 1:TEXT:hello:#: /msg $chan hi $nick
  


I think this should take care of it.
Posted By: bibadi

Re: help - 25/03/03 09:04 PM

ehm:P that's gamesnet?
and i want to kick 1 already when only saying #
And voice every1 that joins a channel where i have ops
(i use quakenet)
Posted By: _D3m0n_

Re: help - 25/03/03 09:49 PM

ok if u cant change a line of command that was shown to u ..... then really ur not looking for info or help or to even learn anything ..... ur looking for a already made script ....... to find one of those go to mircscripts.org or one of them other sites
Posted By: bibadi

Re: help - 26/03/03 11:36 AM

Well, I'm a noob. And I do want to learn, but I think i can not learn anything without seeing it before. and I already tried something
On 1:JOIN:#: set +v $nick
and
On *:TEXT:#:{
{ msg chanserv kick # $nick } }}
}
But i'm sure it won't work, so i need help, and if u don;t tell me how. how am i ever gonne learn it?
Posted By: Aubs

Re: help - 26/03/03 01:31 PM

The following should work for all networks.

on @*JOIN:#:{ mode $chan +v $nick }


the text events are like this:
Code:
on [color:red]@[/color]*:TEXT:*:#:{
  if ((http://* iswm $1-) [color:blue]||[/color] (www.* iswm $1-)) { .mode +b $address($nick,3) [color:orange]|[/color] .kick $chan $nick Banned. Do not advertise websites in $chan }
  if (($1 == lo) [color:blue]||[/color] ($1 == hello) [color:blue]||[/color] ($1 == lo all) [color:blue]||[/color] ($1 == hi)) { msg $chan HI $nick $+ ! }
}

@ - means it will only do the commands if you are oped (remove @ if you want the script to attempt it at all times)
|| - Using abc, then: if ((a = a) or (b == b) or (c == c)) { do this }
So if either one of them is correct, it works. You could always do each one individually like Kazz shows above.
| - this is only used in the actions part of the script to keep text in less lines.
The example above could have been written as:
Code:
on [color:red]@[/color]*:TEXT:*:#:{
  if ((http://* iswm $1-) [color:blue]||[/color] (www.* iswm $1-)) {
     .mode +b $address($nick,3)
     .kick $chan $nick Banned. Do not advertise websites in $chan
  }
  if (($1 == lo) [color:blue]||[/color] ($1 == hello) [color:blue]||[/color] ($1 == lo all) [color:blue]||[/color] ($1 == hi)) { msg $chan HI $nick $+ ! }
}

From the help file (/help Aliases):
Quote:
For multiple commands you should use a | character (the shifted character usually under the \ key). So to write an alias that kicks and bans someone:
/dkb /kick # $1 | /mode # +b $1



If you want to reply with different messages, then use:


Code:
on [color:red]@[/color]*:TEXT:*:#:{
  if (http://* iswm $1-) {
     .mode +b $address($nick,3)
     .kick $chan $nick Banned. Do not advertise in $chan
  }
  if (www.* iswm $1-) {
     .kick $chan $nick Banned. Do not advertise in $chan
  }

  }
  if (($1 == lo) { msg $chan lo $nick $+ ! }
  if ($1 == hello) { msg $chan Hello $nick $+ ! }
  if ($1 == lo all) { msg $chan Hi $nick }
  if ($1 == hi) { msg $chan Hi $nick $+ ! }
}


This time, the different actions are:
[edit] Had to replace this as it looked all messed up!
Code:
| TEXT                |                      |
|Starts With | Is     | Actions              |
|------------|--------|----------------------|
| http://    |        |Ban + Kick            |
| www.       |        |Kick                  |
|            | lo     |Reply "lo <nick>!"    |
|            | hello  |Reply "Hello <nick>!" |
|            | lo all |Reply "Hi <nick>"     |
|            | hi     |Reply "Hi <Nick>!"    |
[/edit]


REMEMBER:
You cannot have two of the same events in the same script file.
e.g. you cannot have two on *:TEXT:*:#:{} or on *:JOIN:#:{} events in the same file


Hope the above helps you in some way! smile
Posted By: bibadi

Re: help - 26/03/03 01:38 PM

thanks m8, u really helped me out this time:D
Posted By: Aubs

Re: help - 26/03/03 02:07 PM

NP mate smile

Glad I could help!!!
© 2022 mIRC Discussion Forums