Jump to content

Archived

This topic is now archived and is closed to further replies.

chain

Triggers (like !rules)

Recommended Posts

  • Administrators

If you'd like to create some !triggers for your channel copy and paste this script in to your Remotes in mIRC.

 

Note: You'll need to make some modifications before it'll be ready to use. These modifications are explained below the code. Also, these triggers cannot be invoked by you if they're running on the copy of mIRC you are using to chat. So, if you wish to invoke these triggers yourself you'll need to run two copies of mIRC. One for you to chat with and another one that'll run this script (and possibly others. It'll essentially be a "bot.")

 

>on 1:text:!rules:#channel: {    if (($calc(($ctime - %lastupdatetime)) >= 15) || (!%lastupdatetime)) {      set %lastupdatetime $ctime  /msg $chan Your-rules-or-message-goes-here   }}

 

You'll need to change #channel on the 1st line to your channel's name.

 

The 2nd and 3rd line calculates how long ago this trigger was used and prevents it from being triggered again in so many minutes. In this example it can only be triggered once every 15 minutes. You can make it shorter or longer by changing the 15 to however many minutes you want it to be.

 

The 4th line contains the message you want sent to the channel. Leave /msg $chan the way it is and replace Your-rules-or-message-goes-here with whatever you want sent.

 

 

How to have more than one trigger:

You can copy this script and change the 1st and 4th lines to send different messages. Just place every copy below the preceding one in mIRC's Remotes.

 

Example:

 

>on 1:text:!rules:#channel: {    if (($calc(($ctime - %lastupdatetime)) >= 15) || (!%lastupdatetime)) {      set %lastupdatetime $ctime  /msg $chan If you repeat yourself, talk in caps, are abusive, or use sexually explicit language you won't be able to chat anymore.   }}on 1:text:!voice:#channel: {    if (($calc(($ctime - %lastupdatetime)) >= 15) || (!%lastupdatetime)) {      set %lastupdatetime $ctime  /msg $chan To get voiced you need to behave and follow the rules.   }}on 1:text:!cam:#channel: {    if (($calc(($ctime - %lastupdatetime)) >= 15) || (!%lastupdatetime)) {      set %lastupdatetime $ctime  /msg $chan I'm using a Logitech Quick Cam   }}

Link to comment
Share on other sites



×
×
  • Create New...