Post "match" Operators

About Post Match Operations

Main Page Installation Configuration Permissions Commands Post-Match Operators Regex Samples GitHub


PwnFilter makes use of several post match operators, to react to positive matches from your regular expressions rules. Here we will cover these operators and show you how they can be used to make PwnFilter the most powerful chat filter plugin available. These rules are applied in your rules.txt after the "match".

NOTE: Rules are applied in the order they are listed in this file. Using the "then abort" action will stop further rule processing. So, if you want a rule to take priority over the others, list it first in this file. If you want a rule to stop further processing, use "then abort" as an action to that rule.

Variables

%world% ,%player%, %string%, %rawstring%, %event%, %ruleid%, %ruledescr% Detailed info coming soon.

Post Match List

  • ignore user <username1 username2> - rule will ignore any users defined separated by spaces.
  • require user <username1 username2> - rule will require any users defined separated by spaces.
  • ignore permission <permission.node1 permission.node2> - rule will ignore players with permissions defined separated by spaces. (Available in 1.3)
  • require permission <permission.node1 permission.node2> - rule will require players with permissions defined separated by spaces. (Available in 1.3)
  • ignore command <command1|command2> - rule will ignore defined commands from a pipe separated list. (Available in 2.3.4)
  • require command <command1|command2> - rule will required defined commands from a pipe separated list. (Available in 2.3.4)
  • ignore string <string1|string2|string3> - rule will ignore matches containing defined strings from a pipe separated list. (Available in 1.4)
  • ignore signs - rule will ignore matches on signs. (Available in 2.4.0) (Removed in 3.0)
  • events <chat,command,sign> Only apply this rule to the events listed (default = all events) (Available in 3.0) OR
  • events not <chat,command,sign> Apply this rule to ALL events, -except- those listed after the "not" keyword (Available in 3.0)
  • then abort - stop processing any rules after this one.
  • then replace <optional string> - replace match with defined string or nothing at all. Best for swear filters, etc.
  • then rewrite <optional string> - like replace, only does not filter color codes. Best for fun filters. (Available in 1.3)
    • NOTE As of 3.0.0, the filter will now preserve color codes that are not part of the match. Also, we will insert any color codes in replace or rewrite strings.
  • then randrep <string1|string2|string3> - replace matches randomly from the pipe separated list of words. (Available in 2.0.0)
  • then warn <optional string> - send user warning message after match.
  • then command <optional string> - if left empty it will use your chat message
    • variables: (Available in 1.3)
      • %player%: returns the player name
      • %world%: returns the player world
      • %string%: returns the chat message (as modified by any previous rules)
      • %rawstring%: returns the original unfiltered message
      • %event%: returns the type of event that was triggered (eg: sign, item, chat, command)
  • then cmdchain (command string1|command string2) - Run chained commands as player from pipe separated list.
    • variables: (Available in 2.1.0)
      • %player%: returns the player name
      • %world%: returns the player world
      • %string%: returns the chat message (as modified by any previous rules)
      • %rawstring%: returns the original unfiltered message
      • %event%: returns the type of event that was triggered (eg: sign, item, chat, command)
  • then console <string> - executes string as console. Useful for connecting with punishment plugins to mute or ban someone. Very Powerful - Be Careful!
    • variables: (Available in 1.3)
      • %player%: returns the player name
      • %world%: returns the player world
      • %string%: returns the chat message (as modified by any previous rules)
      • %rawstring%: returns the original unfiltered message
      • %event%: returns the type of event that was triggered (eg: sign, item, chat, command)
  • then conchain (command string1|command string2) - Run chained console commands.
    • variables: (Available in 2.1.4)
      • %player%: returns the player name
      • %world%: returns the player world
      • %string%: returns the chat message (as modified by any previous rules)
      • %rawstring%: returns the original unfiltered message
      • %event%: returns the type of event that was triggered (eg: sign, item, chat, command)
  • then debug - prints debug information to console for development purposes.
  • then deny - complete cancels the matching message so it never appears in chat.
  • then kick <optional string> - kicks player from server with optional kick message.
  • then burn <optional string> - burns player with optional burn message. (Available in 1.9.3)
  • then kill <optional string> - kills player with optional kill message. (Available in 1.9.3)
  • then fine <amount> <string> - removes <amount> from the player's balance and sends <string> as a message to the player. ( New in 3.1 )
  • then lower - used alone paired with the proper regex, this operator will replace any match with all lower case letters. Great for anti-caps replacement instead of just warning or blocking. (Available in 2.0.0)
  • then log - Will cause this match to be logged to the server log, regardless of loglevel setting. (Updated in 3.0)

Comments

  • To post a comment, please or register a new account.
Posts Quoted:
Reply
Clear All Quotes