qwertyydev

Plugin Name: PlayerHologram

Create a professional Minecraft plugin named "PlayerHologram" for Paper 1.21 using Java.

The plugin must contain no comment lines in the source code.

Core Functionality:

  1. Every player must have a hologram above their head.
  1. Hologram must contain exactly two lines.

Line 1: Text configurable from config.yml (default: "Minecraft").

Line 2: Text configurable from config.yml (default: "Oyuncu").

  1. Do NOT add unnecessary placeholders, statistics systems, or extra features.
  1. Configuration System:

- All hologram texts must be fully editable from config.yml. - Hologram size must be adjustable. - Shadow rendering must be enabled for hologram text. - Billboard rotation angle must be configurable.

  1. Performance Optimization:

- Avoid PlayerMoveEvent spam calculations. - Use scheduler-based periodic updates instead of tick-based loops. - Do not perform heavy computations.

  1. Entity Rendering:

- Use modern Paper 1.21 entity-based hologram system. - Prefer Display entities or optimized ArmorStand holograms.

  1. Player Events:

- Spawn hologram when player joins. - Remove hologram when player quits. - Update hologram when config is reloaded.

  1. Startup Behavior:

- Automatically create holograms for all online players when plugin enables.

  1. Plugin Architecture:

Implement: - Main plugin class - Config manager - Hologram manager - Event listeners - Scheduler optimization system

  1. Output Requirements:

- Plugin must be compiled into a runnable JAR file. - Source code must be production-quality. - Code must be clean, optimized, and multiplayer server friendly. - Language of source code must be English.

Generate full working plugin source code.

Kodari AI
KodariMar 3 at 9:39 am 20,473 (v2)

I’ll create a professional PlayerHologram plugin for Paper 1.21 using modern TextDisplay entities with optimized performance.

PlayerHologram
A lightweight player hologram system for Paper 1.21+ that displays customizable two-line holograms above every player's head. Uses modern TextDisplay entities for optimal performance with scheduler-based position updates instead of event-driven calculations. Features configurable text, size, shadow rendering, and billboard modes. Automatically manages holograms on player join/quit and world changes with full configuration reload support.

Now I’ll create the complete plugin structure:

Complete PlayerHologram plugin created with modern Paper 1.21 TextDisplay entities, scheduler-based position updates, full configuration support, and optimized performance.

qwertyydev

Modify the existing PlayerHologram plugin code without rewriting the entire project.

Required Changes:

  1. Ensure file headers and package declarations are correct.
  1. Align all file names, class names, and project structure with Qwerty Dev branding.
  1. Fix any incorrect or inconsistent file header formatting.
  1. Update code style if necessary but do not add new unnecessary systems.
  1. The plugin must still follow original functionality:

- Two-line hologram above players. - Line 1 and Line 2 texts must be configurable from config.yml. - No extra placeholder or statistic systems. - Performance optimized scheduler-based updates. - Paper 1.21 compatibility.

  1. Do not introduce new features.
  1. Keep the plugin lightweight and production quality.
  1. Only modify code where necessary.

Output the corrected and optimized version of the plugin code.

Kodari AI
KodariMar 3 at 9:48 am 13,643 (v2)

I’ll analyze the existing PlayerHologram plugin and make necessary corrections for branding, structure, and code quality.

Analysis

The plugin has major package declaration inconsistencies:

  • Main class uses package dev.qwerty.PlayerHologram; instead of package dev.qwerty;

  • All subclasses use old com.playerhologram package instead of dev.qwerty

  • All imports reference wrong package names

  • plugin.yml author field needs standardized branding

All package declarations and imports have been corrected to use dev.qwerty namespace, and plugin.yml author field standardized to “Qwerty Dev” branding. The plugin maintains its lightweight, production-quality design with configurable two-line holograms above players.

qwertyydev

Modify the PlayerHologram plugin implementation.

Change hologram rendering system to a pseudo-nameplate system that looks like a real Minecraft nametag floating above the player's head.

Technical Requirements:

  1. Do not use simple static hologram entities only.
  1. Implement a name-tag-like display system that behaves visually similar to vanilla player nametag rendering.
  1. The text must appear directly above the player head as if it is an authentic Minecraft player name tag.
  1. Background visibility must be configurable via config.yml.

- Allow background box behind text to be enabled or disabled.

  1. If background is enabled:

- Render shadowed text with background.

  1. If background is disabled:

- Render clean floating text without any box.

  1. Plugin Configuration Options:

- Line 1 text (default: "Minecraft") - Line 2 text (default: "Oyuncu") - Text size scaling - Billboard rotation angle - Background toggle

  1. Use optimized Paper 1.21 compatible rendering.
  1. Avoid heavy tick-based calculations.
  1. Use scheduler-based update logic.
  1. Do not add new gameplay mechanics.
  1. Keep plugin lightweight and performance friendly.
  1. Maintain Qwerty Dev project structure.
  1. Output only the updated optimized plugin code.
  1. Do not rewrite the entire plugin unless necessary.

Implement the improved name-tag style hologram system.

Kodari AI
KodariMar 3 at 10:03 am 12,712 (v2)

I’ll analyze the current plugin structure and implement an optimized name-tag style hologram system.

Now I’ll implement an optimized name-tag style hologram system with configurable background rendering.

Analysis

  • Current implementation uses basic TextDisplay entities

  • Need to add background visibility control similar to vanilla nametags

  • Optimize rendering with Paper 1.21 TextDisplay API features

  • Add background color configuration for authentic nametag appearance

Implemented optimized name-tag style hologram system with configurable background rendering, VERTICAL billboard for authentic nametag rotation, brightness control for visibility, and validation checks for performance.

qwertyydev

Use position anchoring system.

Attach hologram entity as a child transform reference of player entity.

Update hologram position using server-side transform matrix sync.

Avoid per-tick full entity recreation.

Use cached entity handle update instead of destroy/spawn cycle.

Kodari AI
KodariMar 3 at 10:11 am 16,480 (v2)

I’ll analyze the current implementation and refactor it to use an efficient position anchoring system with cached entity handles.

I’ll refactor the system to use position anchoring with cached entity handles and transform-based updates, eliminating unnecessary entity recreation.

Refactored hologram system with position anchoring, cached entity handles, and transform-based updates to eliminate per-tick entity recreation.

Kodari can make mistakes. Review important code before using.
Files
src
build.gradle
Code
10 460
src/main/java/dev/qwerty/PlayerHologram.java
package dev.qwerty;

import dev.qwerty.command.ReloadCommand;
import dev.qwerty.listener.PlayerListener;
import dev.qwerty.manager.ConfigManager;
import dev.qwerty.manager.HologramManager;
import dev.qwerty.task.HologramUpdateTask;
import lombok.Getter;
import org.bukkit.Bukkit;
import org.bukkit.entity.Player;
import org.bukkit.plugin.java.JavaPlugin;

@Getter
public class PlayerHologram extends JavaPlugin {
    private ConfigManager configManager;
    private HologramManager hologramManager;
    private HologramUpdateTask updateTask;
    
    @Override
    public void onEnable() {
        this.configManager = new ConfigManager(this);
        this.configManager.load();
        
        this.hologramManager = new HologramManager(this);
        
        Bukkit.getPluginManager().registerEvents(new PlayerListener(this), this);
        
        this.getCommand("hologramreload").setExecutor(new ReloadCommand(this));
        
        this.updateTask = new HologramUpdateTask(this);
        this.updateTask.runTaskTimer(this, 0L, this.configManager.getUpdateInterval());
        
        for (Player player : Bukkit.getOnlinePlayers()) {
            this.hologramManager.createHologram(player);
        }
    }
    
    @Override
    public void onDisable() {
        if (this.updateTask != null) {
            this.updateTask.cancel();
        }
        
        if (this.hologramManager != null) {
            this.hologramManager.removeAllHolograms();
        }
    }
    
    public void reload() {
        this.configManager.reload();
        this.hologramManager.updateAllHolograms();
        
        if (this.updateTask != null) {
            this.updateTask.cancel();
        }
        this.updateTask = new HologramUpdateTask(this);
        this.updateTask.runTaskTimer(this, 0L, this.configManager.getUpdateInterval());
    }
}