forked from zhdev/griefus
Add MaterialUtils#asTranslatable to convert Material to the MiniMessage key
This commit is contained in:
parent
fcf4d43010
commit
ab0a01b12f
1 changed files with 6 additions and 0 deletions
|
|
@ -3,6 +3,7 @@ package net.coreprotect.utility;
|
||||||
import java.util.Locale;
|
import java.util.Locale;
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
|
|
||||||
|
import org.bukkit.Bukkit;
|
||||||
import org.bukkit.Material;
|
import org.bukkit.Material;
|
||||||
|
|
||||||
import net.coreprotect.config.ConfigHandler;
|
import net.coreprotect.config.ConfigHandler;
|
||||||
|
|
@ -213,4 +214,9 @@ public class MaterialUtils extends Queue {
|
||||||
return isInventory ? 2 : 1;
|
return isInventory ? 2 : 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Griefus
|
||||||
|
public static String asTranslatable(Material material) {
|
||||||
|
return "<lang:" + material.translationKey() + ">";
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue