当前版本: 1.3.2.1
推荐构建: 1.3.2-R1 (Craftbukkit build - 2377)
重要提示:在 2.3.1b 中,匹配机制已更改。请参阅发行说明以获取更多信息。
简介
这是什么?
是否曾遇到过玩家不断辱骂的情况?或者你希望拥有一个适合全年龄段的服务器?又或者你想阻止别人索要钻石?现在你不必再为此烦恼了:CurseBan 允许你添加“监控词”——每当玩家提及其中任何一个词时,他就会被踢出。同时,该插件会为每个被监控的词记录一个“诅咒值”。每次玩家使用该词时,该词的诅咒值就会累加到玩家的点数中。你可以定义当用户达到特定阈值时执行的命令,并设置冷却时间以减少点数。
它是如何工作的?
每个受诅咒/禁用的词都被分配了一定的点数。每当玩家使用这些词中的一个时,该词的点数就会添加到该玩家的总计数中。然后,执行与该总数值关联的命令。如果没有关联的命令,则执行下一个最低的数值对应的命令。
命令、权限和示例
命令
- /cb - 显示帮助信息
- /cb list - 列出当前的监控词
- /cb add [word] <threshold> - 将该词及其封禁阈值添加到列表中。如果未指定阈值,则默认使用 5
- /cb remove [word] - 从列表中移除该词
- /cb pardon [player] - 将该玩家的踢出计数重置为 0(注意:如果玩家已被封禁,此操作不会解除封禁)
- /cb pardon-all - 将所有玩家的踢出计数重置为 0(注意:如果玩家已被封禁,此操作不会解除封禁)
- /cb save - 将所有文件保存到磁盘。请谨慎操作,这将覆盖尚未重新加载的文件中所做的更改。
- /cb set value [curse] [value] - 设置该诅咒的点数值
- /cb set matching [curse] [matchtype] - 设置该诅咒的匹配模式(允许的值:default, default-ignorecase, literal, literal-ignorecase, regex, regex-all-lower)
- /cb set kick [message] - 设置默认的踢出消息
- /cb set command [value] [command] - 设置当玩家达到或超过指定数值时执行的命令
- /cb listpoints [player] - 显示特定玩家的点数(区分大小写)
权限节点
(注意:任何子节点都可以由其父节点代表——你可以使用 cb.admin.* 来代替逐个输入每个节点)
- cb.admin.ignore - 你不会因骂人而被踢出
- cb.admin.pardon.all - 将所有玩家的踢出计数重置为零。不会解除他们的封禁
- cb.admin.pardon.single - 赦免单个玩家。同样不会解除封禁
- cb.admin.add - 将诅咒词添加到列表
- cb.admin.remove - 删除诅咒词
- cb.admin.save - 允许保存文件
- cb.admin.set.value - 允许设置禁用词的诅咒点数
- cb.admin.set.matching - 允许设置词的匹配模式
- cb.admin.set.kick - 允许设置默认的踢出消息
- cb.admin.set.command - 允许设置当达到某点数时执行的新命令或现有命令
- cb.list - 允许查看所有被监控的诅咒词列表
用法示例
- 禁止骂人:/cb add shit
- 禁止全大写输入:/cb add r:[A-Z]{3} 将对连续 3 个或更多大写字母的行为进行踢出
- 如果有人说 "supercalifragilistic" 就给他们钻石:/cb add i:supercalifragilistic 9000,在配置文件中,写入 9000: give %name% diamond 64;cb pardon %name%
示例
/cb add shit - 列表现在包含单词 shit,默认值为 5
/cb list -> "[shit]"
/cb add fuck 10 - 列表现在包含单词 fuck,值为 10
/cb list -> "[shit, fuck]"
/cb set command 0 kick %name% - 每当玩家说脏话且点数大于 0 时将其踢出(基本上总是如此)(注意:%name% 是一个用于表示玩家名称的变量)
/cb set command 10 jail %name% - 每当玩家说脏话且点数大于 10 时将其关入监狱
玩家 A 加入...
A: "This server is shit!" -> "shit" 的值为 5 -> A 现在有 5 点 -> 0 < 5 < 10,因此执行 "kick" 命令
A 重新加入...
A: "What the fuck, man?" -> "fuck" 的值为 10 -> A 现在有 15 点 -> 10 < 15,因此执行 "jail" 命令
所有这些也可以通过编辑 /plugin/CurseBan 中创建的 yaml 文件来完成——有关更多信息,请参阅此页面:
其他
待办事项
- 添加功能以告知玩家他们所说的不当用词,使用 %word%(你可以将其添加到监狱告示牌上,例如:- Swearing: 'shit' )
- 防止服务器在重启后覆盖由服务器所有者保存的文件。
更新日志
v1.3.2.1:
- 将版本号更改为反映其配置支持的当前 MC 版本。(1.3.2)并为此版本添加了额外的构建号(.1)。
- 修复了问题 18 和 20,解决了 PlayerChatEvent 相关的问题(本质上是用 AsycPlayerChatEvent 替换了该事件)。这似乎已解决了该问题,但老实说我不完全确定。请在工单系统中报告您发现的任何问题。请勿在此处发帖。
注意:此版本无法在 Tekkit 服务器上运行。请使用版本 2.5.0 用于 Tekkit 版本 3.1.2。
v 2.5.0:- 由新项目所有者 GokouZWAR 发布的首个版本
- 修复了点数随时间推移被添加到玩家身上而非扣除的问题。
- 增加了控制台追踪功能,记录玩家的点数变化,以便查看系统何时扣除玩家点数、扣除了多少以及具体时间。
- 更新以支持 Craftbukkit 1.2.5 - R4
- 在本页面添加了一些内容(之前缺失的命令、注释以及旧版修订信息)
v 2.4.0:- (不确定是否所有条目都已添加,但这些是我在更新页面找到的,可能是原作者希望在此版本中添加或修复的内容,我也不完全确定。由于它们标记为 2.4,我将把它们视为最后一次更新。 -GokouZWAR)
- (希望)修复了关闭服务器时配置文件未保存的问题
- 修复了 /cb set 匹配设置错误选项的问题
- 新增:日志记录保存到方法中
- 新增:重载命令 (/cb reload <all/config/curse/count>)。权限节点:cb.admin.reload(或者,可以仅针对单个文件授予权限 cb.admin.reload.<file>)
- 新增:列表命令 (/cb listpoints [player] - 玩家名称可选,省略则显示所有)。权限节点:cb.admin.listpoints
- 新增:配置文件选项 "save":决定文件应如何保存,除了关闭时的自动保存外:
- always(始终):每次修改任何文件时都进行保存
- config(配置):修改配置文件时进行保存
- curse(诅咒):修改诅咒文件时进行保存
- count(计数):修改计数文件时进行保存
- 可以使用多个选项:"save: config,curse"
v 2.3.3:
- 更新至 CraftBukkit 1.2.5-R1.0(呼,终于搞定了)
- 扩展日志记录,包含发现该词汇的消息内容。
v 2.3.2:
- 更新至 R6/1.2.3-R01
- 移除了所有已弃用的 API
- 包含新的匹配机制,更多信息请参阅发行说明
v 2.3.0:
- 为配置文件添加了变量:%points% 将被替换为玩家拥有的点数
- 实现了 :在配置文件中添加了 "log-actions" 选项(默认值:true)。这将记录:玩家名称、触发过滤器的词汇、随后发出的命令以及玩家的点数。
v 2.2.10:
- 将“始终踢出”检查移至任何执行的命令之后 - 这应该能修复 bug #6 (),该 bug 导致插件无法永久封禁玩家
v 2.2.9:
v 2.2.8:
v 2.2.7:
- 命令列表现在同时以 ";" 和 " ;" 分隔
- 启动和关闭时显示版本号
v 2.2.6:
- 修复 Bug #2 (#3, #4):onClientChat 中的 NullPointerException(空指针异常)
v 2.2.5:
v 2.2.4:
- 修复在使用 /cb pardon-all 后出现的空指针异常
- 增加了对多条命令的支持
- 新增 /cb save 命令
v 2.2.3:
- 更新至 MC 1.0.* / CB 1.0.1-R1
v 1.2.3:
- 增加了冷却时间(参见:“如何使用 .yml 文件”)
- 新增命令:/cb set literal [curse] [true/false]
- 新增权限节点:cb.admin.set.literal
v 1.2.2(最终版和测试版发行说明合并):
- 更新至 RB 1337
- 重构了诅咒惩罚系统
- 所有内容均切换为 Yaml 格式
- 添加了精确匹配:如果使用游戏内命令,则在单词前加 *;或在 Curses.yml 中使用 "literal-match" 选项
- 修复了 Curses 加载不正确的问题(如果您已经添加了诅咒词,但在游戏中未显示,请将 "Curse Point Value.yml" 重命名为 "Curses.yml")
- 支持自定义命令
v1.1.2:
- 更新至 RB 1317
- hopefully 修复了 PEX 问题
- 跳过了 v1.1.1,真是失误
v1.1.0:
v1.0.0:
联系方式
请在此提交工单,或在 联系我。邮箱:administrator at mcnations Dot Net。最新版本将在 server.mcnations.net:25599 上使用 - 运行的是 Tekkit。
Current Version: 1.3.2.1
Recommended Build: 1.3.2-R1 (Craftbukkit build - 2377)
IMPORTANT: With 2.3.1b, matching has been changed. Please see the release notes for additional information
About
What is this?
Ever had a player flaming constantly? Or maybe you want to have a family-friendly server? Or you want to stop people from asking for diamonds? Now you don't have to worry about that anymore: CurseBan allows you to add "stalk words" - Whenever a player mentions one of them, he gets kicked. At the same time, the plugin keeps track of a "curse value" for every stalked words. This curse value is added to the players point count every time he uses such a word. You can define commands that should be executed once a user reaches a certain threshold, and a cooldown to remove points.
How does it work?
Every curse/banned word is assigned a certain point value. Every time a player uses one of these words, the word's point value is added to that players total count. Then, the command associated with that total value is executed. If none is associated, the next lowest is executed.
Commands, Permissions and Examples
Commands
- /cb - Displays help
- /cb list - Lists the current stalk words
- /cb add [word] <threshold> - Adds the word with that ban threshold to the list. If no threshold is given, 5 is used
- /cb remove [word] - Removes that word from the list
- /cb pardon [player] - Sets that player's kick count to 0 (Note: Will not unban if he has been banned)
- /cb pardon-all - Sets the kick count of all players to 0( Note: Will not unban if they have been banned)
- /cb save - Save all files to the disk. Handle with care, this will overwrite and changes made to the files that have not yet been reloaded.
- /cb set value [curse] [value] - Sets the curse point value of the curse
- /cb set matching [curse] [matchtype] - Sets the matching for this curse (Allowed: default, default-ignorecase, literal, literal-ignorecase, regex, regex-all-lower)
- /cb set kick [message] - Sets the default kick message
- /cb set command [value] [command] - Sets the command to be executed whenever a player reaches or passes value
- /cb listpoints [player] - displays points for a specific player (case sensitive)
Permission nodes
(Note that any node can be represented by its parent node - You can use cb.admin.* instead of typing in every node one by one)
- cb.admin.ignore - You won't get kicked for cursing
- cb.admin.pardon.all - Will set the kick count of all players back to zero. Will not unban them
- cb.admin.pardon.single - Will pardon single player. Also no unban
- cb.admin.add - Add curses to the list
- cb.admin.remove - D'uh
- cb.admin.save - Allows to save files
- cb.admin.set.value - Allows to set the curse points value of a banned word
- cb.admin.set.matching - Allows to set matching for a word
- cb.admin.set.kick - Allows to set the default kick message
- cb.admin.set.command - Allows to set a new or existing command to be executed when a point value is reached
- cb.list - Allows to see a list of all stalked curses
Example Usages
- Stop cursing: /cb add shit
- Stop people from typing in ALL CAPS: /cb add r:[A-Z]{3} will kick for 3 or more consecutive uppercase letters
- Give people diamonds if they say "supercalifragilistic": /cb add i:supercalifragilistic 9000, in the config file, put 9000: give %name% diamond 64;cb pardon %name%
Examples
/cb add shit - The list now contains the word shit, with default value 5
/cb list -> "[shit]"
/cb add fuck 10 - The list now contains the word fuck, with a value of 10
/cb list -> "[shit, fuck]"
/cb set command 0 kick %name% - Kicks a player whenever he swears and has more than 0 points (Basically, always) (Note that %name% is a variable used to represent the player's name)
/cb set command 10 jail %name% - Jails a player whenever he swears and has more than 10 points
Player A joins...
A: "This server is shit!" -> "shit" has a value of 5 -> A now has 5 points -> 0 < 5 < 10, so the "kick" command is executed
A rejoins...
A: "What the fuck, man?" -> "fuck" has a value of 10 -> A now has 15 points -> 10 < 15, so the "jail" command is executed
All this can also be done by editing the yaml files created in /plugin/CurseBan - see this page for more information:
Misc
ToDo
- Add the ability to tell the player their bad word they said using %word% (You'd be able to add this to the jail sign (IE - Swearing: 'shit' ))
- Stop the server from overwriting files saved to the server by the server owner after a restart.
Changelog
v1.3.2.1:
- Changed version number to reflect current MC version it is configured for. (1.3.2) with additional build number for this (.1)
- Fixed issue 18 and 20 for issues with PlayerChatEvent (essentially replaced this even with AsycPlayerChatEvent) This seems to have resolved this issue, but I'm not entirely sure to be honest. Please report any issues you find to the ticket system. Do not post here.
Note this version will NOT work with tekkit servers. Use version 2.5.0 for Tekkit version 3.1.2.
v 2.5.0: -First release by new project owner GokouZWAR
- Fixed points being added to players instead of taking them away over time.
- Added console tracking for player's points so you can see when the system takes away player points, and how much was removed and when.
- Updated for Craftbukkit 1.2.5 - R4
- Added a few things on this page (commands that were missing, comments, and old missing revision information)
v 2.4.0: - (don't know if all these were added but I found these on the update page, possibly things he wanted added or had fixed in this version, not entirely sure. They were marked 2.4 so I'm going with this as the last updates. -GokouZWAR)
- (Hopefully) Fixed config not being saved on shutdown
- Fixed /cb set matching setting the wrong option
- Added: Logging to save methods
- Added: Reload command (/cb reload <all/config/curse/count>). Permission node: cb.admin.reload (alternatively, permission for one file only can be given by cb.admin.reload.<file>)
- Added: List command (/cb listpoints [player] - Player is optionally, omitting it will display all). Permission node: cb.admin.listpoints
- Added: Config option "save": Determines how files should be saved, in addition to the shutdown save:
- always: Save every file whenever it is modified
- config: Save the config file when modified
- curse: Save the curse file when modified
- count: Save the count file when modified
- Multiple options are possible: "save: config,curse"
v 2.3.3:
- Update to CraftBukkit 1.2.5-R1.0 (Phew, finally)
- Extended logging to include the message in which the word was found.
v 2.3.2:
- Updated to R6/1.2.3-R01
- Removed any deprecated API
- Included new matching, see release notes for more information
v 2.3.0:
- Added variable for the config file: %points% is replaced by the number of points the player has
- Implemented : Added "log-actions" option to the config file (default: true). This logs: The name of the player, the word that triggered the filter, the commands issued in return and the points of the player.
v 2.2.10:
- Moved the always-kick check behind any executed commands - This should fix bug #6 () which caused the plugin to not perma-ban people
v 2.2.9:
v 2.2.8:
v 2.2.7:
- Command lists are now separated by both ";" and " ;"
- Version number displayed on startup and shutdown
v 2.2.6:
- Fixed Bug #2 (#3, #4): NullPointerException in onClientChat
v 2.2.5:
- Changed indenting of the .yml files
v 2.2.4:
- Fixed null-pointer-exception after using /cb pardon-all
- Added support for multiple commands
- Added /cb save
v 2.2.3:
- Updated to MC 1.0.* / CB 1.0.1-R1
v 1.2.3:
- Added cooldown (See: "How to use the .yml files")
- Added command: /cb set literal [curse] [true/false]
- Added permission node: cb.admin.set.literal
v 1.2.2 (Final and beta release notes merged):
- Updated to RB 1337
- Rework of the curse punishment system
- Switched everything to Yaml
- Added literal matching: A * in front of the word if using ingame commands, or the "literal-match" option in the Curses.yml
- Fixed Curses not being loaded properly (If you already added curses, but they arent showing up ingame, rename "Curse Point Value.yml" to "Curses.yml"
- Custom commands possible
v1.1.2:
- Updated to RB 1317
- Hopefully fixed PEX issue
- Skipped v1.1.1, derp
v1.1.0:
v1.0.0:
Contact
Ticket here or contact me on . Email: administrator at mcnations Dot Net. Latest version in use will be on server.mcnations.net:25599 - running Tekkit.
评论 0
登录后参与评分
还没有评论,来抢沙发吧