Ноу Нейм

Develop a Minecraft plugin that displays holographic damage notifications upon player hits, showcasing the damage dealt and the opponent's remaining health in yellow. The hologram should be configurable to include custom text for critical hits and blocked strikes, disappear after 2 seconds or with the next hit, and only appear if the hit is successful (ignoring players in Creative or with god mode). Additionally, implement a combo counter for consecutive hits and highlight damage exceeding 5.0 in red, while replacing the health display with "Murder" in red when a player achieves a kill.

Kodari AI
KodariOct 8 at 2:21 pm 1
DamageHologramCombo
A Minecraft plugin that displays holographic damage notifications above hit targets. Shows damage dealt and remaining health in yellow, with red highlighting for damage over 5.0. Features configurable critical hit and blocked strike messages, auto-disappears after 2 seconds or next hit, ignores Creative/god mode players, tracks consecutive hit combos, and displays "Murder" in red on kills. Uses MiniMessage for color formatting and supports custom text configuration.
  1. Set up the Paper plugin and default message configuration.

  2. Add player-hit handling for damage, health, critical/blocked text, kills, and combos.

  3. Manage each attacker’s hologram so it expires after 2 seconds or is replaced by their next hit.

Created the Paper plugin with temporary damage holograms, critical and partially blocked hit messages, combo tracking, red highlighting for damage over 5.0, and a red “Murder” label on kills. Holograms disappear after 2 seconds or on the attacker’s next player hit; cancelled, zero-damage, Creative, and invulnerable hits are ignored. Tune the messages and combo reset time in config.yml.

Ноу Нейм

Also make it so that the plugin displays damage dealt to mobs and the ability to add more lines to the hologram in the config. And create a command that reloads the config.

Kodari AI
KodariOct 8 at 2:24 pm 1
  1. Extend damage holograms to include mob hits while preserving player-specific logic.

  2. Add configurable extra hologram lines with placeholders.

  3. Add and register a config-reload command.

  1. Damage holograms now appear for successful hits on mobs as well as players, with damage, remaining health, and combo placeholders.

  2. Added configurable extra hologram lines in config.yml; lines support %damage%, %health%, %combo%, %target%, %damage_color%, and %health_color%.

  3. Added /damagenotifications reload for operators to reload the config.

Kodari can make mistakes. Review important code before using.
Files
src
build.gradle
Code
5 286
src/main/java/com/kodari/damagenotifications/DamageNotificationsPlugin.java
package com.kodari.damagenotifications;

import org.bukkit.Bukkit;
import org.bukkit.ChatColor;
import org.bukkit.plugin.java.JavaPlugin;

public final class DamageNotificationsPlugin extends JavaPlugin {
    private DamageNotificationListener damageNotificationListener;

    @Override
    public void onEnable() {
        saveDefaultConfig();
        damageNotificationListener = new DamageNotificationListener(this);
        Bukkit.getPluginManager().registerEvents(damageNotificationListener, this);
        getCommand("damagenotifications").setExecutor((sender, command, label, args) -> {
            if (args.length != 1 || !args[0].equalsIgnoreCase("reload")) {
                sender.sendMessage(ChatColor.RED + "Usage: /damagenotifications reload");
                return true;
            }
            reloadConfig();
            sender.sendMessage(ChatColor.GREEN + "DamageNotifications config reloaded.");
            return true;
        });
    }

    @Override
    public void onDisable() {
        if (damageNotificationListener != null) {
            damageNotificationListener.clearAllHolograms();
        }
    }
}