2
Donate to the B3 fund!

"even a small donation helps!"
Donate with PayPal!
Most of the plugins here are made by B3 users and the authors may not visit frequently. If you need support for plugins or if questions remain unanswered, you will have to contact the author directly. Read the full Support Disclaimer here

NOTE: Do not attach plugins to your forumtopics! Attachements are periodically removed by maintenance tasks. Upload your plugins to our Downloads section instead!

Author Topic: Chat Plugin  (Read 40067 times)

Offline xlr8or

  • [ www.xlrstats.com ]
  • Project Lead
  • Hero Member
  • *
  • Posts: 2057
    • The Art of Tactical Gaming
Chat Plugin
« on: September 26, 2009, 10:13:38 AM »
Chat Plugin by walker from 1stsop:

v1.0.0 (original by Walker): http://www.1stsop.nl/b3/chat.zip
latest version: http://www.bigbrotherbot.com/forums/downloads/?sa=view;down=31
« Last Edit: November 15, 2009, 12:59:01 AM by Courgette »

Offline Walker

  • Jr. Member
  • **
  • Posts: 23
Re: Chat Plugin
« Reply #1 on: September 26, 2009, 11:39:19 AM »
Now that's been a while :)...

Offline Spoon

  • Sr. Member
  • ****
  • Posts: 255
    • EHD Gaming
Re: Chat Plugin
« Reply #2 on: September 26, 2009, 02:17:55 PM »
nice plugin i just added to my server.

Offline Walker

  • Jr. Member
  • **
  • Posts: 23
Re: Chat Plugin
« Reply #3 on: September 26, 2009, 02:47:23 PM »
It looks like your console is alive :)

Offline Courgette

  • Senior Dev.
  • Hero Member
  • *
  • Posts: 4882
    • Github repository
Re: Chat Plugin
« Reply #4 on: November 14, 2009, 11:02:38 PM »
v1.1.0 : add keywords $time and $nextmap

Offline xavierk

  • Jr. Member
  • **
  • Posts: 16
Re: Chat Plugin
« Reply #5 on: April 04, 2010, 01:37:32 AM »
Sorry, still new to this, but what exactly does a "Chat Plugin" do?  Could someone provide a description of what this plug does.


Thank you!

Offline soggyoreo

  • Full Member
  • ***
  • Posts: 127
    • The Firm
Re: Chat Plugin
« Reply #6 on: April 04, 2010, 01:46:16 AM »
Quote
###################################################################################

Chat plugin (v1.0.0) for B3
###################################################################################

This plugin will let the console react on ingame chat messages and so, your console
will come alive :)...

Some basic reactions are configured in the plugin_chat.xml config file.

It is possible to configure multiple reactions on one trigger. The bot will
then choose one reaction out of the available ones when the chat trigger fires.

The 'triggers' are highly configurable because they are written in regular
expressions. Examples are included.

Quote
<messages>
      <message>
         <comment>If someone types 'help' without the !</comment>
         <trigger>^( help )$</trigger>
         <reaction>Type ^3!help^7 to see all my options $player</reaction>
      </message>
      <message>
         <comment></comment>
         <trigger>(cheat)</trigger>
         <reaction>Cheaters are the biggest dumbass losers ever!</reaction>
         <reaction>We do NOT like cheaters... hope they make mistakes real soon</reaction>
         <reaction>A good cheater is a dead cheater!</reaction>
         <reaction>Cheaters are like cochroaches, they should be squashed!</reaction>
      </message>
      <message>
         <comment>If someone types 'name foo', console will react and try to help</comment>
         <trigger>^( name)</trigger>
         <reaction>You should change your name in your multiplayer options $player</reaction>
      </message>
      <message>
         <comment>Hi reaction</comment>
         <trigger>\sh[eoa]*[ij]\s|\sh[ea]+l+o+\s|\sheej?\s|\se+j\s</trigger>
         <reaction>Hi there $player!</reaction>
         <reaction>Hello there yourself $player!</reaction>
         <reaction>Howdy doody $player!</reaction>
      </message>
      <message>
         <comment>Recruiting questions</comment>
         <trigger>(((cruit)|(join)).*((sop)|(clan)|(you)))|(((sop)|(clan)|(you)).*((cruit)|(join)))</trigger>
         <reaction>One can only join 1stSoP by invitation $player.</reaction>
      </message>
   </messages>

Description isn't really clear, but by looking at the config and readme in the file it puts triggers on chat for automated responses...

Offline ryry46d9

  • B3 Contrib/Support
  • Sr. Member
  • *
  • Posts: 337
    • Pb| clan
Re: Chat Plugin
« Reply #7 on: April 04, 2010, 04:15:37 AM »
Code: [Select]
 <message>
                        <comment>azza2</comment>
                        <trigger>( hacker )</trigger>
<reaction>^7Post a demo or STFU</reaction>
                        <reaction>^7some day, you'll get just as good $player</reaction>
                </message>

If some one types
Quote
hacker
 they will get
Quote
Post a demo or STFU
or will get
Quote
some day, you'll get just as good $player


Offline Skajaquada

  • Jr. Member
  • **
  • Posts: 40
Re: Chat Plugin
« Reply #8 on: April 12, 2010, 05:43:55 PM »
Or my favorite. :)


Code: [Select]
		<message>
<comment>Skajaquada WILL ban you too!</comment>
<trigger>^( .*skaj.* )$</trigger>
<reaction>Skajaquada ^1WILL ^7ban you too!</reaction>
</message>


Offline grosbedo

  • Former Dev. (senate)
  • Sr. Member
  • *****
  • Posts: 258
Re: Chat Plugin
« Reply #9 on: August 11, 2010, 02:54:16 PM »
Hello,

I think there is a bug in the detection of regexprssion that contains more than 1 word.

Here is a basic example of what I tried to do :
Code: [Select]
		<message>
<comment>time</comment>
<trigger>^( time | what time )</trigger>
<reaction>^2$time</reaction>
</message>

It detects "time" successfully, but not "what time". Ive tried many other alternatives, none worked.

Offline Courgette

  • Senior Dev.
  • Hero Member
  • *
  • Posts: 4882
    • Github repository
Re: Chat Plugin
« Reply #10 on: August 11, 2010, 02:57:58 PM »
have you tried
Code: [Select]
		<message>
<comment>time</comment>
<trigger>(time|what\s+time)</trigger>
<reaction>^2$time</reaction>
</message>
« Last Edit: August 11, 2010, 03:00:10 PM by Courgette »

Offline grosbedo

  • Former Dev. (senate)
  • Sr. Member
  • *****
  • Posts: 258
Re: Chat Plugin
« Reply #11 on: August 12, 2010, 10:47:24 AM »
have you tried
Code: [Select]
		<message>
<comment>time</comment>
<trigger>(time|what\s+time)</trigger>
<reaction>^2$time</reaction>
</message>

Yes, it doesn't work. But from what I could read in the DB in penalties, I think I've got a clue : the spaces are removed prior to the detection of strings. I will try by removing any space instead.

Offline grosbedo

  • Former Dev. (senate)
  • Sr. Member
  • *****
  • Posts: 258
Re: Chat Plugin
« Reply #12 on: August 19, 2010, 01:02:49 PM »
my own config :

Code: xml [Select]
		<message>
<comment>Hackers/cheats</comment>
<trigger>((cheat)|(cheats)|(cheater)|(cheating)|(hacker)|(hack)|(aimbot)|(wallhack))</trigger>
<reaction>^2/record a demo and post it on www.^7superbots.org ^2instead of cursing</reaction>
            <reaction>^2you'll see, $player, some day, you'll get just as good</reaction>
</message>
<message>
<comment>Camping</comment>
<trigger>((camp)|(camper)|(camping)|(flagcamp)|(flagcamper)|(flagcamping))</trigger>
<reaction>^2Go to ^1supeR^5,^7CTF2^2, there is an automatic anti-camp system</reaction>
</message>
<message>
<comment>Lag (but not delag or flag or unlag)</comment>
<trigger>(^ |re|[^du][^enf])((la[g]+[s]*)|(lagin)|(laggin)|(lagging)|(lagger)|(connection))</trigger>
<reaction>^2Go to ^1supeR^5,^7CTF2^2, there is _full_ delag for _all_ weapons</reaction>
<reaction>^2To optimally reduce lag, set ^3/snaps 25^2, ^3/cl_maxPackets 125 ^2and ^3/rate 25000</reaction>
</message>
<message>
<comment>If someone types 'name foo', console will react and try to help</comment>
<trigger>^( name)</trigger>
<reaction>^2You should change your name in your multiplayer options $player or type /name</reaction>
</message>
<message>
<comment>Hi reaction</comment>
<trigger>\sh[eoa]*[ij]\s|\sh[ea]+l+o+\s|\sheej?\s|\se+j\s</trigger>
<reaction>^2Hi $player</reaction>
<reaction>^2Hello $player</reaction>
<reaction>^2Hi there $player!</reaction>
<reaction>^2And here comes... DA $player!</reaction>
</message>

Offline ryry46d9

  • B3 Contrib/Support
  • Sr. Member
  • *
  • Posts: 337
    • Pb| clan
Re: Chat Plugin
« Reply #13 on: August 19, 2010, 01:17:23 PM »
or you can just be lazy like I :
Code: [Select]
<message>
                        <comment>time</comment>
                        <trigger>(((time)))</trigger>
                        <reaction>^4$time</reaction>
                </message>

Offline learco

  • Full Member
  • ***
  • Posts: 124
Re: Chat Plugin
« Reply #14 on: September 03, 2010, 05:44:21 PM »
is it different
Code: [Select]
 <comment>If someone types 'name foo', console will react and try to help</comment>
         <trigger>^( name)</trigger>
         <reaction>You should change your name in your multiplayer options $player</reaction>
to
Code: [Select]
 <comment>If someone types 'name foo', console will react and try to help</comment>
         <trigger>^(name)</trigger>
         <reaction>You should change your name in your multiplayer options $player</reaction>
where "name" isn't empty.
is there a different reaction?

then:
Code: [Select]
<comment>Recruiting questions</comment><trigger>(((cruit)|(join)).*((sop)|(clan)|(you)))|(((sop)|(clan)|(you)).*((cruit)|(join)))</trigger><reaction>One can only join 1stSoP by invitation $player.</reaction>
i try to write "cruit" but doesn't work.
i don't understand what's the cause.

thank you for this 2 things!

 


Rate this page +1 at Google Search