sunchl

a 1.21.11 paper plugin

make it so with this plugin, i can change globally how much damage arrows that a player has shot do. /arrowdamagemultiplier and then a multiplier that would go like 0.5 or 1 or 1.5 or anything in between if you understand it

this base damage of arrows doesnt disappear when enchantments are added and is added on top of the base multiplied damage, no issues

Kodari AI
KodariJun 27 at 1:11 pm 1
ArrowDamageMultiplier
A Paper plugin that adds a global arrow damage multiplier command. Server admins can use /arrowdamagemultiplier to set any decimal multiplier (e.g. 0.5, 1.5, 2.0) which scales all arrow damage dealt by players. The multiplier applies on top of base arrow damage and enchantments work normally. The multiplier persists across restarts via config.yml.

I’ll create a complete Paper 1.21 plugin with command, listener, config persistence, and tab completion.

Kodari can make mistakes. Review important code before using.
Files
src
build.gradle
settings.gradle
Code
7 177
src/main/java/com/arrowdamage/ArrowDamageMultiplier.java
package com.arrowdamage;

import org.bukkit.plugin.java.JavaPlugin;

public class ArrowDamageMultiplier extends JavaPlugin {

    private static ArrowDamageMultiplier instance;
    private double multiplier;

    @Override
    public void onEnable() {
        instance = this;
        saveDefaultConfig();
        loadMultiplier();

        getCommand("arrowdamagemultiplier").setExecutor(new ArrowDamageCommand(this));
        getCommand("arrowdamagemultiplier").setTabCompleter(new ArrowDamageCommand(this));
        getServer().getPluginManager().registerEvents(new ArrowDamageListener(this), this);

        getLogger().info("ArrowDamageMultiplier enabled. Current multiplier: " + multiplier);
    }

    @Override
    public void onDisable() {
        getLogger().info("ArrowDamageMultiplier disabled.");
    }

    public void loadMultiplier() {
        multiplier = getConfig().getDouble("arrow-damage-multiplier", 1.0);
    }

    public double getMultiplier() {
        return multiplier;
    }

    public void setMultiplier(double multiplier) {
        this.multiplier = multiplier;
        getConfig().set("arrow-damage-multiplier", multiplier);
        saveConfig();
    }

    public static ArrowDamageMultiplier getInstance() {
        return instance;
    }
}