mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: Jan 2016
Posts: 43
T
Ameglian cow
OP Offline
Ameglian cow
T
Joined: Jan 2016
Posts: 43
I want to make a command that when someone sends a PM to my bot with (lets say for example)

!voice techchef

my bot would then add techchef to the auto voice list.
is this possible?

Joined: Dec 2008
Posts: 1,515
Hoopy frood
Offline
Hoopy frood
Joined: Dec 2008
Posts: 1,515
Try use this code:

Syntax: !voice <nickname> <#channel>

Code:
ON *:TEXT:*:?: {
  tokenize 32 $strip($1-)
  if ($1 == !voice) {
    if (!$2) { .msg $nick Error, Please specify a nickname! | return }
    if (!$3) { .msg $nick Error, Please specify a channel! | return }
    if ($avoice($2 $+ !*@*)) { .msg $nick Error, This nickname is already exists! | return }
    .avoice $2 $3 $network
    .msg $nick The $qt($2) nickname has been added into the autovoice list for $qt($3) channel into $qt($network) network.
  }
}


Need Online mIRC help or an mIRC Scripting Freelancer? -> https://irc.chathub.org <-
Joined: Jan 2016
Posts: 43
T
Ameglian cow
OP Offline
Ameglian cow
T
Joined: Jan 2016
Posts: 43
OK it kinda works...Is there a way we can do it without having to put the channel in? If not-its OK-Just asking smile

Joined: Jan 2004
Posts: 1,358
L
Hoopy frood
Offline
Hoopy frood
L
Joined: Jan 2004
Posts: 1,358
Are you only in a single channel? Hardcode it. Otherwise, no.

Joined: Jan 2016
Posts: 43
T
Ameglian cow
OP Offline
Ameglian cow
T
Joined: Jan 2016
Posts: 43
its actually 2 channels that the bot runs and both are used by the same users (the ones that will be auto voiced anyways)


Link Copied to Clipboard