▶️ ЗАБЕРИ СВОИ 8 ПОДАРКОВ 🎁 ПРИ СОЗДАНИИ СВОЕГО МАЙНКРАФТ СЕРВЕРА
Моды/Health Regeneration Overhaul
Health Regeneration Overhaul

Health Regeneration Overhaul

This API changes health regeneration to be attribute-driven and (optionally) disables the hunger/saturation system.

7.3K
13

Health Regeneration Overhaul

This API changes the way health is regenerated. Instead of depending on the hunger system, entity attributes are used.

The vanilla hunger system including exhaustion and saturation is disabled by default.

Additionally, an entity attribute called healthregenerationoverhaul:reserved_health is added and a vanilla bug that clamps player health to a maximum of 20 when respawning/joining a world has been fixed.

Default implementation

Health is regenerated by healthregenerationoverhaul:health_regeneration every healthregenerationoverhaul:health_tick_threshold ticks.

When health is reduced, regeneration is stopped for healthregenerationoverhaul:health_regeneration_delay_threshold ticks.

healthregenerationoverhaul:reserved_health describes the percentage amount of maximum health that is currently not available.

Default attribute values

  • healthregenerationoverhaul:health_regeneration: 0
  • healthregenerationoverhaul:health_tick_threshold: 100
  • healthregenerationoverhaul:health_regeneration_delay_threshold: 100
  • healthregenerationoverhaul:reserved_health: 0

Customization

When the vanilla game rule "natural_health_regeneration" is true, players have 1 additional health regeneration.

In the client config an alternative health bar can be enabled and customised.

The server config has options to set the default value for each attribute (including max_health). This only affects the attribute values for players, not other entities.

Also in the server config, the vanilla food system can be re-enabled.

API

Casting a "LivingEntity" to the "HealthRegeneratingEntity" interface gives access to all relevant methods.

Совместимость

Minecraft: Java Edition

26.1.x1.21.x1.20.x

Платформы

Поддерживаемые окружения

Клиент и сервер

Создатели

Детали

Лицензия:MIT
Опубликован:1 год назад
Обновлён:16 часов назад
Главная