HoloMobHealth 显示生物血量 伤害指示器 客户端 JavaScript 格式化 | |
---|---|
![]() |
显示暴徒健康客户端只有通过包!支持定制的JavaScript格式! |
作 者 | LOOHP |
发布时间 | 2020年3月12日 |
支持核心 | Spigot | 原生版本 |
支持版本 | 1.8,1.9,1.10,1.11,1.12,1.13,1.14,1.15,1.16,1.17,1.18,1.19,1.20 |
插件详细介绍
HoloMobHealth 是一款 Minecraft 插件,用于在生物头顶显示其剩余生命值。该插件高度可定制,允许你自定义生命值显示的方式,例如使用数字、百分比或爱心符号。它完全是客户端的,这意味着它不会影响服务器上的生物数据,也不会导致死亡消息中出现乱码。
🎉
&x&F&F&F&F&F&F
或
[color=#ffffff]
如果有一个具有不同字体的自定义资源包,你甚至可以像颜色代码一样使用它们!
[font=myawesomefont]
/holomobhealth reload
(或 /hmh reload
) - 重载插件/holomobhealth update
(或 /hmh update
) - 检查更新/holomobhealth toggle
(或 /hmh toggle
) - 切换自己的生物生命值显示
permissions:
holomobhealth.reload:
description: 允许您重新加载插件
default: op
holomobhealth.use:
description: 允许您查看生命值显示
default: true
holomobhealth.toggle:
description: 允许您切换自己的生命值显示
default: true
holomobhealth.toggle.others:
description: 允许您切换其他人的生命值显示
default: op
holomobhealth.update:
description: 允许您接收更新通知
default: op
最新配置带有说明。
# +-------------------------------------------------------------------------------------------------------------------+
# | ____ _ _ _____ _ _ |
# | / ___| _ __ __| | ___ _ __ ___ | |_ _ __ ___ | ____|_ __ | | ___ __ _ | | ___ |
# | \___ \| '_ \ / _` |/ _ \| '_ \ / _ \| __| | '__/ _ \| _| | '_ \| |/ _ \ / _` | | |/ _ \ |
# | ___) | |_) | (_| | (_) | | | | (_) | |_ | | | (_) | |___| | | | | (_) | (_| | | | __/ |
# | |____/| .__/ \__,_|\___/|_| |_|\___/ \__| |_| \___/|_____|_| |_|_|\___/ \__,_| |_|\___| |
# | |_| |
# +-------------------------------------------------------------------------------------------------------------------+
#
# Documentation can be found here: https://github.com/LOOHP/HoloMobHealth/wiki/Configuration
#
# Color Codes: https://minecraft.fandom.com/wiki/Formatting_codes
# RGB Colors: &x&R&R&G&G&B&B or [color=#RRGGBB]
# Font: [font=fontname]
#
# Placeholders that you can use in messages:
# {health} - Mob's current health
# {maxHealth} - Mob's maximum health
# {percent} - Mob's health percentage
# {name} - Mob's name (if it has one)
# {distance} - Distance from the mob in blocks
# {entityType} - Mob's type (e.g. Zombie, Cow, etc.)
# {entityTypeName} - Mob's translated type name (e.g. Zombie, Cow, etc.)
# {formattedName} - Mob's formatted name (Name or Type if it doesn't have a name)
# {formattedHealth} - Mob's formatted health (Health / Max Health)
# {scaledHealth} - Mob's health scaled to a value
# {scaledMaxHealth} - Mob's maximum health scaled to a value
# {scaledSymbols} - Mob's health as a number of symbols (e.g. Hearts)
# {strippedName} - Mob's name without formatting
# {strippedType} - Mob's type without formatting
# {strippedFormattedName} - Mob's formatted name without formatting
# {healthbar} - A health bar that displays the health
# {damage} - The damage dealt to the mob (Damage Indicators)
# {custom} - Custom placeholder from PlaceholderAPI
# {script:scriptname} - Custom placeholder script (See Placeholder Scripts)
# {newLine} - New line
# {space} - Space
# {empty} - Empty String
# {playerHead} - Player's head (Only works for players, needs to be enabled in the config)
#
# Placeholders that you can use in Damage Indicator messages:
# {damage} - The damage dealt to the mob
# {health} - Mob's current health
# {maxHealth} - Mob's maximum health
# {name} - Mob's name (if it has one)
# {entityType} - Mob's type (e.g. Zombie, Cow, etc.)
#
# Placeholders that you can use in Damage Indicator display names:
# {damage} - The damage dealt to the mob
# {health} - Mob's current health
# {maxHealth} - Mob's maximum health
# {name} - Mob's name (if it has one)
# {entityType} - Mob's type (e.g. Zombie, Cow, etc.)
#
# Placeholders that you can use in Conditions
# health - Mob's current health
# maxHealth - Mob's maximum health
# percent - Mob's health percentage
# name - Mob's name (if it has one)
# distance - Distance from the mob in blocks
# entityType - Mob's type (e.g. Zombie, Cow, etc.)
# world - World name
# isBaby - Is the mob a baby
# hasPassenger - Does the mob have a passenger
# isLeashed - Is the mob leashed
# isInvisible - Is the mob invisible
# hasPotionEffect - Does the mob have a potion effect
# isGlowing - Is the mob glowing
# custom - Custom placeholder from PlaceholderAPI
# script - Custom placeholder script (See Placeholder Scripts)
settings:
# Whether to display the health of mobs
enable: true
# Display health only when the mob is attacked
dynamic-display: false
# Disable health display for mobs in spectator mode
spectator-mode-check: true
# Show the health of invisible mobs
show-invisible: false
# Update rate in ticks
update-rate: 2
# Max distance to display health (0 = infinite)
max-distance: 64
# Whether to align the health display with the mob's head (Requires ModelEngine Support)
align-with-head: false
# Height offset of the health display
height-offset: 2.2
# Multiplier for the height offset based on the mob's height
height-multiplier: 0.2
# Whether to display player heads instead of names (Only works for players)
player-head: false
# Show health of players
player-health: true
# Show health of named mobs only (Overrides named-mobs-only)
named-mobs:
only: false
# Show health alongside named mobs instead of overriding it
display-alongside: false
# Show health for mobs with a custom name tag from resource pack only (Overrides named-mobs-only)
resource-pack-mobs: false
# Show health of boss mobs
boss-mobs: true
# Show health of mobs from these plugins
plugin-mobs:
my-pet: true
citizens: false
mythic-mobs: false
shopkeeper: true
# Display health based on condition
conditions:
enable: false
condition: "health < maxHealth"
# When condition is false
hide-when-false: false
# World whitelist / blacklist
world:
enable: false
whitelist: false
worlds:
- "world_nether"
- "world_the_end"
# Prevent health display in certain WorldGuard regions
worldguard:
enable: false
# Flag to check for
flag: "holomobhealth-hide"
# Hide health in certain light level
light-level:
enable: false
max-level: 7
# Blacklist certain mobs
blacklist:
mob-types:
- "ARMOR_STAND"
mob-names:
- "Dinnerbone"
- "Grumm"
name-contains:
- "Example"
- "&cExample"
# Custom Model Data
custom-model-data:
enable: false
# Mobs with these custom model data will have their health hidden
blacklist:
- 1234
- 5678
# Mobs with these custom model data will have the display replaced
replace:
12345: "&cExample"
# ModelEngine
modelengine:
enable: false
# Height offset of the health display
height-offset: 0.0
# Always update health display
always-update: false
# Health Bar
health-bar:
enable: true
# The symbol used to represent a full health point
symbol: "&a%rounded_rectangle%"
# The symbol used to represent an empty health point
empty-symbol: "&c%rounded_rectangle%"
# The length of the health bar
length: 20
# The color of the health bar
color: "&a"
# The color of the empty health bar
empty-color: "&c"
# Scale the health to the length of the bar
scale-health: true
# Damage Indicators
damage-indicators:
enable: true
# Show damage indicators only when the mob is attacked
dynamic-display: false
# Update rate in ticks
update-rate: 5
# Max distance to display damage indicators (0 = infinite)
max-distance: 16
# The offset of the damage indicator relative to the mob's head
offset: 0.7
# Whether to display damage indicators in the direction of the player
look-at-player: true
# The speed at which the damage indicator moves
velocity: 0.1
# The gravity of the damage indicator
gravity: 0.05
# Damage indicator display name settings
display-name:
# Whether to enable display names for damage indicators
enable: true
# The display name format for damage indicators
format: "&c-{damage}"
# Whether to enable custom model data for damage indicators
custom-model-data:
enable: true
# The custom model data to use for damage indicators
data: 12345
# Formatting settings for damage indicators
formatting:
# The minimum size of the damage indicator
min-size: 8
# The maximum size of the damage indicator
max-size: 16
# Whether to enable fade-in effect for damage indicators
fade-in: true
# The duration of the fade-in effect in ticks
fade-in-duration: 5
# Whether to enable fade-out effect for damage indicators
fade-out: true
# The duration of the fade-out effect in ticks
fade-out-duration: 20
# +-------------------------------------------------------------------------------------------------------------------+
# | Message Settings |
# +-------------------------------------------------------------------------------------------------------------------+
messages:
# Main message
main: "&c{formattedHealth} &7(&f{health}&7/&f{maxHealth}&7)"
# Update message
update:
available: "&aThere is a new version of HoloMobHealth available! (v{version})"
no-update: "&cYou are using the latest version of HoloMobHealth!"
# Toggle message
toggle:
enabled: "&aHoloMobHealth has been enabled!"
disabled: "&cHoloMobHealth has been disabled!"
# Reload message
reload: "&aHoloMobHealth has been reloaded!"
reload-failed: "&cHoloMobHealth failed to reload! Check console for errors!"
# Damage indicator message
damage-indicator: "&c{damage}"
# +-------------------------------------------------------------------------------------------------------------------+
# | Placeholder Scripts |
# +-------------------------------------------------------------------------------------------------------------------+
# You can create your own placeholders through the use of JavaScript
#
# To use a script, use the placeholder {script:scriptname} in the messages
# Example: {script:example}
# You can also use PlaceholderAPI placeholders in the scripts
#
# Available variables:
# - player: The player who is seeing the health display
# - entity: The entity who's health is being displayed
# - health: The entity's current health
# - maxHealth: The entity's maximum health
# - name: The entity's name
# - entityType: The entity's type
#
# Available functions:
# - PlaceholderAPI.setPlaceholders(Player player, String text): Replaces PlaceholderAPI placeholders in the text
# - PlaceholderAPI.containsPlaceholders(String text): Checks if the text contains PlaceholderAPI placeholders
#
# Example:
# example: |
# var name = entity.getName();
# if (name == null || name.isEmpty()) {
# name = entityType;
# }
# '&a' + name + ' is at ' + health + '/' + maxHealth + ' health!';
scripts:
example: |
var name = entity.getName();
if (name == null || name.isEmpty()) {
name = entityType;
}
'&a' + name + ' is at ' + health + '/' + maxHealth + ' health!';
# +-------------------------------------------------------------------------------------------------------------------+
# | Advanced Settings |
# +-------------------------------------------------------------------------------------------------------------------+
advanced:
# Whether to use the advanced NMS system to get the entity's name (Requires ProtocolLib)
use-advanced-name-system: true
# Whether to use the advanced NMS system to set the entity's name (Requires ProtocolLib)
use-advanced-set-name-system: true
# Whether to debug the plugin
debug: false
# Whether to enable metrics
metrics: true
# Whether to check for updates
update-check: true
# Which system to use to get the entity's type name
entity-type-name-system: "LEGACY"
# Which system to use to create the hologram
hologram-system: "NATIVE"
# Which system to use to get the entity's custom name
custom-name-system: "LEGACY"
# Which system to use to get the entity's custom name
custom-model-data-system: "LEGACY"
# Whether to use the optimized check for entities
optimized-entity-check: true
# Custom damage indicators
custom-damage-indicators:
enable: false
# The item to use for the damage indicator
item: "STONE"
# The amount of damage indicators to spawn
amount: 1
# The spread of the damage indicators
spread: 0.5