Paper.java

AKL City ยท akl-city.git

Branches > main > d6131a1 > files / src / main / java / dev / grahp / aklcity / utils / Paper.java

package dev.grahp.aklcity.utils;

import org.bukkit.Bukkit;

import net.kyori.adventure.text.Component;
import net.kyori.adventure.text.format.NamedTextColor;

import java.util.Arrays;
import java.util.stream.Collectors;

public class Paper {
  public static void debug(Object... xs) {
    var text = Arrays.stream(xs)
      .map(String::valueOf)
      .collect(Collectors.joining(", "));

    Bukkit.broadcast(Component.text("Debug: ", NamedTextColor.GRAY)
                     .append(Component.text(text, NamedTextColor.GRAY)));
  }
}