mIRC Home    About    Download    Register    News    Help

Print Thread
#35122 09/07/03 05:37 AM
Joined: Jul 2003
Posts: 2
A
Bowl of petunias
OP Offline
Bowl of petunias
A
Joined: Jul 2003
Posts: 2
Hiya folks. I'd like some jabs in the right direction as to how to get my bot to be "animated" via ops. I'd like ops to be able to have the bot talk and do /me actions (in the main channel) at the direction of the channel ops.

I've seen this before in another channel, useing .say and .me as triggers in private message with the bot. I'm fairly new at programming IRC, but have some experience with other languages, so I'm not entirely unfamilliar with programming.

Thanks for anything you're able to offer!
Amethyst


I am too scared to close my eyes.
Joined: Jul 2003
Posts: 46
V
Ameglian cow
Offline
Ameglian cow
V
Joined: Jul 2003
Posts: 46
heh, i am a newb too, but i will write something that may work out for you... i will not test it.


  • on *:TEXT:.me:?: { if ($nick isop #chanyouwantittosaytoo) { me #chanyouwantotsayto $2- | halt } }
    on *:TEXT:.say:?: { if ($nick isop #chanyouwantittosaytoo) { say #chanyouwantotsayto $2- | halt } }


agian this is not tested so if it does not work you can type /help on Text inside mirc and you should be able to find what your looking for.

Joined: Dec 2002
Posts: 3,547
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,547
Lets assume the level of the ops is 100.
Code:
on 100:TEXT:!me*:?: {
  if ($2 == $null) { notice $nick Valid syntax is: !me #channelname Message }
  if ($2) && ($3) { describe $2 $3-  }
}



This will trigger in a Private Message.
Level 100 users type: !me #Channel message


/help on text

Joined: Dec 2002
Posts: 3,547
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,547
Firstly you can't use the /me command in a on text event. Secondly what if the original poster has more than one channel. I have to give credit to you on the /halt command though.
Code:
on *:TEXT:.me*:?: { 
if ($nick isop $2) { describe $2 $3- | halt }
}
on *:TEXT:.say*:?: { 
if ($nick isop $2) { say $2 $3- | halt }
}

Joined: Jul 2003
Posts: 46
V
Ameglian cow
Offline
Ameglian cow
V
Joined: Jul 2003
Posts: 46
Like I said I am a newb, thank you for showing me the correct way, I will never us it in this way but it may come in handy sometime.

Joined: Dec 2002
Posts: 3,547
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,547
It's ok. grin

Joined: Mar 2003
Posts: 54
J
Babel fish
Offline
Babel fish
J
Joined: Mar 2003
Posts: 54
Quote:
I'm fairly new at programming IRC, but have some experience with other languages, so I'm not entirely unfamilliar with programming.


Don't be mistaken, this is programming mIRC smile

Joined: Dec 2002
Posts: 774
T
Hoopy frood
Offline
Hoopy frood
T
Joined: Dec 2002
Posts: 774
This has nothing to do with programming... This is scripting...


Code:
//if ( khaled isgod ) echo yes | else echo no
Joined: Dec 2002
Posts: 3,547
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,547
theRat, nice signature.
* SladeKraven knows Khaled is god. grin

#35131 09/07/03 04:26 PM
Joined: Jul 2003
Posts: 2
A
Bowl of petunias
OP Offline
Bowl of petunias
A
Joined: Jul 2003
Posts: 2
I'lll give your suggestions a try, and let ya know what happens.


I am too scared to close my eyes.
Joined: Mar 2003
Posts: 54
J
Babel fish
Offline
Babel fish
J
Joined: Mar 2003
Posts: 54
Scripting in mIRC, that's what I meant.


Link Copied to Clipboard