8.17.1 release

This commit is contained in:
BuildTools 2020-07-22 12:50:23 +02:00
parent 27f3521c20
commit 3b81ffaad1
4 changed files with 46 additions and 3 deletions

View File

@ -1,5 +1,10 @@
# Changelog
## 8.17.1
- Improved sorting of colored blocks
- White, light gray, gray and black comes first
- Remaining colors are sorted in a rainbow like order
## 8.17.0
- Added option to disable automatic sorting and/or automatic inventory sorting. Hotkeys will still work if enabled. When running /chestsort while automatic sorting is disabled, it will display the hotkeys gui instead.

View File

@ -9,7 +9,7 @@
<name>ChestSort</name>
<url>https://www.chestsort.de</url>
<description>Automatically sorts your chests!</description>
<version>8.17.0</version>
<version>8.17.1</version>
<packaging>jar</packaging>
<properties>

View File

@ -105,6 +105,44 @@ public class ChestSortOrganizer {
}
static String getColorOrdered(String c) {
switch(c) {
case "white":
return "01_white";
case "light_gray":
return "02_light_gray";
case "gray":
return "03_gray";
case "black":
return "04_black";
case "brown":
return "05_brown";
case "red":
return "06_red";
case "orange":
return "07_orange";
case "yellow":
return "08_yellow";
case "lime":
return "09_lime";
case "green":
return "10_green";
case "cyan":
return "11_cyan";
case "light_blue":
return "12_light_blue";
case "blue":
return "13_blue";
case "magenta":
return "14_magenta";
case "purple":
return "15_purple";
case "pink":
return "16_pink";
}
return "";
}
static int getNumberOfEnchantments(ItemStack is) {
int totalEnchants = 0;
@ -214,7 +252,7 @@ public class ChestSortOrganizer {
for (String color : colors) {
if (typeName.startsWith(color)) {
typeName = typeName.replaceFirst(color + "_", "");
myColor = color;
myColor = getColorOrdered(color);
}
}
// Same for wood, but the wood name can also be in the middle of the item name,

View File

@ -1,6 +1,6 @@
main: de.jeff_media.ChestSort.ChestSortPlugin
name: ChestSort
version: 8.17.0
version: 8.17.1
api-version: "1.13"
description: Allows automatic chest sorting
author: mfnalex