?Soul Graves?
一款独特的墓地插件,玩家收集自己的灵魂以在死亡后取回物品。在你死亡的位置会生成一个灵魂,提供音频和视觉反馈以帮助你定位它。找到后,走进你的灵魂即可取回物品。但请注意,如果等待时间过长,灵魂将会爆裂并掉落所有物品!
特别感谢 Catnies 和 ShiroKazane 对本项目的贡献!
功能
⭐ 核心机制
- 当玩家死亡时,Soul Graves 会生成一个灵魂来存储其物品。
- 避免在液体、虚空或非固体方块中生成灵魂。
- 灵魂在服务端重启后依然保留。
- 可自定义每个玩家同时存在的灵魂数量,并支持无限选项。
- 可以限制只有灵魂的所有者才能拾取灵魂。
- 配置选项允许在所有者离线时暂停灵魂倒计时计时器。
- 可在特定世界中禁用灵魂生成。
✨ 视觉与音频反馈
- 视觉提示显示灵魂即将爆裂。
- 处于可配置半径内的玩家会听到心跳声,从而引导他们前往附近的灵魂。
- 可选且可自定义的提示粒子,直接指引玩家前往其灵魂。
- 选择播放哪些声音用于灵魂拾取、灵魂爆裂以及通知玩家。
- 当灵魂状态改变时,可以同时通知灵魂的所有者和附近的玩家。
? 物品与经验处理
- 可配置灵魂爆裂时仅掉落物品、经验值或两者兼有。
- 分别设置所有者和非所有者的经验返还百分比。
- 可选择灵魂爆裂时是销毁还是散落物品/经验值。
? 跨服务器支持
- 通过 MySQL 和 Redis 实现跨服务器支持,提供无缝体验。
? 经济支持
?️ 自定义与开发者 API
- 所有消息均完全支持 MiniMessage 格式进行自定义。
- 提供自定义 API,供开发者接入以进一步自定义 Soul Graves。
兼容性
- WorldGuard:标志位用于在特定区域禁用灵魂生成。
- Towny:支持其各种库存保留选项。
- 灵魂绑定附魔插件:
- Vane
- ExcellentEnchants
- EcoEnchants
展示
一个待拾取的稳定灵魂
一个不稳定的灵魂,它会爆裂并掉落其中的内容物
命令与权限
- /soulgraves 或 /sg:Soul Graves 的主命令。向发送者提供版本信息。
- /soulgraves reload:重新加载插件的配置文件。
- 权限:
soulgraves.command.reload
- /soulgraves back:将发送者传送至其最新的灵魂。仅限游戏内使用。
- 权限:
soulgraves.command.back
其他权限
soulgraves.spawn:如果配置中的 permission-required 为 true,则允许生成灵魂。
配置
config.yml
# DO NOT EDIT file-version DIRECTLY
file-version: 4
# If set true, players will require "soulgraves.spawn" permission to spawn a soul upon death
permission-required: false
# Time in seconds for how long a soul remains in its stable state before becoming unstable
time-stable: 240
# Time in seconds for how long a soul will show the unstable animation for before bursting
# The total time the soul is available to collect is time-stable + time-unstable
time-unstable: 60
# How much it costs to teleport to your soul, set to 0.0 to disable
teleport-cost: 0.0
# Whether to freeze the timer when the owner of the soul is offline
# This feature cannot detect the online status of players in other subservers on a proxy server
offline-owner-timer-freeze: false
# Whether to notify nearby players when a soul bursts
notify-nearby-players: true
# The radius in blocks to alert nearby players when a soul bursts
notify-radius: 128
# Whether to notify the owner of a soul when it is collected by another player
notify-owner-pickup: true
# The percentage of the soul's XP to give to the owner of the soul when it is collected by the owner
xp-percentage-owner: 0.5
# The percentage of the soul's XP to give to a player who isn't the owner when the soul is collected by that player
xp-percentage-others: 0.2
# The percentage of the soul's XP to drop when the soul bursts
xp-percentage-burst: 0.2
# Whether souls are only collectible by their owners
owner-locked: false
# The maximum number of souls a player can hold simultaneously. Set to 0 for unlimited.
# If the limit is exceeded, the oldest soul will explode
max-souls-per-player: 0
# Whether souls will drop items when they burst
souls-drop-items: true
# Whether souls will drop XP when they burst
souls-drop-xp: true
# Whether souls will store items when they are created
# If both souls-store-items and souls-store-xp are false, souls will not spawn
souls-store-items: true
# Whether souls will store XP when they are created
# If both souls-store-items and souls-store-xp are false, souls will not spawn
souls-store-xp: true
# What sounds to play when a soul is collected
# The format is 'soundEvent, volume, pitch'
# The soundKey can be found at https://minecraft.wiki/w/Sounds.json#Java_Edition_values under the 'Sound Event' column
pickup-sound:
enabled: true
sounds:
- 'minecraft:block.amethyst_block.break, 1.0, 0.5'
- 'minecraft:entity.player.levelup, 1.0, 2.0'
- 'minecraft:block.amethyst_block.resonate, 1.0, 0.5'
# 灵魂破裂时播放的音效
# 格式为 '音效事件, 音量, 音高'
# soundKey 可在 https://minecraft.wiki/w/Sounds.json#Java_Edition_values 的 'Sound Event' 列中找到
burst-sound:
enabled: true
sounds:
- 'minecraft:block.glass.break, 3.0, 1.0'
- 'minecraft:entity.vex.death, 3.0, 0.5'
- 'minecraft:entity.allay.death, 3.0, 0.5'
- 'minecraft:entity.warden.sonic_boom, 3.0, 0.5'
# 当灵魂破裂时通知附近玩家播放的音效
# 格式为 '音效事件, 音量, 音高'
# soundKey 可在 https://minecraft.wiki/w/Sounds.json#Java_Edition_values 的 'Sound Event' 列中找到
notify-nearby-sound:
enabled: true
sounds:
- 'minecraft:block.amethyst_block.resonate, 1.0, 1.0'
# 当玩家的灵魂破裂时向该玩家播放的音效
# 格式为 '音效事件, 音量, 音高'
# soundKey 可在 https://minecraft.wiki/w/Sounds.json#Java_Edition_values 的 'Sound Event' 列中找到
notify-owner-burst-sound:
enabled: true
sounds:
- 'minecraft:block.amethyst_block.break, 1.0, 0.5'
# 当玩家的灵魂被其他玩家拾取时向该玩家播放的音效
# 格式为 '音效事件, 音量, 音高'
# soundKey 可在 https://minecraft.wiki/w/Sounds.json#Java_Edition_values 的 'Sound Event' 列中找到
notify-owner-pickup-sound:
enabled: true
sounds:
- 'minecraft:block.beacon.deactivate, 1.0, 0.5'
# 禁用生成灵魂的维度世界
# 如果不需要,请留空数组
# 用法:
#disabled-worlds:
# - world_nether
# - world_the_end
disabled-worlds: []
# 控制引导玩家找到其灵魂的粒子效果
hint-particles:
enabled: true
activation-radius: 128 # 显示提示粒子的灵魂周围半径,设置为 0 以始终显示提示粒子
tracked-soul: 'OLDEST' # 如果玩家有多个灵魂,我们应该追踪哪一个?选项:OLDEST(最旧的), NEWEST(最新的)
particle-type: 'END_ROD'
start-distance: 5 # 粒子应在距离玩家多远处开始显示
mode: 'TRAIL' # 选项:TRAIL(轨迹), WANDER(游荡)
trail:
length: 8 # 指向灵魂的粒子轨迹长度
density: 2 # 每单位距离生成的粒子数量
wander:
count: 5 # 应生成的粒子数量
min-speed: 0.2 # 粒子的最小速度
max-speed: 0.6 # 粒子的最大速度
database.yml
# 请勿直接编辑 file-version
file-version: 1
# 注意:如果您更改了此配置,需要重启服务器以使更改生效。
# 选项:PDC, CROSS_SERVER
# 如果使用 CROSS_SERVER,必须同时配置 MySQL 和 Redis 部分
storage-mode: PDC
# 跨服存储时的服务器名称
# 在使用 CROSS_SERVER 存储时,确保每个服务器的名称是唯一的
# 警告:在初始化数据库后更改此值将导致数据丢失
server-name: "lobby"
# 跨服存储的数据库配置
# 如果您的数据库支持,请将 useSSL 设置为 true
MySQL:
jdbc-url: "jdbc:mysql://localhost:3306/minecraft?useSSL=false&autoReconnect=true"
jdbc-class: "com.mysql.cj.jdbc.Driver"
properties:
user: "username"
password: "password"
Redis:
uri: "redis://localhost:6379/0"
messages.yml
# 请勿直接编辑 file-version
file-version: 4
# 当玩家运行重载命令时发送给玩家的消息
soul-graves-reload: "[<dark_aqua>Soul Graves</dark_aqua>] 配置已重载!"
# 当玩家的灵魂破裂时发送给该玩家的消息
soul-burst: "<dark_aqua>☠ 你的灵魂已破裂!</dark_aqua>"
# 当玩家的灵魂破裂且 souls-drop-items 为 true 时发送给该玩家的消息
soul-burst-drop-items: "<red>☀ 其中的所有物品都已散落!</red>"
# 当玩家的灵魂破裂且 souls-drop-items 为 false 时发送给该玩家的消息
soul-burst-lose-items: "<red>✖ 其中的所有物品都已销毁!</red>"
# 当附近有灵魂破裂时发送的消息
soul-burst-nearby: "<dark_aqua>☠ 附近有灵魂破裂。</dark_aqua>"
# 当灵魂被收集时发送的消息
soul-collect: "<green>✦ 你已收集了灵魂中的物品!</green>"
# 当其他玩家收集了玩家的灵魂时发送给该玩家的消息
soul-collect-other: "<light_purple>⚑ 有人已经收集了你的灵魂!</light_purple>"
# 当生成新灵魂会超过玩家限制时发送的消息(最旧的那个会爆炸)
soul-limit-explode: "<yellow>⚠ 已达到灵魂上限 (%max%),你最旧的灵魂已破裂!</yellow>"
# 当玩家尝试返回其灵魂但没有灵魂时发送的消息
command-back-no-soul: "<yellow>✖ 你没有可传送到的灵魂。</yellow>"
# 当玩家资金不足以返回其灵魂时发送的消息
command-back-no-funds: "<red>✖ 你没有足够的资金传送回你的灵魂。</red>"
# 当玩家成功免费返回其灵魂时发送的消息
command-back-success-free: "<gold>✔ 你已传送到你的灵魂。</gold>"
# 当玩家付费成功返回其灵魂时发送的消息
command-back-success-paid: "<gold>✔ 你花费 %cost% 金币传送到你的灵魂。</gold>"
API
Maven
<repositories>
<repository>
<id>jitpack.io</id>
<url>https://jitpack.io</url>
</repository>
</repositories>
<dependency>
<groupId>com.github.FaultyFunctions</groupId>
<artifactId>SoulGraves</artifactId>
<version>TAG</version>
</dependency>
Gradle
dependencyResolutionManagement {
repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
repositories {
mavenCentral()
maven { url 'https://jitpack.io' }
}
}
dependencies {
implementation 'com.github.FaultyFunctions:SoulGraves:TAG'
}
将 TAG 替换为你在 GitHub 上选择的对应版本的发布标签。
第三方插件
路线图
致谢
?Soul Graves?
A unique graves plugin where players collect their souls to retrieve their belongings when they die. A soul will spawn at your death location that provides audio and visual feedback to help you locate it. Once you find it you can retrieve your items by walking into your soul. Be careful though, wait too long and your soul will burst dropping all your items!
Special thanks to Catnies and ShiroKazane for their contributions to the project!
Features
⭐ Core Mechanics
- Soul Graves will spawn a soul when a player dies, storing their belongings.
- Avoids spawning souls in liquids, the void, or non-solid blocks.
- Souls persist through server restarts.
- Customizable number of active souls per player, with an option for unlimited.
- Ability to restrict soul collection to their owner.
- Config options to pause the soul countdown timer while the owner is offline.
- Disable soul spawning in specific worlds.
✨ Visual & Audio Feedback
- Visual cue indicates when a soul is about to burst.
- Players in a configurable radius will hear heartbeat sounds to guide the to nearby souls.
- Optional and customizable hint particles to lead players directly to their soul.
- Choose which sounds play for soul collection, soul bursting, and notifying players.
- Both the soul’s owner and nearby players can be notified when a soul's status changes.
? Item & XP Handling
- Souls can be configured to only drop items, xp, or both when they burst.
- Set distinct XP return percentages for owners and non-owners separately.
- Option to either destroy or scatter items/xp when a soul bursts.
? Cross-Server Support
- Cross-server support with MySQL and Redis for a seamless experience.
? Economy Support
- Configurable costs for players teleporting to their soul.
?️ Customization & Developer API
- All messages are fully customizable with MiniMessage formatting.
- Custom API for developers to hook into to customize Soul Graves further.
Compatibility
- WorldGuard: Flag for disabling soul spawning in specific regions.
- Towny: Supporting their various keep-inventory options.
- Soulbound Enchantment Plugins:
- Vane
- ExcellentEnchants
- EcoEnchants
Showcase
A stable soul waiting to be collected
A unstable soul that bursts and drops its contents
Commands & Permissions
- /soulgraves or /sg: The main command for Soul Graves. Will give version information to the sender.
- Permission:
soulgraves.command
- /soulgraves reload: Reload the plugin's configuration files.
- Permission:
soulgraves.command.reload
- /soulgraves back: Teleports the sender to their latest soul. Only works in-game.
- Permission:
soulgraves.command.back
Other Permissions
soulgraves.spawn: Allows a soul to spawn if permission-required is true in the config.
Configuration
config.yml
# DO NOT EDIT file-version DIRECTLY
file-version: 4
# If set true, players will require "soulgraves.spawn" permission to spawn a soul upon death
permission-required: false
# Time in seconds for how long a soul remains in its stable state before becoming unstable
time-stable: 240
# Time in seconds for how long a soul will show the unstable animation for before bursting
# The total time the soul is available to collect is time-stable + time-unstable
time-unstable: 60
# How much it costs to teleport to your soul, set to 0.0 to disable
teleport-cost: 0.0
# Whether to freeze the timer when the owner of the soul is offline
# This feature cannot detect the online status of players in other subservers on a proxy server
offline-owner-timer-freeze: false
# Whether to notify nearby players when a soul bursts
notify-nearby-players: true
# The radius in blocks to alert nearby players when a soul bursts
notify-radius: 128
# Whether to notify the owner of a soul when it is collected by another player
notify-owner-pickup: true
# The percentage of the soul's XP to give to the owner of the soul when it is collected by the owner
xp-percentage-owner: 0.5
# The percentage of the soul's XP to give to a player who isn't the owner when the soul is collected by that player
xp-percentage-others: 0.2
# The percentage of the soul's XP to drop when the soul bursts
xp-percentage-burst: 0.2
# Whether souls are only collectible by their owners
owner-locked: false
# The maximum number of souls a player can hold simultaneously. Set to 0 for unlimited.
# If the limit is exceeded, the oldest soul will explode
max-souls-per-player: 0
# Whether souls will drop items when they burst
souls-drop-items: true
# Whether souls will drop XP when they burst
souls-drop-xp: true
# Whether souls will store items when they are created
# If both souls-store-items and souls-store-xp are false, souls will not spawn
souls-store-items: true
# Whether souls will store XP when they are created
# If both souls-store-items and souls-store-xp are false, souls will not spawn
souls-store-xp: true
# What sounds to play when a soul is collected
# The format is 'soundEvent, volume, pitch'
# The soundKey can be found at https://minecraft.wiki/w/Sounds.json#Java_Edition_values under the 'Sound Event' column
pickup-sound:
enabled: true
sounds:
- 'minecraft:block.amethyst_block.break, 1.0, 0.5'
- 'minecraft:entity.player.levelup, 1.0, 2.0'
- 'minecraft:block.amethyst_block.resonate, 1.0, 0.5'
# What sounds to play when a soul bursts
# The format is 'soundEvent, volume, pitch'
# The soundKey can be found at https://minecraft.wiki/w/Sounds.json#Java_Edition_values under the 'Sound Event' column
burst-sound:
enabled: true
sounds:
- 'minecraft:block.glass.break, 3.0, 1.0'
- 'minecraft:entity.vex.death, 3.0, 0.5'
- 'minecraft:entity.allay.death, 3.0, 0.5'
- 'minecraft:entity.warden.sonic_boom, 3.0, 0.5'
# What sounds to play to notify nearby players when a soul bursts
# The format is 'soundEvent, volume, pitch'
# The soundKey can be found at https://minecraft.wiki/w/Sounds.json#Java_Edition_values under the 'Sound Event' column
notify-nearby-sound:
enabled: true
sounds:
- 'minecraft:block.amethyst_block.resonate, 1.0, 1.0'
# What sounds to play to the owner when their soul bursts
# The format is 'soundEvent, volume, pitch'
# The soundKey can be found at https://minecraft.wiki/w/Sounds.json#Java_Edition_values under the 'Sound Event' column
notify-owner-burst-sound:
enabled: true
sounds:
- 'minecraft:block.amethyst_block.break, 1.0, 0.5'
# What sounds to play to the owner when their soul is collected by another player
# The format is 'soundEvent, volume, pitch'
# The soundKey can be found at https://minecraft.wiki/w/Sounds.json#Java_Edition_values under the 'Sound Event' column
notify-owner-pickup-sound:
enabled: true
sounds:
- 'minecraft:block.beacon.deactivate, 1.0, 0.5'
# What worlds to disable spawning a soul in
# If none, leave a blank array
# Usage:
#disabled-worlds:
# - world_nether
# - world_the_end
disabled-worlds: []
# Controls particles that will lead the player to their soul
hint-particles:
enabled: true
activation-radius: 128 # The radius around the soul to show hint particles, set to 0 to always show hint particles
tracked-soul: 'OLDEST' # Which soul should we track if the player has multiple? Options: OLDEST, NEWEST
particle-type: 'END_ROD'
start-distance: 5 # How far away from the player the particles should start
mode: 'TRAIL' # Options: TRAIL, WANDER
trail:
length: 8 # How long the particle trail towards the soul should be
density: 2 # How many particles to spawn per block distance
wander:
count: 5 # How many particles should be spawned
min-speed: 0.2 # The minimum speed of the particles
max-speed: 0.6 # The maximum speed of the particles
database.yml
# DO NOT EDIT file-version DIRECTLY
file-version: 1
# NOTE: If you change this config, you'll need to restart the server in order for the changes to take effect.
# Options: PDC, CROSS_SERVER
# If you use CROSS_SERVER, you must set configure both the MySQL and Redis sections
storage-mode: PDC
# Server name for cross-server storage
# Ensure that each server's name is unique when using CROSS_SERVER storage
# WARNING: Changing this value after initializing the database will cause data loss
server-name: "lobby"
# Database config for cross-server storage
# Set useSSL to true if your database supports it
MySQL:
jdbc-url: "jdbc:mysql://localhost:3306/minecraft?useSSL=false&autoReconnect=true"
jdbc-class: "com.mysql.cj.jdbc.Driver"
properties:
user: "username"
password: "password"
Redis:
uri: "redis://localhost:6379/0"
messages.yml
# DO NOT EDIT file-version DIRECTLY
file-version: 4
# Message to send the player when they run the reload commands
soul-graves-reload: "[<dark_aqua>Soul Graves</dark_aqua>] Config reloaded!"
# Message to send to the owner when their soul bursts
soul-burst: "<dark_aqua>☠ Your soul has burst!</dark_aqua>"
# Message to send to the owner when their soul bursts and souls-drop-items is true
soul-burst-drop-items: "<red>☀ Any belongings inside have been scattered!</red>"
# Message to send to the owner when their soul bursts and souls-drop-items is false
soul-burst-lose-items: "<red>✖ Any belongings inside have been destroyed!</red>"
# Message to send when a soul bursts nearby
soul-burst-nearby: "<dark_aqua>☠ A soul has burst nearby.</dark_aqua>"
# Message to send when a soul is collected
soul-collect: "<green>✦ You've collected the soul's contents!</green>"
# Message to send to the owner when another player has collected their soul
soul-collect-other: "<light_purple>⚑ Someone else has collected your soul!</light_purple>"
# Message to send when spawn a new soul would exceed the player's limit (oldest will explode)
soul-limit-explode: "<yellow>⚠ Reached soul limit (%max%), your oldest soul has burst!</yellow>"
# Message to send when a player tries to return to their soul but has no soul
command-back-no-soul: "<yellow>✖ You don't have a soul to teleport to.</yellow>"
# Message to send when a player doesn't have enough funds to return to their soul
command-back-no-funds: "<red>✖ You don't have enough funds to teleport to your soul.</red>"
# Message to send when a player successfully returns to their soul without a cost
command-back-success-free: "<gold>✔ You have teleported to your soul.</gold>"
# Message to send when a player successfully returns to their soul
command-back-success-paid: "<gold>✔ You have teleported to your soul for %cost% coins.</gold>"
API
Maven
<repositories>
<repository>
<id>jitpack.io</id>
<url>https://jitpack.io</url>
</repository>
</repositories>
<dependency>
<groupId>com.github.FaultyFunctions</groupId>
<artifactId>SoulGraves</artifactId>
<version>TAG</version>
</dependency>
Gradle
dependencyResolutionManagement {
repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
repositories {
mavenCentral()
maven { url 'https://jitpack.io' }
}
}
dependencies {
implementation 'com.github.FaultyFunctions:SoulGraves:TAG'
}
Replace TAG with the release tag on GitHub of your desired version.
Third-Party Addons
Roadmap
Acknowledgements
评论 0
登录后参与评分
还没有评论,来抢沙发吧