1
0
mirror of https://github.com/Zrips/Jobs.git synced 2024-11-29 14:05:25 +01:00

Customizable GUI job name section

This commit is contained in:
Zrips 2024-04-15 18:05:19 +03:00
parent 0f406c0ab4
commit 281591b93a
2 changed files with 5 additions and 3 deletions

View File

@ -212,7 +212,7 @@ public class GuiManager {
} }
}; };
button.setName(job.getDisplayName()); button.setName(Jobs.getLanguage().getMessage("command.info.help.jobName", job));
button.clearLore(); button.clearLore();
button.addLore(lore); button.addLore(lore);
if (Jobs.getGCManager().hideItemAttributes) { if (Jobs.getGCManager().hideItemAttributes) {
@ -338,8 +338,9 @@ public class GuiManager {
continue; continue;
ItemMeta meta = guiItem.getItemMeta(); ItemMeta meta = guiItem.getItemMeta();
meta.setDisplayName(job.getDisplayName()); meta.setDisplayName(Jobs.getLanguage().getMessage("command.info.help.jobName", job));
meta.setLore(lore); meta.setLore(lore);
guiItem.setItemMeta(meta); guiItem.setItemMeta(meta);
tempInv.setItem(i, guiItem.clone()); tempInv.setItem(i, guiItem.clone());
@ -358,7 +359,7 @@ public class GuiManager {
} }
ItemMeta meta = guiItem.getItemMeta(); ItemMeta meta = guiItem.getItemMeta();
meta.setDisplayName(job.getDisplayName()); meta.setDisplayName(Jobs.getLanguage().getMessage("command.info.help.jobName", job));
meta.setLore(lore); meta.setLore(lore);
guiItem.setItemMeta(meta); guiItem.setItemMeta(meta);
tempInv.setItem(i, guiItem.clone()); tempInv.setItem(i, guiItem.clone());

View File

@ -346,6 +346,7 @@ public class LanguageManager {
c.get("command.info.help.actions", "&eValid actions are: &f%actions%"); c.get("command.info.help.actions", "&eValid actions are: &f%actions%");
c.get("command.info.help.max", " - &emax level:&f "); c.get("command.info.help.max", " - &emax level:&f ");
c.get("command.info.help.newMax", " &eMax level: &f[max]"); c.get("command.info.help.newMax", " &eMax level: &f[max]");
c.get("command.info.help.jobName", "&7%jobdisplayname%");
c.get("command.info.help.material", "&7%material%"); c.get("command.info.help.material", "&7%material%");
c.get("command.info.help.levelRange", " &a(&e%levelFrom% &a- &e%levelUntil% &alevels)"); c.get("command.info.help.levelRange", " &a(&e%levelFrom% &a- &e%levelUntil% &alevels)");