Color (@NotNull Color color, int tones) { final float[] hsb = Color.RGBtoHSB(color.getRed(), color.getGreen(), color.getBlue(), null); float saturation = hsb[1]; for (int i = 0; i < tones; i++) { saturation = Math.max(0, saturation / 1.1F); if (saturation == 0) break; } return Color.getHSBColor(hsb[0], saturation, hsb[2]); }