1.2.0
Fixed: - Plugin incorrectly reporting update available if installed version was newer than github version. Added: - Arm pose position menu. Each Arm can now be individually posed using the menu. - Radius View Button. This button initiates a red sprite outline of the scan and slaughter radius that stays for 30 seconds. - Show/Hide Name button. This button hides/shows the RS MobStand name above the MobStand.
This commit is contained in:
1 parent
e702c96cad
commit
ffd84d2bfa
9 files changed
+1312
-80
No files matched your search
@@ -34,7 +34,7 @@ public class StandMenu {
|
||||
new RSMenuHolder(
|
||||
"MAIN"
|
||||
),
|
||||
27,
|
||||
36,
|
||||
MENU_TITLE
|
||||
);
|
||||
|
||||
@@ -185,6 +185,44 @@ public class StandMenu {
|
||||
|
||||
inventory.setItem(6, pauseItem);
|
||||
|
||||
// View Radius item
|
||||
ItemStack viewRadiusItem =
|
||||
new ItemStack(
|
||||
Material.ENDER_EYE
|
||||
);
|
||||
|
||||
ItemMeta viewRadiusMeta =
|
||||
viewRadiusItem.getItemMeta();
|
||||
|
||||
if (viewRadiusMeta != null) {
|
||||
|
||||
viewRadiusMeta.setDisplayName(
|
||||
ChatColor.GREEN
|
||||
+ "View Radius"
|
||||
);
|
||||
|
||||
viewRadiusMeta.setLore(List.of(
|
||||
ChatColor.GRAY
|
||||
+ "Display the current scan area.",
|
||||
ChatColor.GRAY
|
||||
+ "Shows horizontal radius",
|
||||
ChatColor.GRAY
|
||||
+ "and vertical scan height.",
|
||||
"",
|
||||
ChatColor.YELLOW
|
||||
+ "Click to view."
|
||||
));
|
||||
|
||||
viewRadiusItem.setItemMeta(
|
||||
viewRadiusMeta
|
||||
);
|
||||
}
|
||||
|
||||
inventory.setItem(
|
||||
31,
|
||||
viewRadiusItem
|
||||
);
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -238,6 +276,47 @@ public class StandMenu {
|
||||
|
||||
inventory.setItem(17, babyFilters);
|
||||
|
||||
// Display Name item
|
||||
ItemStack displayNameItem =
|
||||
new ItemStack(Material.NAME_TAG);
|
||||
|
||||
ItemMeta displayNameMeta =
|
||||
displayNameItem.getItemMeta();
|
||||
|
||||
if (displayNameMeta != null) {
|
||||
|
||||
boolean visible =
|
||||
armorStand.isCustomNameVisible();
|
||||
|
||||
displayNameMeta.setDisplayName(
|
||||
(visible
|
||||
? ChatColor.GREEN
|
||||
: ChatColor.RED)
|
||||
+ "Display Name"
|
||||
);
|
||||
|
||||
displayNameMeta.setLore(List.of(
|
||||
ChatColor.GRAY + "Show or hide the",
|
||||
ChatColor.GRAY + "RS MobStand name.",
|
||||
"",
|
||||
ChatColor.GRAY + "Current: "
|
||||
+ (visible
|
||||
? ChatColor.GREEN + "Visible"
|
||||
: ChatColor.RED + "Hidden"),
|
||||
"",
|
||||
ChatColor.YELLOW + "Click to toggle."
|
||||
));
|
||||
|
||||
displayNameItem.setItemMeta(
|
||||
displayNameMeta
|
||||
);
|
||||
}
|
||||
|
||||
inventory.setItem(
|
||||
20,
|
||||
displayNameItem
|
||||
);
|
||||
|
||||
|
||||
// Leave Alive item
|
||||
int leaveAlive =
|
||||
@@ -355,7 +434,7 @@ public class StandMenu {
|
||||
|
||||
inventory.setItem(11, gravityItem);
|
||||
|
||||
// Arms toggle
|
||||
// Arm Poses
|
||||
ItemStack armsItem =
|
||||
new ItemStack(
|
||||
Material.IRON_SWORD
|
||||
@@ -367,21 +446,28 @@ public class StandMenu {
|
||||
if (armsMeta != null) {
|
||||
|
||||
armsMeta.setDisplayName(
|
||||
(arms
|
||||
? ChatColor.GREEN
|
||||
: ChatColor.RED)
|
||||
+ "Arms"
|
||||
arms
|
||||
? ChatColor.GREEN + "Arm Poses"
|
||||
: ChatColor.RED + "Arm Poses"
|
||||
);
|
||||
|
||||
armsMeta.setLore(List.of(
|
||||
ChatColor.GRAY + "Current: "
|
||||
ChatColor.GRAY + "Configure the Main Hand",
|
||||
ChatColor.GRAY + "and Off Hand arm poses.",
|
||||
"",
|
||||
ChatColor.GRAY + "Arms: "
|
||||
+ (arms
|
||||
? ChatColor.GREEN + "Enabled"
|
||||
: ChatColor.RED + "Disabled"),
|
||||
"",
|
||||
ChatColor.YELLOW + "Click to toggle."
|
||||
ChatColor.YELLOW
|
||||
+ "Click to configure."
|
||||
));
|
||||
|
||||
armsMeta.addItemFlags(
|
||||
ItemFlag.HIDE_ATTRIBUTES
|
||||
);
|
||||
|
||||
if (arms) {
|
||||
|
||||
armsMeta.addEnchant(
|
||||
@@ -391,17 +477,19 @@ public class StandMenu {
|
||||
);
|
||||
|
||||
armsMeta.addItemFlags(
|
||||
ItemFlag.HIDE_ENCHANTS,
|
||||
ItemFlag.HIDE_ATTRIBUTES
|
||||
ItemFlag.HIDE_ENCHANTS
|
||||
);
|
||||
|
||||
}
|
||||
|
||||
armsItem.setItemMeta(armsMeta);
|
||||
|
||||
armsItem.setItemMeta(
|
||||
armsMeta
|
||||
);
|
||||
}
|
||||
|
||||
inventory.setItem(22, armsItem);
|
||||
inventory.setItem(
|
||||
22,
|
||||
armsItem
|
||||
);
|
||||
|
||||
player.openInventory(inventory);
|
||||
|
||||
|
||||
Reference in new issue
Block a user