如果你的服务器存在玩家使用透视(X-Raying)的问题,但又不想使用反透视插件,那么这可能正是你需要的。
此插件会根据你的 config.yml 配置,在玩家挖掘特定方块超过阈值时,向 Discord 发送包含该玩家信息的通知。通知中将显示坐标、世界和方块类型,并支持通过配置 imgur.com 的图片 ID 来添加图片。虽然插件还有进一步完善的空间,但目前主要功能已能正常运行。
权限
- orenotifier.alerts - 接收警报所需的权限。
- orenotifier.reload - 允许重新加载配置。
- orenotifier.toggle - 允许切换警报开关。
命令
- /orenotifier reload - 重新加载配置。
- /orenotifier toggle - 开启/关闭警报。
工作原理?
通过追踪可配置的矿石开采量,我们可以记录这些数据,以便当玩家超过设定的阈值时,向 Discord 发送通知。你可以为每种方块单独自定义触发警报的阈值,以及 Webhook 消息和游戏内消息的颜色。当玩家挖掘足够数量的常见方块(石头、深板岩、凝灰岩)或不常见方块(下界岩、玄武岩)时,阈值将会重置。这样,使用透视的玩家将根据其开采的矿石与常见/不常见方块的比例来触发警报。
CustomOres:
diamond_ore: # 定义我们要追踪的矿石名称。
msg-color: "&b" # 设置聊天中警报显示的矿石名称颜色。
thumbnail: xXkIhRR # 嵌入消息右侧的图片,通过 imgur 获取。
threshold: 9 # 触发警报所需的方块数量。
webhook-color: # 嵌入消息的颜色。
r: 150
g: 255
b: 255
致谢:
感谢 RandomWebUser 帮助我进行 X 光... 我是说测试本插件。
*Discord: @Plexiate
邮箱: hi@plexiate.com
配置
# 我们是一个拥有永久地图的小型白名单原版 SMP 服务器,地图生成于 2021 年 1 月 28 日。
# 你可以在 https://crafters.one/Discord 加入我们,或者在这里查看我们的插件 https://www.spigotmc.org/resources/authors/plexiate.117947/
# Webhook 设置
prefix: "&8[&bOreNotifier&8]"
webhook: webhook_url
webhook-enabled: true
# 这是你需要在两次矿石开采之间挖掘的石头、深板岩、凝灰岩和下界岩的数量
# 用于重置警报等级。请根据你的喜好进行调整 :)
reset-threshold: 95 # 石头、深板岩和凝灰岩的总和
nether-threshold: 250 # 下界岩和玄武岩的总和
# 用于通知的矿石列表 / 其他方块
CustomOres:
diamond_ore:
msg-color: "&b"
thumbnail: xXkIhRR
threshold: 9
webhook-color:
r: 150
g: 255
b: 255
deepslate_diamond_ore:
msg-color: "&b"
thumbnail: ihJgnuM
threshold: 9
webhook-color:
r: 0
g: 102
b: 102
ancient_debris:
msg-color: "&5"
thumbnail: DNvvUsr
threshold: 3
webhook-color:
r: 85
g: 35
b: 0
gold_ore:
msg-color: "&e"
thumbnail: JTrQfFY
threshold: 15
webhook-color:
r: 255
g: 255
b: 0
# 不要动这些。这里是它们的家。
stone:
threshold: 0
deepslate:
threshold: 0
tuff:
threshold: 0
netherrack:
threshold: 0
basalt:
threshold: 0
# 消息 - ( 占位符包括 {PREFIX}, {USERNAME}, {BLOCK}, {AMOUNT} 和 {COORDS} )
messages:
server-chat-message: "{PREFIX} &a{USERNAME} &7-> {BLOCK}&7."
reload-message: "{PREFIX} &c此时我们建议执行 /reload 命令。 ."
no-permission: "&f未知命令。输入 ''/help'' 获取帮助。"
webhook-settings:
title: "{PLUGIN} | {USERNAME}"
description: "**{USERNAME}** -> **{BLOCK}**"
footer: "插件版本: {VERSION}"
# 缩略图 URL 通过 imgur (https://imgur.com) 的图片 ID 工作
# Kasprr 表示从长远来看这可能不是个好主意,如果遇到任何问题,请发送邮件给我
# 发送至 plexiate@crafters.one
# 这里有一些我已经上传的其他方块供你欣赏。
emerald_ore-thumbnail: "4USvGhH"
deepslate_emerald_ore-thumbnail: "uwCGbpB"
gold_ore-thumbnail: "JTrQfFY"
deepslate_gold_ore-thumbnail: "DnTMYwe"
nether_gold_ore-thumbnail: "iIH6NUk"
iron_ore-thumbnail: "6I7zQyC"
deepslate_iron_ore-thumbnail: "07QlXdh"
copper_ore-thumbnail: "LCm0dHJ"
deepslate_copper_ore-thumbnail: "ATym2ul"
redstone_ore-thumbnail: "D8nIgQa"
deepslate_redstone_ore-thumbnail: "IKuPFmR"
netherite_block-thumbnail: "JRZvsSr"
diamond_block-thumbnail: "CR8rJf0"
emerald_block-thumbnail: "sBwrnxH"
gold_block-thumbnail: "NhxxIQ9"
iron_block-thumbnail: "IbhLcoL"
# 这是我的个人设置。
debug: false
If you have a problem with X-Raying players on your server, but don't want to use an Anti-Xray plugin then this might be what you're looking for.
This plugin will send a notification, dependent on your config.yml settings, to discord showing information on players when they break a threshold of a certain block. The coords, world and block type are displayed as well as room for an image, configured by imgur.com codes, configurable in the config. There is a bit more to do to fully shine the plugin up, but it's mostly working fine.
Permissions
- orenotifier.alerts - Permission required to receive alerts.
- orenotifier.reload - Allows reloading the configuration.
- orenotifier.toggle - Allows toggling alerts.
Commands
- /orenotifier reload - Reloads the configuration.
- /orenotifier toggle - toggles alerts on/off.
How it works?
By tracking the amount of ores being mined, configurable via the config, we can store these so that when the player exceeds the threshold it sends a notification to discord. You can customize the threshold to your liking for each block individually, as can you the color of the webhook message and in game messages. The threshold gets reset when the player mines enough common (stone, deepslate, tuff) or uncommon ores (netherrack, basalt). This way players who are X-Raying will send alerts based on the amount of ores to common/uncommon blocks as per a ratio.
CustomOres:
diamond_ore: # Defines the name of the ore we should track.
msg-color: "&b" # Sets the color of the ores name in chat for alerts.
thumbnail: xXkIhRR # The image on the right of the embed. via imgur.
threshold: 9 # How many blocks are needed to set off the alert.
webhook-color: # The color for embedded messages.
r: 150
g: 255
b: 255
Credits:
Thank you RandomWebUser for helping me X-r... I mean test the plugin.
*Discord: @Plexiate
Email: hi@plexiate.com
Config
# We're a small whitelisted vanilla SMP with a permanent map, generated on jan 28th, 2021.
# You can join us at https://crafters.one/Discord or see our plugins here https://www.spigotmc.org/resources/authors/plexiate.117947/
# Webhook settings
prefix: "&8[&bOreNotifier&8]"
webhook: webhook_url
webhook-enabled: true
# This is how many Stone, Deepslate, Tuff,and netherrack you would need to mine
# in-between ores to reset the alert level. Adjust them as you'd like :)
reset-threshold: 95 # Stone, Deepslate and Tuff combined
nether-threshold: 250 # Netherrack and Basalt combined
# List of ores for notifications / other blocks
CustomOres:
diamond_ore:
msg-color: "&b"
thumbnail: xXkIhRR
threshold: 9
webhook-color:
r: 150
g: 255
b: 255
deepslate_diamond_ore:
msg-color: "&b"
thumbnail: ihJgnuM
threshold: 9
webhook-color:
r: 0
g: 102
b: 102
ancient_debris:
msg-color: "&5"
thumbnail: DNvvUsr
threshold: 3
webhook-color:
r: 85
g: 35
b: 0
gold_ore:
msg-color: "&e"
thumbnail: JTrQfFY
threshold: 15
webhook-color:
r: 255
g: 255
b: 0
# Don't touch these. This is their home.
stone:
threshold: 0
deepslate:
threshold: 0
tuff:
threshold: 0
netherrack:
threshold: 0
basalt:
threshold: 0
# Messages - ( Placeholders include {PREFIX}, {USERNAME}, {BLOCK}, {AMOUNT} and {COORDS} )
messages:
server-chat-message: "{PREFIX} &a{USERNAME} &7-> {BLOCK}&7."
reload-message: "{PREFIX} &cWe suggest doing /reload instead at this time. ."
no-permission: "&fUnknown command. Type ''/help'' for help."
webhook-settings:
title: "{PLUGIN} | {USERNAME}"
description: "**{USERNAME}** -> **{BLOCK}**"
footer: "Plugin version: {VERSION}"
# Thumbnail URLs work through imgur (https://imgur.com) image IDs
# Kasprr says this might be a bad idea for the long term, and if any issues are encountered please email me
# at plexiate@crafters.one
# Here are some other blocks I already uploaded for your pleasure.
emerald_ore-thumbnail: "4USvGhH"
deepslate_emerald_ore-thumbnail: "uwCGbpB"
gold_ore-thumbnail: "JTrQfFY"
deepslate_gold_ore-thumbnail: "DnTMYwe"
nether_gold_ore-thumbnail: "iIH6NUk"
iron_ore-thumbnail: "6I7zQyC"
deepslate_iron_ore-thumbnail: "07QlXdh"
copper_ore-thumbnail: "LCm0dHJ"
deepslate_copper_ore-thumbnail: "ATym2ul"
redstone_ore-thumbnail: "D8nIgQa"
deepslate_redstone_ore-thumbnail: "IKuPFmR"
netherite_block-thumbnail: "JRZvsSr"
diamond_block-thumbnail: "CR8rJf0"
emerald_block-thumbnail: "sBwrnxH"
gold_block-thumbnail: "NhxxIQ9"
iron_block-thumbnail: "IbhLcoL"
# this is my personal setting.
debug: false
评论 0
登录后参与评分
还没有评论,来抢沙发吧