所有者
该插件主要作为 API 设计,但如果您在服务器上独立使用它,它将作为一个全新的生命系统运行!
插件开发者
要使用此 API,只需将插件放入您的 Java 构建路径中即可。
API
函数
PlayerBar.getHealth(player) 返回特定玩家的生命值。
PlayerBar.getMaxHealth(player) 返回玩家的最大生命值。
PlayerBar.getMessage(player) 返回显示在玩家生命条上的消息。
PlayerBar.hasHealth(player) 返回该玩家是否拥有生命条。
PlayerBar.setHealth(player, health, livingEntity, killAble) 设置玩家的生命值。如果玩家未受到任何伤害,请将 livingEntity 设为 null;如果玩家不会因该事件死亡,请将 killAble 设为 false。
PlayerBar.updateBar(player, livingEntity, killAble) 更新玩家的生命条。如果玩家未受到任何伤害,请将 livingEnitty 设为 null;如果玩家不会因特定事件死亡,请将 killAble 设为 false。
PlayerBar.setMainDisplay(player) 在所有玩家的屏幕上显示特定玩家的生命条。
元数据 (Metadata) 您可以获取玩家的 "playerBarHealth" 元数据以获取其生命值,如果您不想直接使用插件 API 的话!
如果您更改了 EntityDamageByEntityEvent 的伤害值,所受伤害应减少玩家的生命值。
自定义事件
event.getAttacker() 返回攻击玩家实体的实体,如果没有则返回 null。
event.getHealth() 返回修改后的玩家生命值。
event.getMaxHealth() 返回玩家的最大生命值。
event.getPercentage() 返回玩家当前生命值的百分比(..%)。
event.getPlayer() 返回触发该事件的玩家。
使用 "HealthUpdateEvent" 来触发此事件!
配置文件
Increase Health After Time: true - 设置为 false 表示不希望玩家恢复生命值。
Increase If Player Has Hunger: true - 设置为 false 表示希望玩家始终恢复生命值。
Health Type: bar - 设置将使用的生命条类型(bar, normal, text)[ 请注意,如果您使用的是 v0.4 版本并更改了此项,请重启服务器! ]
Update Time: 5000 - 设置玩家获得生命值的时间间隔(毫秒)。
Health Increased After Time: 1 - 设置每次更新时恢复的生命值数量。
Message: 'You have %health% health and level %level%' - 设置基础消息(支持的标签: %name%, %level%, %health% , %maxHealth%, %expToLevel%, %food%, %flySpeed%, %speed%)。
Default Max Health: 20 - 设置默认最大生命值,将在玩家首次加入时设定。
使用 PlayerBar 的插件
如果您正在使用 PlayerBar,请通过私信告诉我您的插件名称。
实际功能说明
如果您单独使用此插件,它将把 Minecraft 旧版的生命条替换为一个新的、可配置性更强的生命条!
指标统计 (Metrics)
本插件使用了 Hidendra 的插件指标系统,这意味着以下信息将被收集并发送至 mcstats.org:
- 一个唯一的标识符。
- 服务器的 Java 版本。
- 服务器处于离线模式还是在线模式。
- 插件的版本号。
- 服务器的版本。
- 操作系统版本/名称及架构。
- CPU 的核心数量。
- 在线玩家数量。
- Metrics 的版本号。
- 您可以通过编辑 plugins/Plugin Metrics/config.yml 并将 opt-out 更改为 true 来退出此服务。
提醒
此插件会改变 Minecraft 生命值的运作方式,请务必注意这一点!

评论
Owners
This plugin is mainly designed as an API but if you use it standalone on your server it will act as a new health system!
Plugin Developers
To use the API just drop the plugin into you're java build path.
API
Functions
PlayerBar.getHealth(player) Will return the health of a specific player.
PlayerBar.getMaxHealth(player) Will return a player max health.
PlayerBar.getMessage(player) Will return the message displayed on a player's bar.
PlayerBar.hasHealth(player) Will return if the player has a bar or not.
PlayerBar.setHealth(player, health, livingEntity, killAble) Will set a player's health, if the player wasn't hit by anything set the livingEntity as null and if the player wont die from the event set the killAble as false.
PlayerBar.updateBar(player, livingEntity, killAble) Will update the bar for a player, leave the livingEnitty as null if the player wasn't hit by something and set killAble as false if the player can't die from the specific event.
PlayerBar.setMainDisplay(player) Will display the bar of a specific player on everyone's screen.
Metadata You can get a players "playerBarHealth" metadata to get his health, if you don't want to use the plugin API it'self!
If you change the damage of the EntityDamageByEntityEvent the damage taken should decrease the player health.
Custom Event
event.getAttacker() Returns the entity which attacked the player, if none will return null.
event.getHealth() Returns the player health after being changed.
event.getMaxHealth() Returns the player max health.
event.getPercentage() Returns player's ..% health.
event.getPlayer() Returns the player triggering the event.
Use "HealthUpdateEvent" to trigger the event!
Configs
Increase Health After Time: true - Set to false if you don't want players to regen hp.
Increase If Player Has Hunger: true - Set to false if you want players always to regen hp.
Health Type: bar - Sets the type of bar which will be used ( bar, normal, text ) [ Keep in mind to restart the server if you change this and you use v0.4! ]
Update Time: 5000 - Set the amount of times for the players to gain hp ( milliseconds ).
Health Increased After Time: 1 - Set the health regenerated every update.
Message: 'You have %health% health and level %level%' - Set's the message on the base ( tags supported: %name%, %level%, %health% , %maxHealth%, %expToLevel%, %food%, %flySpeed%, %speed%).
Default Max Health: 20 - Set's the default max health, which will be set when a player joins for the first time.
Plugins using PlayerBar
Send me a private message with you're plugin if you are using PlayerBar.
What this actually does
If you use this plugin all by it'self it will change the minecraft old healthbar to a new one way more configureable!
Metrics
This plugin utilises Hidendra's plugin metrics system, which means that the following information is collected and sent to mcstats.org:
- A unique identifier.
- The server's version of Java.
- Whether the server is in offline or online mode.
- The plugin's version.
- The server's version.
- The OS version/name and architecture.
- The core count for the CPU.
- The number of players online.
- The Metrics version.
- Opting out of this service can be done by editing plugins/Plugin Metrics/config.yml and changing opt-out to true.
Reminder
This plugins changes the way minecraft health works, keep that in mind!

Reviews
下载 PlayerBar
下载 PlayerBar
下载 PlayerBar
下载 PlayerBar
下载 PlayerBar
下载 PlayerBar
下载 PlayerBar
下载 PlayerBar
下载 PlayerBar
下载 PlayerBar
PlayerBar v1.2
- 完全重写了配置的工作方式。
- 提升了性能。
- 修复了一些 bug。
关于这个资源的讨论、问题反馈与使用心得
还没有讨论,来发第一帖吧
你是这个资源的作者?登录后可认领此资源。
相似资源
插件
PacketEvents 是一款专为 Minecraft Java 版打造的协议库,旨在简化数据包的处理与传输。
插件
ExyliaPlugins 的库。
插件
通过对话框或铁砧界面帮助你的 Anthme
插件
重新定义服务器上的生物运输方式。使用高度可定制的口袋道具,安全地捕获、存储和释放任何实体。
插件
为基于 Spigot/Paper/Folia 的服务器添加对 Vivecraft 的支持
插件
用于绘制游戏内地图或在浏览器中随探索实时进行地图绘制的实时地图。
评论 0
登录后参与评分
还没有评论,来抢沙发吧