mirror of
https://github.com/TotalFreedomMC/PlayerParticles.git
synced 2025-07-09 23:37:58 +00:00
/pp add | /pp help finished and working
This commit is contained in:
parent
4532455ccc
commit
15a1d9c74e
19 changed files with 210 additions and 79 deletions
|
@ -1,14 +1,18 @@
|
||||||
package com.esophose.playerparticles.command;
|
package com.esophose.playerparticles.command;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.Arrays;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import org.bukkit.Material;
|
import org.bukkit.Material;
|
||||||
|
import org.bukkit.entity.Player;
|
||||||
|
import org.bukkit.util.StringUtil;
|
||||||
|
|
||||||
import com.esophose.playerparticles.manager.DataManager;
|
import com.esophose.playerparticles.manager.DataManager;
|
||||||
import com.esophose.playerparticles.manager.LangManager;
|
import com.esophose.playerparticles.manager.LangManager;
|
||||||
|
import com.esophose.playerparticles.manager.LangManager.Lang;
|
||||||
import com.esophose.playerparticles.manager.ParticleManager;
|
import com.esophose.playerparticles.manager.ParticleManager;
|
||||||
import com.esophose.playerparticles.manager.PermissionManager;
|
import com.esophose.playerparticles.manager.PermissionManager;
|
||||||
import com.esophose.playerparticles.manager.LangManager.Lang;
|
|
||||||
import com.esophose.playerparticles.particles.PPlayer;
|
import com.esophose.playerparticles.particles.PPlayer;
|
||||||
import com.esophose.playerparticles.particles.ParticleEffect;
|
import com.esophose.playerparticles.particles.ParticleEffect;
|
||||||
import com.esophose.playerparticles.particles.ParticleEffect.NoteColor;
|
import com.esophose.playerparticles.particles.ParticleEffect.NoteColor;
|
||||||
|
@ -116,15 +120,59 @@ public class AddCommandModule implements CommandModule {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
ParticleGroup group = pplayer.getActiveParticleGroup();
|
|
||||||
group.getParticles().add(new ParticlePair(pplayer.getUniqueId(), pplayer.getNextActiveParticleId(), effect, style, blockData, blockData, colorData, noteColorData));
|
|
||||||
DataManager.saveParticleGroup(pplayer.getUniqueId(), group);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
ParticleGroup group = pplayer.getActiveParticleGroup();
|
||||||
|
ParticlePair newParticle = new ParticlePair(pplayer.getUniqueId(), pplayer.getNextActiveParticleId(), effect, style, blockData, blockData, colorData, noteColorData);
|
||||||
|
group.getParticles().add(newParticle);
|
||||||
|
DataManager.saveParticleGroup(pplayer.getUniqueId(), group);
|
||||||
|
|
||||||
|
LangManager.sendMessage(pplayer, Lang.COMMAND_ADD_PARTICLE_APPLIED, newParticle.getEffect().getName(), newParticle.getStyle().getName(), newParticle.getDataString());
|
||||||
}
|
}
|
||||||
|
|
||||||
public List<String> onTabComplete(PPlayer pplayer, String[] args) {
|
public List<String> onTabComplete(PPlayer pplayer, String[] args) {
|
||||||
return null;
|
Player p = pplayer.getPlayer();
|
||||||
|
List<String> matches = new ArrayList<String>();
|
||||||
|
System.out.println("Args in AddCommandModule: " + Arrays.toString(args) + " " + args.length);
|
||||||
|
if (args.length <= 1) { // Effect name
|
||||||
|
if (args.length == 0) matches = PermissionManager.getEffectsUserHasPermissionFor(p);
|
||||||
|
else StringUtil.copyPartialMatches(args[0], PermissionManager.getEffectsUserHasPermissionFor(p), matches);
|
||||||
|
} else if (args.length == 2) { // Style name
|
||||||
|
StringUtil.copyPartialMatches(args[1], PermissionManager.getStylesUserHasPermissionFor(p), matches);
|
||||||
|
} else if (args.length >= 3) { // Data
|
||||||
|
ParticleEffect effect = ParticleEffect.fromName(args[0]);
|
||||||
|
if (effect != null) {
|
||||||
|
if (effect.hasProperty(ParticleProperty.COLORABLE)) {
|
||||||
|
List<String> possibleValues = new ArrayList<String>();
|
||||||
|
if (effect == ParticleEffect.NOTE) { // Note data
|
||||||
|
if (args.length == 3) {
|
||||||
|
possibleValues.add("<0-23>");
|
||||||
|
possibleValues.add("rainbow");
|
||||||
|
}
|
||||||
|
} else { // Color data
|
||||||
|
if (args.length <= 5 && !args[2].equalsIgnoreCase("rainbow")) {
|
||||||
|
possibleValues.add("<0-255>");
|
||||||
|
}
|
||||||
|
if (args.length <= 4 && !args[2].equalsIgnoreCase("rainbow")) {
|
||||||
|
possibleValues.add("<0-255> <0-255>");
|
||||||
|
}
|
||||||
|
if (args.length <= 3) {
|
||||||
|
possibleValues.add("<0-255> <0-255> <0-255>");
|
||||||
|
possibleValues.add("rainbow");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
StringUtil.copyPartialMatches(args[args.length - 1], possibleValues, matches);
|
||||||
|
} else if (args.length == 3 && effect.hasProperty(ParticleProperty.REQUIRES_MATERIAL_DATA)) {
|
||||||
|
if (effect == ParticleEffect.BLOCK || effect == ParticleEffect.FALLING_DUST) { // Block material
|
||||||
|
matches = StringUtil.copyPartialMatches(args[2], ParticleUtils.getAllBlockMaterials(), matches);
|
||||||
|
} else if (effect == ParticleEffect.ITEM) { // Item material
|
||||||
|
matches = StringUtil.copyPartialMatches(args[2], ParticleUtils.getAllItemMaterials(), matches);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return matches;
|
||||||
}
|
}
|
||||||
|
|
||||||
public String getName() {
|
public String getName() {
|
||||||
|
|
|
@ -1,11 +1,14 @@
|
||||||
package com.esophose.playerparticles.command;
|
package com.esophose.playerparticles.command;
|
||||||
|
|
||||||
|
import java.text.MessageFormat;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import com.esophose.playerparticles.manager.LangManager;
|
import com.esophose.playerparticles.manager.LangManager;
|
||||||
import com.esophose.playerparticles.manager.LangManager.Lang;
|
import com.esophose.playerparticles.manager.LangManager.Lang;
|
||||||
import com.esophose.playerparticles.particles.PPlayer;
|
import com.esophose.playerparticles.particles.PPlayer;
|
||||||
|
|
||||||
|
import net.md_5.bungee.api.ChatColor;
|
||||||
|
|
||||||
public interface CommandModule {
|
public interface CommandModule {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -59,7 +62,24 @@ public interface CommandModule {
|
||||||
* @param command The command to display usage for
|
* @param command The command to display usage for
|
||||||
*/
|
*/
|
||||||
public static void printUsage(PPlayer pplayer, CommandModule command) {
|
public static void printUsage(PPlayer pplayer, CommandModule command) {
|
||||||
LangManager.sendCustomMessage(pplayer, String.format("/{0} {1}", command.getName(), command.getArguments()));
|
Object[] args = new Object[] { command.getName(), command.getArguments() };
|
||||||
|
LangManager.sendCustomMessage(pplayer, new MessageFormat(ChatColor.YELLOW + "/pp {0} {1}").format(args));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Displays a command's usage (with its description) to the player
|
||||||
|
*
|
||||||
|
* @param pplayer The PPlayer to display the command usage to
|
||||||
|
* @param command The command to display usage for
|
||||||
|
*/
|
||||||
|
public static void printUsageWithDescription(PPlayer pplayer, CommandModule command) {
|
||||||
|
if (command.getArguments().length() == 0) {
|
||||||
|
Object[] args = new Object[] { command.getName(), LangManager.getText(command.getDescription()) };
|
||||||
|
LangManager.sendCustomMessage(pplayer, new MessageFormat(ChatColor.YELLOW + "/pp {0} - {1}").format(args));
|
||||||
|
} else {
|
||||||
|
Object[] args = new Object[] { command.getName(), command.getArguments(), LangManager.getText(command.getDescription()) };
|
||||||
|
LangManager.sendCustomMessage(pplayer, new MessageFormat(ChatColor.YELLOW + "/pp {0} {1} - {2}").format(args));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -71,7 +91,8 @@ public interface CommandModule {
|
||||||
* @param subCommandArgs The sub-command's arguments
|
* @param subCommandArgs The sub-command's arguments
|
||||||
*/
|
*/
|
||||||
public static void printSubcommandUsage(PPlayer pplayer, CommandModule command, String subCommandName, String subCommandArgs) {
|
public static void printSubcommandUsage(PPlayer pplayer, CommandModule command, String subCommandName, String subCommandArgs) {
|
||||||
LangManager.sendCustomMessage(pplayer, String.format("/{0} {1} {2}", command.getName(), subCommandName, subCommandArgs));
|
Object[] args = new Object[] { command.getName(), subCommandName, subCommandArgs };
|
||||||
|
LangManager.sendCustomMessage(pplayer, new MessageFormat(ChatColor.YELLOW + "/pp {0} {1} {2}").format(args));
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,7 +1,10 @@
|
||||||
package com.esophose.playerparticles.command;
|
package com.esophose.playerparticles.command;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
|
import org.bukkit.util.StringUtil;
|
||||||
|
|
||||||
import com.esophose.playerparticles.manager.LangManager.Lang;
|
import com.esophose.playerparticles.manager.LangManager.Lang;
|
||||||
import com.esophose.playerparticles.particles.PPlayer;
|
import com.esophose.playerparticles.particles.PPlayer;
|
||||||
|
|
||||||
|
@ -13,7 +16,14 @@ public class DefaultCommandModule implements CommandModule {
|
||||||
}
|
}
|
||||||
|
|
||||||
public List<String> onTabComplete(PPlayer pplayer, String[] args) {
|
public List<String> onTabComplete(PPlayer pplayer, String[] args) {
|
||||||
return null;
|
List<String> matches = new ArrayList<String>();
|
||||||
|
List<String> commandNames = ParticleCommandHandler.getCommandNames();
|
||||||
|
|
||||||
|
if (args.length == 0) return commandNames;
|
||||||
|
|
||||||
|
StringUtil.copyPartialMatches(args[0], commandNames, matches);
|
||||||
|
|
||||||
|
return matches;
|
||||||
}
|
}
|
||||||
|
|
||||||
public String getName() {
|
public String getName() {
|
||||||
|
|
|
@ -8,7 +8,10 @@ import com.esophose.playerparticles.particles.PPlayer;
|
||||||
public class HelpCommandModule implements CommandModule {
|
public class HelpCommandModule implements CommandModule {
|
||||||
|
|
||||||
public void onCommandExecute(PPlayer pplayer, String[] args) {
|
public void onCommandExecute(PPlayer pplayer, String[] args) {
|
||||||
// TODO: Rewrite to be dynamically generated from the ParticleCommandHandler's registered CommandModules
|
List<CommandModule> cmds = ParticleCommandHandler.getCommands();
|
||||||
|
for (CommandModule cmd : cmds) {
|
||||||
|
CommandModule.printUsageWithDescription(pplayer, cmd);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public List<String> onTabComplete(PPlayer pplayer, String[] args) {
|
public List<String> onTabComplete(PPlayer pplayer, String[] args) {
|
||||||
|
|
|
@ -57,6 +57,27 @@ public class ParticleCommandHandler implements CommandExecutor, TabCompleter {
|
||||||
return commandModule;
|
return commandModule;
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get a list of all available commands
|
||||||
|
*
|
||||||
|
* @return A List of all CommandModules registered
|
||||||
|
*/
|
||||||
|
public static List<CommandModule> getCommands() {
|
||||||
|
return commands;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get all available command names
|
||||||
|
*
|
||||||
|
* @return All available command names
|
||||||
|
*/
|
||||||
|
public static List<String> getCommandNames() {
|
||||||
|
List<String> commandNames = new ArrayList<String>();
|
||||||
|
for (CommandModule cmd : commands)
|
||||||
|
commandNames.add(cmd.getName());
|
||||||
|
return commandNames;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Called when a player executes a /pp command
|
* Called when a player executes a /pp command
|
||||||
|
@ -110,10 +131,14 @@ public class ParticleCommandHandler implements CommandExecutor, TabCompleter {
|
||||||
if (!(sender instanceof Player)) return new ArrayList<String>();
|
if (!(sender instanceof Player)) return new ArrayList<String>();
|
||||||
|
|
||||||
if (cmd.getName().equalsIgnoreCase("pp")) {
|
if (cmd.getName().equalsIgnoreCase("pp")) {
|
||||||
if (args.length > 1) {
|
System.out.println("Args in onTabComplete: " + Arrays.toString(args) + " " + args.length);
|
||||||
|
if (args.length <= 1) {
|
||||||
|
CommandModule commandModule = findMatchingCommand(""); // Get the default command module
|
||||||
|
return commandModule.onTabComplete(DataManager.getPPlayer(((Player) sender).getUniqueId()), args);
|
||||||
|
} else if (args.length >= 2) {
|
||||||
CommandModule commandModule = findMatchingCommand(args[0]);
|
CommandModule commandModule = findMatchingCommand(args[0]);
|
||||||
|
String[] cmdArgs = Arrays.copyOfRange(args, 1, args.length);
|
||||||
if (commandModule != null) {
|
if (commandModule != null) {
|
||||||
String[] cmdArgs = Arrays.copyOfRange(args, 1, args.length);
|
|
||||||
return commandModule.onTabComplete(DataManager.getPPlayer(((Player) sender).getUniqueId()), cmdArgs);
|
return commandModule.onTabComplete(DataManager.getPPlayer(((Player) sender).getUniqueId()), cmdArgs);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -250,7 +250,7 @@ public class PlayerParticlesGui extends BukkitRunnable implements Listener {
|
||||||
particles.clear();
|
particles.clear();
|
||||||
particles.add(particle);
|
particles.add(particle);
|
||||||
|
|
||||||
ParticleGroup group = new ParticleGroup(null, particles);
|
ParticleGroup group = new ParticleGroup(ParticleGroup.DEFAULT_NAME, particles);
|
||||||
DataManager.saveParticleGroup(pplayer.getUniqueId(), group);
|
DataManager.saveParticleGroup(pplayer.getUniqueId(), group);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -264,7 +264,7 @@ public class PlayerParticlesGui extends BukkitRunnable implements Listener {
|
||||||
particles.clear();
|
particles.clear();
|
||||||
particles.add(particle);
|
particles.add(particle);
|
||||||
|
|
||||||
ParticleGroup group = new ParticleGroup(null, particles);
|
ParticleGroup group = new ParticleGroup(ParticleGroup.DEFAULT_NAME, particles);
|
||||||
DataManager.saveParticleGroup(pplayer.getUniqueId(), group);
|
DataManager.saveParticleGroup(pplayer.getUniqueId(), group);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -278,7 +278,7 @@ public class PlayerParticlesGui extends BukkitRunnable implements Listener {
|
||||||
particles.clear();
|
particles.clear();
|
||||||
particles.add(particle);
|
particles.add(particle);
|
||||||
|
|
||||||
ParticleGroup group = new ParticleGroup(null, particles);
|
ParticleGroup group = new ParticleGroup(ParticleGroup.DEFAULT_NAME, particles);
|
||||||
DataManager.saveParticleGroup(pplayer.getUniqueId(), group);
|
DataManager.saveParticleGroup(pplayer.getUniqueId(), group);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -292,7 +292,7 @@ public class PlayerParticlesGui extends BukkitRunnable implements Listener {
|
||||||
particles.clear();
|
particles.clear();
|
||||||
particles.add(particle);
|
particles.add(particle);
|
||||||
|
|
||||||
ParticleGroup group = new ParticleGroup(null, particles);
|
ParticleGroup group = new ParticleGroup(ParticleGroup.DEFAULT_NAME, particles);
|
||||||
DataManager.saveParticleGroup(pplayer.getUniqueId(), group);
|
DataManager.saveParticleGroup(pplayer.getUniqueId(), group);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -306,7 +306,7 @@ public class PlayerParticlesGui extends BukkitRunnable implements Listener {
|
||||||
particles.clear();
|
particles.clear();
|
||||||
particles.add(particle);
|
particles.add(particle);
|
||||||
|
|
||||||
ParticleGroup group = new ParticleGroup(null, particles);
|
ParticleGroup group = new ParticleGroup(ParticleGroup.DEFAULT_NAME, particles);
|
||||||
DataManager.saveParticleGroup(pplayer.getUniqueId(), group);
|
DataManager.saveParticleGroup(pplayer.getUniqueId(), group);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -320,7 +320,7 @@ public class PlayerParticlesGui extends BukkitRunnable implements Listener {
|
||||||
particles.clear();
|
particles.clear();
|
||||||
particles.add(particle);
|
particles.add(particle);
|
||||||
|
|
||||||
ParticleGroup group = new ParticleGroup(null, particles);
|
ParticleGroup group = new ParticleGroup(ParticleGroup.DEFAULT_NAME, particles);
|
||||||
DataManager.saveParticleGroup(pplayer.getUniqueId(), group);
|
DataManager.saveParticleGroup(pplayer.getUniqueId(), group);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -88,9 +88,10 @@ public class DataManager {
|
||||||
"WHERE g.owner_uuid = ?"; // @formatter:on
|
"WHERE g.owner_uuid = ?"; // @formatter:on
|
||||||
try (PreparedStatement statement = connection.prepareStatement(groupQuery)) {
|
try (PreparedStatement statement = connection.prepareStatement(groupQuery)) {
|
||||||
statement.setString(1, playerUUID.toString());
|
statement.setString(1, playerUUID.toString());
|
||||||
|
System.out.println("Executing particle query");
|
||||||
ResultSet result = statement.executeQuery();
|
ResultSet result = statement.executeQuery();
|
||||||
while (result.next()) {
|
while (result.next()) {
|
||||||
|
System.out.println("Particle result found");
|
||||||
// Group properties
|
// Group properties
|
||||||
String groupName = result.getString("name");
|
String groupName = result.getString("name");
|
||||||
|
|
||||||
|
@ -103,6 +104,15 @@ public class DataManager {
|
||||||
NoteColor noteColor = new NoteColor(result.getInt("note"));
|
NoteColor noteColor = new NoteColor(result.getInt("note"));
|
||||||
OrdinaryColor color = new OrdinaryColor(result.getInt("r"), result.getInt("g"), result.getInt("b"));
|
OrdinaryColor color = new OrdinaryColor(result.getInt("r"), result.getInt("g"), result.getInt("b"));
|
||||||
ParticlePair particle = new ParticlePair(playerUUID, id, effect, style, itemMaterial, blockMaterial, color, noteColor);
|
ParticlePair particle = new ParticlePair(playerUUID, id, effect, style, itemMaterial, blockMaterial, color, noteColor);
|
||||||
|
|
||||||
|
System.out.println("==============================");
|
||||||
|
System.out.println(result.getInt("id"));
|
||||||
|
System.out.println(result.getString("effect"));
|
||||||
|
System.out.println(result.getString("style"));
|
||||||
|
System.out.println(result.getString("item_material"));
|
||||||
|
System.out.println(result.getString("block_material"));
|
||||||
|
System.out.println(result.getInt("note"));
|
||||||
|
System.out.println(result.getInt("r") + " " + result.getInt("g") + " " + result.getInt("b"));
|
||||||
|
|
||||||
// Try to add particle to an existing group
|
// Try to add particle to an existing group
|
||||||
boolean groupAlreadyExists = false;
|
boolean groupAlreadyExists = false;
|
||||||
|
@ -155,7 +165,7 @@ public class DataManager {
|
||||||
}
|
}
|
||||||
|
|
||||||
if (groups.size() == 0) { // If there aren't any groups then this is a brand new PPlayer and we need to save a new active group for them
|
if (groups.size() == 0) { // If there aren't any groups then this is a brand new PPlayer and we need to save a new active group for them
|
||||||
ParticleGroup activeGroup = new ParticleGroup(null, new ArrayList<ParticlePair>());
|
ParticleGroup activeGroup = new ParticleGroup(ParticleGroup.DEFAULT_NAME, new ArrayList<ParticlePair>());
|
||||||
saveParticleGroup(playerUUID, activeGroup);
|
saveParticleGroup(playerUUID, activeGroup);
|
||||||
groups.add(activeGroup);
|
groups.add(activeGroup);
|
||||||
}
|
}
|
||||||
|
@ -222,15 +232,15 @@ public class DataManager {
|
||||||
particlesStatement.setInt(11, particle.getColor().getBlue());
|
particlesStatement.setInt(11, particle.getColor().getBlue());
|
||||||
particlesStatement.addBatch();
|
particlesStatement.addBatch();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
particlesStatement.executeBatch();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
getPPlayer(playerUUID, (pplayer) -> {
|
getPPlayer(playerUUID, (pplayer) -> {
|
||||||
String groupName = group.getName() == null ? "" : group.getName();
|
|
||||||
for (ParticleGroup existing : pplayer.getParticles()) {
|
for (ParticleGroup existing : pplayer.getParticles()) {
|
||||||
String existingName = existing.getName() == null ? "" : existing.getName();
|
if (group.getName().equalsIgnoreCase(existing.getName())) {
|
||||||
if (groupName.equalsIgnoreCase(existingName)) {
|
|
||||||
pplayer.getParticles().remove(existing);
|
pplayer.getParticles().remove(existing);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -298,7 +308,7 @@ public class DataManager {
|
||||||
try (PreparedStatement statement = connection.prepareStatement(particleQuery)) {
|
try (PreparedStatement statement = connection.prepareStatement(particleQuery)) {
|
||||||
ParticlePair particle = fixedEffect.getParticlePair();
|
ParticlePair particle = fixedEffect.getParticlePair();
|
||||||
statement.setString(1, particleUUID);
|
statement.setString(1, particleUUID);
|
||||||
statement.setString(2, null);
|
statement.setNull(2, java.sql.Types.VARCHAR);
|
||||||
statement.setInt(3, fixedEffect.getId());
|
statement.setInt(3, fixedEffect.getId());
|
||||||
statement.setString(4, particle.getEffect().getName());
|
statement.setString(4, particle.getEffect().getName());
|
||||||
statement.setString(5, particle.getStyle().getName());
|
statement.setString(5, particle.getStyle().getName());
|
||||||
|
|
|
@ -5,6 +5,7 @@ import java.io.IOException;
|
||||||
import java.io.InputStream;
|
import java.io.InputStream;
|
||||||
import java.nio.file.Files;
|
import java.nio.file.Files;
|
||||||
import java.nio.file.Paths;
|
import java.nio.file.Paths;
|
||||||
|
import java.text.MessageFormat;
|
||||||
|
|
||||||
import org.bukkit.ChatColor;
|
import org.bukkit.ChatColor;
|
||||||
import org.bukkit.configuration.file.FileConfiguration;
|
import org.bukkit.configuration.file.FileConfiguration;
|
||||||
|
@ -55,6 +56,9 @@ public class LangManager {
|
||||||
COMMAND_DESCRIPTION_GROUP_LOAD,
|
COMMAND_DESCRIPTION_GROUP_LOAD,
|
||||||
COMMAND_DESCRIPTION_GROUP_REMOVE,
|
COMMAND_DESCRIPTION_GROUP_REMOVE,
|
||||||
|
|
||||||
|
// Add Command
|
||||||
|
COMMAND_ADD_PARTICLE_APPLIED,
|
||||||
|
|
||||||
// Effects
|
// Effects
|
||||||
EFFECT_NO_PERMISSION,
|
EFFECT_NO_PERMISSION,
|
||||||
EFFECT_INVALID,
|
EFFECT_INVALID,
|
||||||
|
@ -158,8 +162,8 @@ public class LangManager {
|
||||||
*
|
*
|
||||||
* @return The message
|
* @return The message
|
||||||
*/
|
*/
|
||||||
private String get(String... replacements) {
|
private String get(Object... replacements) {
|
||||||
return String.format(this.message, (Object[]) replacements);
|
return new MessageFormat(this.message).format(replacements);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -198,8 +202,8 @@ public class LangManager {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Loads the target .lang file as defined in the config and grabs its YamlConfiguration
|
* Loads the target .lang file as defined in the config and grabs its YamlConfiguration
|
||||||
* If it doesn't exist, default to en_US.lang
|
* If it doesn't exist, default to default.lang
|
||||||
* If en_US.lang doesn't exist, copy the file from this .jar to the target directory
|
* If default.lang doesn't exist, copy the file from this .jar to the target directory
|
||||||
*
|
*
|
||||||
* @param config The plugin's configuration file
|
* @param config The plugin's configuration file
|
||||||
* @return The YamlConfiguration of the target .lang file
|
* @return The YamlConfiguration of the target .lang file
|
||||||
|
@ -209,21 +213,21 @@ public class LangManager {
|
||||||
langFileName = config.getString("lang-file");
|
langFileName = config.getString("lang-file");
|
||||||
File targetLangFile = new File(pluginDataFolder.getAbsolutePath() + "/lang/" + langFileName);
|
File targetLangFile = new File(pluginDataFolder.getAbsolutePath() + "/lang/" + langFileName);
|
||||||
|
|
||||||
if (!targetLangFile.exists()) { // Target .lang file didn't exist, default to en_US.lang
|
if (!targetLangFile.exists()) { // Target .lang file didn't exist, default to default.lang
|
||||||
if (!langFileName.equals("en_US.lang")) {
|
if (!langFileName.equals("default.lang")) {
|
||||||
PlayerParticles.getPlugin().getLogger().warning("Couldn't find lang file '" + langFileName + "', defaulting to en_US.lang");
|
PlayerParticles.getPlugin().getLogger().warning("Couldn't find lang file '" + langFileName + "', defaulting to default.lang");
|
||||||
}
|
}
|
||||||
langFileName = "en_US.lang";
|
langFileName = "default.lang";
|
||||||
|
|
||||||
targetLangFile = new File(pluginDataFolder.getAbsolutePath() + "/lang/" + langFileName);
|
targetLangFile = new File(pluginDataFolder.getAbsolutePath() + "/lang/" + langFileName);
|
||||||
if (!targetLangFile.exists()) { // en_US.lang didn't exist, create it
|
if (!targetLangFile.exists()) { // default.lang didn't exist, create it
|
||||||
try (InputStream stream = PlayerParticles.getPlugin().getResource("lang/en_US.lang")) {
|
try (InputStream stream = PlayerParticles.getPlugin().getResource("lang/default.lang")) {
|
||||||
targetLangFile.getParentFile().mkdir(); // Make sure the directory always exists
|
targetLangFile.getParentFile().mkdir(); // Make sure the directory always exists
|
||||||
Files.copy(stream, Paths.get(targetLangFile.getAbsolutePath()));
|
Files.copy(stream, Paths.get(targetLangFile.getAbsolutePath()));
|
||||||
return YamlConfiguration.loadConfiguration(targetLangFile);
|
return YamlConfiguration.loadConfiguration(targetLangFile);
|
||||||
} catch (IOException ex) {
|
} catch (IOException ex) {
|
||||||
ex.printStackTrace();
|
ex.printStackTrace();
|
||||||
PlayerParticles.getPlugin().getLogger().severe("Unable to write en_US.lang to disk! All messages for the plugin have been disabled until this is fixed!");
|
PlayerParticles.getPlugin().getLogger().severe("Unable to write default.lang to disk! All messages for the plugin have been disabled until this is fixed!");
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -238,7 +242,7 @@ public class LangManager {
|
||||||
* @param messageType The message type to get
|
* @param messageType The message type to get
|
||||||
* @param replacements The replacements fot the message
|
* @param replacements The replacements fot the message
|
||||||
*/
|
*/
|
||||||
public static String getText(Lang messageType, String... replacements) {
|
public static String getText(Lang messageType, Object... replacements) {
|
||||||
return messageType.get(replacements);
|
return messageType.get(replacements);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -248,7 +252,7 @@ public class LangManager {
|
||||||
* @param player The player to send the message to
|
* @param player The player to send the message to
|
||||||
* @param messageType The message to send to the player
|
* @param messageType The message to send to the player
|
||||||
*/
|
*/
|
||||||
public static void sendMessage(Player player, Lang messageType, String... replacements) {
|
public static void sendMessage(Player player, Lang messageType, Object... replacements) {
|
||||||
if (!messagesEnabled) return;
|
if (!messagesEnabled) return;
|
||||||
|
|
||||||
String message = messageType.get(replacements);
|
String message = messageType.get(replacements);
|
||||||
|
@ -270,8 +274,8 @@ public class LangManager {
|
||||||
* @param pplayer The player to send the message to
|
* @param pplayer The player to send the message to
|
||||||
* @param messageType The message to send to the player
|
* @param messageType The message to send to the player
|
||||||
*/
|
*/
|
||||||
public static void sendMessage(PPlayer pplayer, Lang messageType, String... replacements) {
|
public static void sendMessage(PPlayer pplayer, Lang messageType, Object... replacements) {
|
||||||
sendMessage(pplayer, messageType, replacements);
|
sendMessage(pplayer.getPlayer(), messageType, replacements);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -131,13 +131,11 @@ public class ParticleManager extends BukkitRunnable implements Listener {
|
||||||
// Don't show their particles if they are in spectator mode
|
// Don't show their particles if they are in spectator mode
|
||||||
// Don't spawn particles if the world doesn't allow it
|
// Don't spawn particles if the world doesn't allow it
|
||||||
if (player != null && player.getGameMode() != GameMode.SPECTATOR && !DataManager.isWorldDisabled(player.getWorld().getName())) {
|
if (player != null && player.getGameMode() != GameMode.SPECTATOR && !DataManager.isWorldDisabled(player.getWorld().getName())) {
|
||||||
Location loc = player.getLocation();
|
for (ParticlePair particles : pplayer.getActiveParticles()) {
|
||||||
loc.setY(loc.getY() + 1);
|
displayParticles(particles, player.getLocation().clone().add(0, 1, 0));
|
||||||
|
}
|
||||||
for (ParticlePair particles : pplayer.getActiveParticles())
|
|
||||||
displayParticles(particles, loc);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Loop for FixedParticleEffects
|
// Loop for FixedParticleEffects
|
||||||
// Don't spawn particles if the world doesn't allow it
|
// Don't spawn particles if the world doesn't allow it
|
||||||
for (FixedParticleEffect effect : pplayer.getFixedParticles())
|
for (FixedParticleEffect effect : pplayer.getFixedParticles())
|
||||||
|
|
|
@ -96,7 +96,7 @@ public class PPlayer {
|
||||||
*/
|
*/
|
||||||
public ParticleGroup getActiveParticleGroup() {
|
public ParticleGroup getActiveParticleGroup() {
|
||||||
for (ParticleGroup group : this.particleGroups)
|
for (ParticleGroup group : this.particleGroups)
|
||||||
if (group.getName() == null)
|
if (group.getName().equals(ParticleGroup.DEFAULT_NAME))
|
||||||
return group;
|
return group;
|
||||||
return null; // This should never return null, there will always be at least one ParticleGroup
|
return null; // This should never return null, there will always be at least one ParticleGroup
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,6 +4,8 @@ import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
public class ParticleGroup {
|
public class ParticleGroup {
|
||||||
|
|
||||||
|
public static final String DEFAULT_NAME = "active";
|
||||||
|
|
||||||
private String name;
|
private String name;
|
||||||
private List<ParticlePair> particles;
|
private List<ParticlePair> particles;
|
||||||
|
@ -38,7 +40,7 @@ public class ParticleGroup {
|
||||||
* @return The default empty active ParticleGroup
|
* @return The default empty active ParticleGroup
|
||||||
*/
|
*/
|
||||||
public static ParticleGroup getDefaultGroup() {
|
public static ParticleGroup getDefaultGroup() {
|
||||||
return new ParticleGroup(null, new ArrayList<ParticlePair>());
|
return new ParticleGroup(DEFAULT_NAME, new ArrayList<ParticlePair>());
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -23,7 +23,7 @@ public class ParticleStyleBlockBreak implements ParticleStyle, Listener {
|
||||||
List<PParticle> particles = new ArrayList<PParticle>();
|
List<PParticle> particles = new ArrayList<PParticle>();
|
||||||
|
|
||||||
for (int i = 0; i < 15; i++)
|
for (int i = 0; i < 15; i++)
|
||||||
particles.add(new PParticle(location.clone().add(0.5, 0.5, 0.5), 0.5F, 0.5F, 0.5F, 0.05F));
|
particles.add(new PParticle(location.add(0.5, 0.5, 0.5), 0.5F, 0.5F, 0.5F, 0.05F));
|
||||||
|
|
||||||
return particles;
|
return particles;
|
||||||
}
|
}
|
||||||
|
@ -46,7 +46,7 @@ public class ParticleStyleBlockBreak implements ParticleStyle, Listener {
|
||||||
PPlayer pplayer = DataManager.getPPlayer(player.getUniqueId());
|
PPlayer pplayer = DataManager.getPPlayer(player.getUniqueId());
|
||||||
if (pplayer != null) {
|
if (pplayer != null) {
|
||||||
for (ParticlePair particle : pplayer.getActiveParticlesForStyle(DefaultStyles.BLOCKBREAK)) {
|
for (ParticlePair particle : pplayer.getActiveParticlesForStyle(DefaultStyles.BLOCKBREAK)) {
|
||||||
Location loc = event.getBlock().getLocation();
|
Location loc = event.getBlock().getLocation().clone();
|
||||||
ParticleManager.displayParticles(particle, DefaultStyles.BLOCKBREAK.getParticles(particle, loc));
|
ParticleManager.displayParticles(particle, DefaultStyles.BLOCKBREAK.getParticles(particle, loc));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -54,7 +54,7 @@ public class ParticleStyleBlockEdit implements ParticleStyle, Listener {
|
||||||
PPlayer pplayer = DataManager.getPPlayer(player.getUniqueId());
|
PPlayer pplayer = DataManager.getPPlayer(player.getUniqueId());
|
||||||
if (pplayer != null) {
|
if (pplayer != null) {
|
||||||
for (ParticlePair particle : pplayer.getActiveParticlesForStyle(DefaultStyles.BLOCKEDIT)) {
|
for (ParticlePair particle : pplayer.getActiveParticlesForStyle(DefaultStyles.BLOCKEDIT)) {
|
||||||
Location loc = event.getBlock().getLocation();
|
Location loc = event.getBlock().getLocation().clone();
|
||||||
ParticleManager.displayParticles(particle, DefaultStyles.BLOCKPLACE.getParticles(particle, loc));
|
ParticleManager.displayParticles(particle, DefaultStyles.BLOCKPLACE.getParticles(particle, loc));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -23,7 +23,7 @@ public class ParticleStyleBlockPlace implements ParticleStyle, Listener {
|
||||||
List<PParticle> particles = new ArrayList<PParticle>();
|
List<PParticle> particles = new ArrayList<PParticle>();
|
||||||
|
|
||||||
for (int i = 0; i < 15; i++)
|
for (int i = 0; i < 15; i++)
|
||||||
particles.add(new PParticle(location.clone().add(0.5, 0.5, 0.5), 0.75F, 0.75F, 0.75F, 0.05F));
|
particles.add(new PParticle(location.add(0.5, 0.5, 0.5), 0.75F, 0.75F, 0.75F, 0.05F));
|
||||||
|
|
||||||
return particles;
|
return particles;
|
||||||
}
|
}
|
||||||
|
@ -46,7 +46,7 @@ public class ParticleStyleBlockPlace implements ParticleStyle, Listener {
|
||||||
PPlayer pplayer = DataManager.getPPlayer(player.getUniqueId());
|
PPlayer pplayer = DataManager.getPPlayer(player.getUniqueId());
|
||||||
if (pplayer != null) {
|
if (pplayer != null) {
|
||||||
for (ParticlePair particle : pplayer.getActiveParticlesForStyle(DefaultStyles.BLOCKPLACE)) {
|
for (ParticlePair particle : pplayer.getActiveParticlesForStyle(DefaultStyles.BLOCKPLACE)) {
|
||||||
Location loc = event.getBlock().getLocation();
|
Location loc = event.getBlock().getLocation().clone();
|
||||||
ParticleManager.displayParticles(particle, DefaultStyles.BLOCKPLACE.getParticles(particle, loc));
|
ParticleManager.displayParticles(particle, DefaultStyles.BLOCKPLACE.getParticles(particle, loc));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -70,7 +70,7 @@ public class ParticleStyleCube implements ParticleStyle {
|
||||||
VectorUtils.rotateAroundAxisX(v, angleX);
|
VectorUtils.rotateAroundAxisX(v, angleX);
|
||||||
VectorUtils.rotateAroundAxisY(v, angleY);
|
VectorUtils.rotateAroundAxisY(v, angleY);
|
||||||
VectorUtils.rotateVector(v, xRotation, yRotation, zRotation);
|
VectorUtils.rotateVector(v, xRotation, yRotation, zRotation);
|
||||||
pparticles.add(new PParticle(location.clone().add(v)));
|
pparticles.add(new PParticle(location.add(v)));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
for (int p = 0; p <= particles; p++) {
|
for (int p = 0; p <= particles; p++) {
|
||||||
|
@ -78,7 +78,7 @@ public class ParticleStyleCube implements ParticleStyle {
|
||||||
v.setY(edgeLength * p / particles - a);
|
v.setY(edgeLength * p / particles - a);
|
||||||
VectorUtils.rotateAroundAxisY(v, angleY);
|
VectorUtils.rotateAroundAxisY(v, angleY);
|
||||||
VectorUtils.rotateVector(v, xRotation, yRotation, zRotation);
|
VectorUtils.rotateVector(v, xRotation, yRotation, zRotation);
|
||||||
pparticles.add(new PParticle(location.clone().add(v)));
|
pparticles.add(new PParticle(location.add(v)));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -38,7 +38,7 @@ public class ParticleStyleMove implements ParticleStyle, Listener {
|
||||||
PPlayer pplayer = DataManager.getPPlayer(e.getPlayer().getUniqueId());
|
PPlayer pplayer = DataManager.getPPlayer(e.getPlayer().getUniqueId());
|
||||||
if (pplayer != null) {
|
if (pplayer != null) {
|
||||||
for (ParticlePair particle : pplayer.getActiveParticlesForStyle(DefaultStyles.MOVE)) {
|
for (ParticlePair particle : pplayer.getActiveParticlesForStyle(DefaultStyles.MOVE)) {
|
||||||
Location loc = e.getPlayer().getLocation();
|
Location loc = e.getPlayer().getLocation().clone();
|
||||||
loc.setY(loc.getY() + 0.05);
|
loc.setY(loc.getY() + 0.05);
|
||||||
ParticleManager.displayParticles(particle, DefaultStyles.MOVE.getParticles(particle, loc));
|
ParticleManager.displayParticles(particle, DefaultStyles.MOVE.getParticles(particle, loc));
|
||||||
}
|
}
|
||||||
|
|
|
@ -6,6 +6,21 @@ import java.util.List;
|
||||||
import org.bukkit.Material;
|
import org.bukkit.Material;
|
||||||
|
|
||||||
public class ParticleUtils {
|
public class ParticleUtils {
|
||||||
|
|
||||||
|
private static List<String> blockMaterials, itemMaterials;
|
||||||
|
|
||||||
|
static {
|
||||||
|
blockMaterials = new ArrayList<String>();
|
||||||
|
itemMaterials = new ArrayList<String>();
|
||||||
|
|
||||||
|
for (Material mat : Material.values()) {
|
||||||
|
if (mat.isBlock()) {
|
||||||
|
blockMaterials.add(mat.name().toLowerCase());
|
||||||
|
} else {
|
||||||
|
itemMaterials.add(mat.name().toLowerCase());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Finds a block/item as a material from a string
|
* Finds a block/item as a material from a string
|
||||||
|
@ -45,19 +60,11 @@ public class ParticleUtils {
|
||||||
}
|
}
|
||||||
|
|
||||||
public static List<String> getAllBlockMaterials() {
|
public static List<String> getAllBlockMaterials() {
|
||||||
List<String> materials = new ArrayList<String>();
|
return blockMaterials;
|
||||||
for (Material mat : Material.values())
|
|
||||||
if (mat.isBlock())
|
|
||||||
materials.add(mat.name().toLowerCase());
|
|
||||||
return materials;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public static List<String> getAllItemMaterials() {
|
public static List<String> getAllItemMaterials() {
|
||||||
List<String> materials = new ArrayList<String>();
|
return itemMaterials;
|
||||||
for (Material mat : Material.values())
|
|
||||||
if (!mat.isBlock())
|
|
||||||
materials.add(mat.name().toLowerCase());
|
|
||||||
return materials;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -20,8 +20,8 @@ version: 5.3
|
||||||
check-updates: true
|
check-updates: true
|
||||||
|
|
||||||
# The .lang file to use in the ./lang/ folder
|
# The .lang file to use in the ./lang/ folder
|
||||||
# Default: 'en_US.lang'
|
# Default: 'default.lang'
|
||||||
lang-file: 'en_US.lang'
|
lang-file: 'default.lang'
|
||||||
|
|
||||||
# If you're using other plugins to execute commands you may wish to turn off messages
|
# If you're using other plugins to execute commands you may wish to turn off messages
|
||||||
# Default: true
|
# Default: true
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
# ================================================================ #
|
# ================================================================ #
|
||||||
# en_US.lang MESSAGE CONFIGURATION #
|
# default.lang (English) MESSAGE CONFIGURATION #
|
||||||
# Important Notes: #
|
# Important Notes: #
|
||||||
# * You can use the & symbol to color the messages #
|
# * You can use the & symbol to color the messages #
|
||||||
# * {#} Will be replaced with whatever that message requires #
|
# * {#} Will be replaced with whatever that message requires #
|
||||||
|
@ -17,7 +17,7 @@ command-description-add: 'Add a particle to your active particles'
|
||||||
command-description-data: 'Check what type of data an effect uses'
|
command-description-data: 'Check what type of data an effect uses'
|
||||||
command-description-default: 'The main command. By default, opens the GUI.'
|
command-description-default: 'The main command. By default, opens the GUI.'
|
||||||
command-description-edit: 'Edit the effect, style, or data of an active particle'
|
command-description-edit: 'Edit the effect, style, or data of an active particle'
|
||||||
command-description-effect: 'This command has been removed, use /pp help to find new commands'
|
command-description-effect: '&cThis command has been removed, use &b/pp help &cto find new commands'
|
||||||
command-description-effects: 'Display a list of effects you can use'
|
command-description-effects: 'Display a list of effects you can use'
|
||||||
command-description-fixed: 'Create, edit, and remove fixed particle effects'
|
command-description-fixed: 'Create, edit, and remove fixed particle effects'
|
||||||
command-description-group: 'Save, load, and remove your particle groups'
|
command-description-group: 'Save, load, and remove your particle groups'
|
||||||
|
@ -27,20 +27,23 @@ command-description-info: 'Gets the description of one of your active particles'
|
||||||
command-description-list: 'Lists the ids of your active particles'
|
command-description-list: 'Lists the ids of your active particles'
|
||||||
command-description-remove: 'Removes one of your active particles'
|
command-description-remove: 'Removes one of your active particles'
|
||||||
command-description-reset: 'Removes all your active particles'
|
command-description-reset: 'Removes all your active particles'
|
||||||
command-description-style: 'This command has been removed, use /pp help to find new commands'
|
command-description-style: '&cThis command has been removed, use &b/pp help &cto find new commands'
|
||||||
command-description-styles: 'Display a list of styles you can use'
|
command-description-styles: 'Display a list of styles you can use'
|
||||||
command-description-version: 'Display the current version of the plugin and the author'
|
command-description-version: 'Display the current version of the plugin and the author'
|
||||||
command-description-worlds: 'Find out what worlds PlayerParticles is disabled in'
|
command-description-worlds: 'Find out what worlds particles is disabled in'
|
||||||
|
|
||||||
# Sub-Command Usage
|
# Sub-Command Usage
|
||||||
command-description-fixed-create: '/pp fixed create <x> <y> <z> <effect> <style> [data] - Creates a new fixed effect'
|
command-description-fixed-create: '&e/pp fixed create <x> <y> <z> <effect> <style> [data] - Creates a new fixed effect'
|
||||||
command-description-fixed-remove: '/pp fixed remove <id> - Removes a fixed effect by its id'
|
command-description-fixed-remove: '&e/pp fixed remove <id> - Removes a fixed effect by its id'
|
||||||
command-description-fixed-list: '/pp fixed list - Lists all ids of your fixed effects'
|
command-description-fixed-list: '&e/pp fixed list - Lists all ids of your fixed effects'
|
||||||
command-description-fixed-info: '/pp fixed info <id> - Gets info on one of your fixed effects'
|
command-description-fixed-info: '&e/pp fixed info <id> - Gets info on one of your fixed effects'
|
||||||
command-description-fixed-clear: '/pp fixed clear <radius> - Clears all fixed effects of all players within the given radius'
|
command-description-fixed-clear: '&e/pp fixed clear <radius> - Clears all fixed effects of all players within the given radius'
|
||||||
command-description-group-save: '/pp group save <name> - Saves all currently applied particles under a given name'
|
command-description-group-save: '&e/pp group save <name> - Saves all currently applied particles under a given name'
|
||||||
command-description-group-load: '/pp group load <name> - Loads all particles saved under a given name'
|
command-description-group-load: '&e/pp group load <name> - Loads all particles saved under a given name'
|
||||||
command-description-group-remove: '/pp group remove <name> - Removes all particles saved under a given name'
|
command-description-group-remove: '&e/pp group remove <name> - Removes all particles saved under a given name'
|
||||||
|
|
||||||
|
# Add Command
|
||||||
|
command-add-particle-applied: '&aA new particle has been applied with the effect &b{0}&a, style &b{1}&a, and data &b{2}&a!'
|
||||||
|
|
||||||
# Effects
|
# Effects
|
||||||
effect-no-permission: '&cYou do not have permission to use the effect &b{0} &c!'
|
effect-no-permission: '&cYou do not have permission to use the effect &b{0} &c!'
|
Loading…
Add table
Add a link
Reference in a new issue