diff --git a/src/com/esophose/playerparticles/command/FixedCommandModule.java b/src/com/esophose/playerparticles/command/FixedCommandModule.java index 3d78844..09df1ad 100644 --- a/src/com/esophose/playerparticles/command/FixedCommandModule.java +++ b/src/com/esophose/playerparticles/command/FixedCommandModule.java @@ -41,6 +41,7 @@ public class FixedCommandModule implements CommandModule { if (args.length == 0) { // General information on command LangManager.sendMessage(p, Lang.COMMAND_DESCRIPTION_FIXED_CREATE); + LangManager.sendMessage(p, Lang.COMMAND_DESCRIPTION_FIXED_EDIT); LangManager.sendMessage(p, Lang.COMMAND_DESCRIPTION_FIXED_REMOVE); LangManager.sendMessage(p, Lang.COMMAND_DESCRIPTION_FIXED_LIST); LangManager.sendMessage(p, Lang.COMMAND_DESCRIPTION_FIXED_INFO); @@ -59,6 +60,9 @@ public class FixedCommandModule implements CommandModule { case "create": handleCreate(pplayer, p, cmdArgs); return; + case "edit": + handleEdit(pplayer, p, cmdArgs); + return; case "remove": handleRemove(pplayer, p, cmdArgs); return; @@ -72,8 +76,9 @@ public class FixedCommandModule implements CommandModule { handleClear(pplayer, p, cmdArgs); return; default: - LangManager.sendMessage(pplayer, Lang.FIXED_INVALID_COMMAND); + LangManager.sendMessage(p, Lang.FIXED_INVALID_COMMAND); LangManager.sendMessage(p, Lang.COMMAND_DESCRIPTION_FIXED_CREATE); + LangManager.sendMessage(p, Lang.COMMAND_DESCRIPTION_FIXED_EDIT); LangManager.sendMessage(p, Lang.COMMAND_DESCRIPTION_FIXED_REMOVE); LangManager.sendMessage(p, Lang.COMMAND_DESCRIPTION_FIXED_LIST); LangManager.sendMessage(p, Lang.COMMAND_DESCRIPTION_FIXED_INFO); @@ -155,7 +160,7 @@ public class FixedCommandModule implements CommandModule { double distanceFromEffect = p.getLocation().distance(new Location(p.getWorld(), xPos, yPos, zPos)); int maxCreationDistance = PermissionManager.getMaxFixedEffectCreationDistance(); if (maxCreationDistance != 0 && distanceFromEffect > maxCreationDistance) { - LangManager.sendMessage(p, Lang.FIXED_CREATE_OUT_OF_RANGE, maxCreationDistance + ""); + LangManager.sendMessage(p, Lang.FIXED_CREATE_OUT_OF_RANGE, maxCreationDistance); return; } @@ -274,6 +279,208 @@ public class FixedCommandModule implements CommandModule { DataManager.saveFixedEffect(fixedEffect); } + /** + * Handles the command /pp fixed edit + * + * @param pplayer The PPlayer + * @param p The Player + * @param args The command arguments + */ + private void handleEdit(PPlayer pplayer, Player p, String[] args) { + if (args.length < 3) { + LangManager.sendMessage(p, Lang.FIXED_EDIT_MISSING_ARGS); + return; + } + + int id = -1; + try { + id = Integer.parseInt(args[0]); + } catch (Exception ex) { + LangManager.sendMessage(p, Lang.FIXED_EDIT_INVALID_ID); + return; + } + + FixedParticleEffect fixedEffect = pplayer.getFixedEffectById(id); + if (fixedEffect == null) { + LangManager.sendMessage(p, Lang.FIXED_EDIT_INVALID_ID); + return; + } + + String editType = args[1].toLowerCase(); + if (editType.equals("location")) { + double xPos = -1, yPos = -1, zPos = -1; + + if (args[2].equalsIgnoreCase("looking")) { + Block targetBlock = p.getTargetBlock((Set)null, 8); + int maxDistanceSqrd = 6 * 6; + if (targetBlock.getLocation().distanceSquared(p.getLocation()) > maxDistanceSqrd) { + LangManager.sendMessage(p, Lang.FIXED_EDIT_LOOKING_TOO_FAR); + return; + } + + Location blockLocation = targetBlock.getLocation().clone().add(0.5, 0.5, 0.5); // Center of block + + xPos = blockLocation.getX(); + yPos = blockLocation.getY(); + zPos = blockLocation.getZ(); + } else { + try { + if (args[2].startsWith("~")) { + if (args[2].equals("~")) xPos = p.getLocation().getX(); + else xPos = p.getLocation().getX() + Double.parseDouble(args[2].substring(1)); + } else { + xPos = Double.parseDouble(args[2]); + } + + if (args[3].startsWith("~")) { + if (args[3].equals("~")) yPos = p.getLocation().getY() + 1; + else yPos = p.getLocation().getY() + 1 + Double.parseDouble(args[3].substring(1)); + } else { + yPos = Double.parseDouble(args[3]); + } + + if (args[4].startsWith("~")) { + if (args[4].equals("~")) zPos = p.getLocation().getZ(); + else zPos = p.getLocation().getZ() + Double.parseDouble(args[4].substring(1)); + } else { + zPos = Double.parseDouble(args[4]); + } + } catch (Exception e) { + LangManager.sendMessage(p, Lang.FIXED_EDIT_INVALID_COORDS); + return; + } + } + + double distanceFromEffect = p.getLocation().distance(new Location(p.getWorld(), xPos, yPos, zPos)); + int maxCreationDistance = PermissionManager.getMaxFixedEffectCreationDistance(); + if (maxCreationDistance != 0 && distanceFromEffect > maxCreationDistance) { + LangManager.sendMessage(p, Lang.FIXED_EDIT_OUT_OF_RANGE, maxCreationDistance); + return; + } + + fixedEffect.setCoordinates(xPos, yPos, zPos); + } else if (editType.equals("effect")) { + ParticleEffect effect = ParticleEffect.fromName(args[2]); + if (effect == null) { + LangManager.sendMessage(pplayer, Lang.FIXED_EDIT_EFFECT_INVALID, args[2]); + return; + } else if (!PermissionManager.hasEffectPermission(pplayer.getPlayer(), effect)) { + LangManager.sendMessage(pplayer, Lang.FIXED_EDIT_EFFECT_NO_PERMISSION, effect.getName()); + return; + } + + fixedEffect.getParticlePair().setEffect(effect); + } else if (editType.equals("style")) { + ParticleStyle style = ParticleStyle.fromName(args[2]); + if (style == null) { + LangManager.sendMessage(pplayer, Lang.FIXED_EDIT_STYLE_INVALID, args[2]); + return; + } else if (!PermissionManager.hasStylePermission(pplayer.getPlayer(), style)) { + LangManager.sendMessage(pplayer, Lang.FIXED_EDIT_STYLE_NO_PERMISSION, style.getName()); + return; + } + + fixedEffect.getParticlePair().setStyle(style); + } else if (editType.equals("data")) { + Material itemData = null; + Material blockData = null; + OrdinaryColor colorData = null; + NoteColor noteColorData = null; + + ParticleEffect effect = fixedEffect.getParticlePair().getEffect(); + if (effect.hasProperty(ParticleProperty.COLORABLE)) { + if (effect == ParticleEffect.NOTE) { + if (args[2].equalsIgnoreCase("rainbow")) { + noteColorData = new NoteColor(99); + } else if (args[2].equalsIgnoreCase("random")) { + noteColorData = new NoteColor(98); + } else { + int note = -1; + try { + note = Integer.parseInt(args[2]); + } catch (Exception e) { + LangManager.sendMessage(p, Lang.FIXED_EDIT_DATA_ERROR); + return; + } + + if (note < 0 || note > 24) { + LangManager.sendMessage(p, Lang.FIXED_EDIT_DATA_ERROR); + return; + } + + noteColorData = new NoteColor(note); + } + } else { + if (args[2].equalsIgnoreCase("rainbow")) { + colorData = new OrdinaryColor(999, 999, 999); + } else if (args[2].equalsIgnoreCase("random")) { + colorData = new OrdinaryColor(998, 998, 998); + } else { + int r = -1; + int g = -1; + int b = -1; + + try { + r = Integer.parseInt(args[2]); + g = Integer.parseInt(args[3]); + b = Integer.parseInt(args[4]); + } catch (Exception e) { + LangManager.sendMessage(p, Lang.FIXED_EDIT_DATA_ERROR); + return; + } + + if (r < 0 || r > 255 || g < 0 || g > 255 || b < 0 || b > 255) { + LangManager.sendMessage(p, Lang.FIXED_EDIT_DATA_ERROR); + return; + } + + colorData = new OrdinaryColor(r, g, b); + } + } + } else if (effect.hasProperty(ParticleProperty.REQUIRES_MATERIAL_DATA)) { + if (effect == ParticleEffect.BLOCK || effect == ParticleEffect.FALLING_DUST) { + Material material = null; + try { + material = ParticleUtils.closestMatch(args[2]); + if (material == null) material = Material.matchMaterial(args[2]); + if (material == null || !material.isBlock()) throw new Exception(); + } catch (Exception e) { + LangManager.sendMessage(p, Lang.FIXED_EDIT_DATA_ERROR); + return; + } + + blockData = material; + } else if (effect == ParticleEffect.ITEM) { + Material material = null; + try { + material = ParticleUtils.closestMatch(args[2]); + if (material == null) material = Material.matchMaterial(args[2]); + if (material == null || material.isBlock()) throw new Exception(); + } catch (Exception e) { + LangManager.sendMessage(p, Lang.FIXED_EDIT_DATA_ERROR); + return; + } + + itemData = material; + } + } else { + LangManager.sendMessage(pplayer, Lang.FIXED_EDIT_DATA_NONE); + return; + } + + fixedEffect.getParticlePair().setColor(colorData); + fixedEffect.getParticlePair().setNoteColor(noteColorData); + fixedEffect.getParticlePair().setItemMaterial(itemData); + fixedEffect.getParticlePair().setBlockMaterial(blockData); + } else { + LangManager.sendMessage(p, Lang.FIXED_EDIT_INVALID_PROPERTY); + return; + } + + DataManager.updateFixedEffect(fixedEffect); + LangManager.sendMessage(pplayer, Lang.FIXED_EDIT_SUCCESS, editType, id); + } + /** * Handles the command /pp fixed remove * @@ -297,9 +504,9 @@ public class FixedCommandModule implements CommandModule { if (pplayer.getFixedEffectById(id) != null) { DataManager.removeFixedEffect(pplayer.getUniqueId(), id); - LangManager.sendMessage(p, Lang.FIXED_REMOVE_SUCCESS, id + ""); + LangManager.sendMessage(p, Lang.FIXED_REMOVE_SUCCESS, id); } else { - LangManager.sendMessage(p, Lang.FIXED_REMOVE_INVALID, id + ""); + LangManager.sendMessage(p, Lang.FIXED_REMOVE_INVALID, id); } } @@ -353,7 +560,7 @@ public class FixedCommandModule implements CommandModule { FixedParticleEffect fixedEffect = pplayer.getFixedEffectById(id); if (fixedEffect == null) { - LangManager.sendMessage(p, Lang.FIXED_INFO_INVALID, id + ""); + LangManager.sendMessage(p, Lang.FIXED_INFO_INVALID, id); return; } @@ -362,11 +569,11 @@ public class FixedCommandModule implements CommandModule { DecimalFormat df = new DecimalFormat("0.##"); // Decimal formatter so the coords aren't super long LangManager.sendMessage(p, // @formatter:off Lang.FIXED_INFO_SUCCESS, - fixedEffect.getId() + "", + fixedEffect.getId(), fixedEffect.getLocation().getWorld().getName(), - df.format(fixedEffect.getLocation().getX()) + "", - df.format(fixedEffect.getLocation().getY()) + "", - df.format(fixedEffect.getLocation().getZ()) + "", + df.format(fixedEffect.getLocation().getX()), + df.format(fixedEffect.getLocation().getY()), + df.format(fixedEffect.getLocation().getZ()), particle.getEffect().getName(), particle.getStyle().getName(), particle.getDataString() @@ -409,13 +616,13 @@ public class FixedCommandModule implements CommandModule { for (FixedParticleEffect fixedEffect : fixedEffectsToRemove) DataManager.removeFixedEffect(fixedEffect.getOwnerUniqueId(), fixedEffect.getId()); - LangManager.sendMessage(p, Lang.FIXED_CLEAR_SUCCESS, fixedEffectsToRemove.size() + "", radius + ""); + LangManager.sendMessage(p, Lang.FIXED_CLEAR_SUCCESS, fixedEffectsToRemove.size(), radius); } public List onTabComplete(PPlayer pplayer, String[] args) { Player p = pplayer.getPlayer(); List matches = new ArrayList(); - String[] subCommands = new String[] { "create", "remove", "list", "info", "clear" }; + String[] subCommands = new String[] { "create", "edit", "remove", "list", "info", "clear" }; if (args.length <= 1) { List possibleCmds = new ArrayList(Arrays.asList(subCommands)); @@ -487,6 +694,73 @@ public class FixedCommandModule implements CommandModule { } } break; + case "edit": + if (args.length == 2) { + StringUtil.copyPartialMatches(args[1], pplayer.getFixedEffectIds().stream().map((x) -> String.valueOf(x)).collect(Collectors.toList()), matches); + } else if (args.length == 3) { + String[] validProperties = new String[] { "location", "effect", "style", "data" }; + StringUtil.copyPartialMatches(args[2], Arrays.asList(validProperties), matches); + } else if (args.length > 3) { + String property = args[2].toLowerCase(); + if (property.equals("location")) { + List possibleValues = new ArrayList(); + if (args.length == 6 && !args[3].equalsIgnoreCase("looking")) { + possibleValues.add("~"); + } + if (args.length == 5 && !args[3].equalsIgnoreCase("looking")) { + possibleValues.add("~ ~"); + } + if (args.length == 4) { + possibleValues.add("~ ~ ~"); + possibleValues.add("looking"); + } + StringUtil.copyPartialMatches(args[args.length - 1], possibleValues, matches); + } else if (property.equals("effect") && args.length == 4) { + StringUtil.copyPartialMatches(args[3], PermissionManager.getEffectNamesUserHasPermissionFor(p), matches); + } else if (property.equals("style") && args.length == 4) { + StringUtil.copyPartialMatches(args[3], PermissionManager.getStyleNamesUserHasPermissionFor(p), matches); + } else if (property.equals("data")) { + int id = -1; + try { + id = Integer.parseInt(args[1]); + } catch (Exception e) { } + + FixedParticleEffect fixedEffect = pplayer.getFixedEffectById(id); + if (fixedEffect != null) { + ParticleEffect effect = fixedEffect.getParticlePair().getEffect(); + if (effect.hasProperty(ParticleProperty.COLORABLE)) { + List possibleValues = new ArrayList(); + if (effect == ParticleEffect.NOTE) { // Note data + if (args.length == 4) { + possibleValues.add("<0-24>"); + possibleValues.add("rainbow"); + possibleValues.add("random"); + } + } else { // Color data + if (args.length == 6 && !args[3].equalsIgnoreCase("rainbow") && !args[3].equalsIgnoreCase("random")) { + possibleValues.add("<0-255>"); + } + if (args.length == 5 && !args[3].equalsIgnoreCase("rainbow") && !args[3].equalsIgnoreCase("random")) { + possibleValues.add("<0-255> <0-255>"); + } + if (args.length == 4) { + possibleValues.add("<0-255> <0-255> <0-255>"); + possibleValues.add("rainbow"); + possibleValues.add("random"); + } + } + StringUtil.copyPartialMatches(args[args.length - 1], possibleValues, matches); + } else if (args.length == 4 && effect.hasProperty(ParticleProperty.REQUIRES_MATERIAL_DATA)) { + if (effect == ParticleEffect.BLOCK || effect == ParticleEffect.FALLING_DUST) { // Block material + matches = StringUtil.copyPartialMatches(args[3], ParticleUtils.getAllBlockMaterials(), matches); + } else if (effect == ParticleEffect.ITEM) { // Item material + matches = StringUtil.copyPartialMatches(args[3], ParticleUtils.getAllItemMaterials(), matches); + } + } + } + } + } + break; case "remove": StringUtil.copyPartialMatches(args[1], pplayer.getFixedEffectIds().stream().map((x) -> String.valueOf(x)).collect(Collectors.toList()), matches); break; diff --git a/src/com/esophose/playerparticles/gui/GuiInventory.java b/src/com/esophose/playerparticles/gui/GuiInventory.java index c03223d..d7b7626 100644 --- a/src/com/esophose/playerparticles/gui/GuiInventory.java +++ b/src/com/esophose/playerparticles/gui/GuiInventory.java @@ -36,7 +36,7 @@ public abstract class GuiInventory { if (this.material != null) { // Use 1.13 materials borderIcon = new ItemStack(this.material, 1); } else { // Use < 1.13 data values - borderIcon = new ItemStack(Material.GLASS_PANE, 1, this.data); + borderIcon = new ItemStack(ParticleUtils.closestMatch("THIN_GLASS"), 1, this.data); } ItemMeta meta = borderIcon.getItemMeta(); diff --git a/src/com/esophose/playerparticles/manager/DataManager.java b/src/com/esophose/playerparticles/manager/DataManager.java index d8d7dd7..b098099 100644 --- a/src/com/esophose/playerparticles/manager/DataManager.java +++ b/src/com/esophose/playerparticles/manager/DataManager.java @@ -345,6 +345,52 @@ public class DataManager { pplayer.addFixedEffect(fixedEffect); }); } + + /** + * Updates a fixed effect's particle values + * + * @param fixedEffect The fixed effect to update + */ + public static void updateFixedEffect(FixedParticleEffect fixedEffect) { + async(() -> { + PlayerParticles.getDBConnector().connect((connection) -> { + // Update fixed effect + String fixedEffectQuery = "UPDATE pp_fixed SET xPos = ?, yPos = ?, zPos = ? WHERE owner_uuid = ? AND id = ?"; + try (PreparedStatement statement = connection.prepareStatement(fixedEffectQuery)) { + statement.setDouble(1, fixedEffect.getLocation().getX()); + statement.setDouble(2, fixedEffect.getLocation().getY()); + statement.setDouble(3, fixedEffect.getLocation().getZ()); + statement.setString(4, fixedEffect.getOwnerUniqueId().toString()); + statement.setInt(5, fixedEffect.getId()); + statement.executeUpdate(); + } + + // Update particle + String particleUpdateQuery = "UPDATE pp_particle " + + "SET effect = ?, style = ?, item_material = ?, block_material = ?, note = ?, r = ?, g = ?, b = ? " + + "WHERE uuid = (SELECT particle_uuid FROM pp_fixed WHERE owner_uuid = ? AND id = ?)"; + try (PreparedStatement statement = connection.prepareStatement(particleUpdateQuery)) { + ParticlePair particle = fixedEffect.getParticlePair(); + statement.setString(1, particle.getEffect().getName()); + statement.setString(2, particle.getStyle().getName()); + statement.setString(3, particle.getItemMaterial().name()); + statement.setString(4, particle.getBlockMaterial().name()); + statement.setInt(5, particle.getNoteColor().getNote()); + statement.setInt(6, particle.getColor().getRed()); + statement.setInt(7, particle.getColor().getGreen()); + statement.setInt(8, particle.getColor().getBlue()); + statement.setString(9, fixedEffect.getOwnerUniqueId().toString()); + statement.setInt(10, fixedEffect.getId()); + statement.executeUpdate(); + } + }); + }); + + getPPlayer(fixedEffect.getOwnerUniqueId(), (pplayer) -> { + pplayer.removeFixedEffect(fixedEffect.getId()); + pplayer.addFixedEffect(fixedEffect); + }); + } /** * Deletes a fixed effect from save data diff --git a/src/com/esophose/playerparticles/manager/LangManager.java b/src/com/esophose/playerparticles/manager/LangManager.java index 84ed8af..aded2a3 100644 --- a/src/com/esophose/playerparticles/manager/LangManager.java +++ b/src/com/esophose/playerparticles/manager/LangManager.java @@ -49,6 +49,7 @@ public class LangManager { // Sub-Command Usage COMMAND_DESCRIPTION_FIXED_CREATE, + COMMAND_DESCRIPTION_FIXED_EDIT, COMMAND_DESCRIPTION_FIXED_REMOVE, COMMAND_DESCRIPTION_FIXED_LIST, COMMAND_DESCRIPTION_FIXED_INFO, @@ -159,20 +160,40 @@ public class LangManager { FIXED_CREATE_STYLE_NON_FIXABLE, FIXED_CREATE_DATA_ERROR, FIXED_CREATE_SUCCESS, + + FIXED_EDIT_MISSING_ARGS, + FIXED_EDIT_INVALID_ID, + FIXED_EDIT_INVALID_PROPERTY, + FIXED_EDIT_INVALID_COORDS, + FIXED_EDIT_OUT_OF_RANGE, + FIXED_EDIT_LOOKING_TOO_FAR, + FIXED_EDIT_EFFECT_INVALID, + FIXED_EDIT_EFFECT_NO_PERMISSION, + FIXED_EDIT_STYLE_INVALID, + FIXED_EDIT_STYLE_NO_PERMISSION, + FIXED_EDIT_STYLE_NON_FIXABLE, + FIXED_EDIT_DATA_ERROR, + FIXED_EDIT_DATA_NONE, + FIXED_EDIT_SUCCESS, + FIXED_REMOVE_INVALID, FIXED_REMOVE_NO_ARGS, FIXED_REMOVE_ARGS_INVALID, FIXED_REMOVE_SUCCESS, + FIXED_LIST_NONE, FIXED_LIST_SUCCESS, + FIXED_INFO_INVALID, FIXED_INFO_NO_ARGS, FIXED_INFO_INVALID_ARGS, FIXED_INFO_SUCCESS, + FIXED_CLEAR_NO_PERMISSION, FIXED_CLEAR_NO_ARGS, FIXED_CLEAR_INVALID_ARGS, FIXED_CLEAR_SUCCESS, + FIXED_NO_PERMISSION, FIXED_MAX_REACHED, FIXED_INVALID_COMMAND, diff --git a/src/com/esophose/playerparticles/particles/FixedParticleEffect.java b/src/com/esophose/playerparticles/particles/FixedParticleEffect.java index 8fe722f..faef3a3 100644 --- a/src/com/esophose/playerparticles/particles/FixedParticleEffect.java +++ b/src/com/esophose/playerparticles/particles/FixedParticleEffect.java @@ -88,5 +88,18 @@ public class FixedParticleEffect { public Location getLocation() { return this.location.clone(); } + + /** + * Updates the coordinates of the FixedParticleEffect + * + * @param x The new X coordinate + * @param y The new Y coordinate + * @param z The new Z coordinate + */ + public void setCoordinates(double x, double y, double z) { + this.location.setX(x); + this.location.setY(y); + this.location.setZ(z); + } } diff --git a/src/com/esophose/playerparticles/particles/ParticleEffect.java b/src/com/esophose/playerparticles/particles/ParticleEffect.java index 0b67577..5082478 100644 --- a/src/com/esophose/playerparticles/particles/ParticleEffect.java +++ b/src/com/esophose/playerparticles/particles/ParticleEffect.java @@ -539,7 +539,7 @@ public enum ParticleEffect { */ @Override public float getValueX() { - return (float) note / 24F; + return (float) this.note / 24F; } /** diff --git a/src/com/esophose/playerparticles/particles/ParticlePair.java b/src/com/esophose/playerparticles/particles/ParticlePair.java index a1067b5..37963f2 100644 --- a/src/com/esophose/playerparticles/particles/ParticlePair.java +++ b/src/com/esophose/playerparticles/particles/ParticlePair.java @@ -196,9 +196,9 @@ public class ParticlePair { public ParticleColor getSpawnColor() { if (this.effect.hasProperty(ParticleProperty.COLORABLE)) { if (this.effect == ParticleEffect.NOTE) { - if (this.noteColor.getValueX() * 24 == 99) { + if (this.noteColor.getNote() == 99) { return ParticleManager.getRainbowNoteParticleColor(); - } else if (this.noteColor.getValueX() * 24 == 98) { + } else if (this.noteColor.getNote() == 98) { return ParticleManager.getRandomNoteParticleColor(); } return this.noteColor; @@ -243,12 +243,12 @@ public class ParticlePair { return this.itemMaterial.toString().toLowerCase(); } else if (this.effect.hasProperty(ParticleProperty.COLORABLE)) { if (this.effect == ParticleEffect.NOTE) { - if (this.noteColor.getValueX() * 24 == 99) { + if (this.noteColor.getNote() == 99) { return LangManager.getText(Lang.RAINBOW); - } else if ((int)(this.noteColor.getValueX() * 24) == 98) { + } else if (this.noteColor.getNote() == 98) { return LangManager.getText(Lang.RANDOM); } - return LangManager.getText(Lang.GUI_SELECT_DATA_NOTE, (int) (this.noteColor.getValueX() * 24)); + return LangManager.getText(Lang.GUI_SELECT_DATA_NOTE, this.noteColor.getNote()); } else { if (this.color.getRed() == 999 && this.color.getGreen() == 999 && this.color.getBlue() == 999) { return LangManager.getText(Lang.RAINBOW); diff --git a/src/com/esophose/playerparticles/styles/ParticleStyleInvocation.java b/src/com/esophose/playerparticles/styles/ParticleStyleInvocation.java index 9d83e71..2dfb5c1 100644 --- a/src/com/esophose/playerparticles/styles/ParticleStyleInvocation.java +++ b/src/com/esophose/playerparticles/styles/ParticleStyleInvocation.java @@ -12,7 +12,7 @@ import com.esophose.playerparticles.styles.api.ParticleStyle; public class ParticleStyleInvocation implements ParticleStyle { - private int points = 5; + private int points = 6; private double radius = 3.5; private double step = 0; private int circleStep = 0; diff --git a/src/lang/default.lang b/src/lang/default.lang index cbc8016..b3946f7 100644 --- a/src/lang/default.lang +++ b/src/lang/default.lang @@ -35,6 +35,7 @@ command-description-worlds: 'Find out what worlds particles are disabled in' # Sub-Command Usage command-description-fixed-create: '&e/pp fixed create < |>