mirror of
https://github.com/TotalFreedomMC/TF-ProjectKorra.git
synced 2025-02-11 19:50:37 +00:00
Fixed Generic warning, General Clean up
* Fixed Warning: A generic array of HashSet<String> is created for a varargs parameter * Cleaned Imports * Removed unnecessary toggle message
This commit is contained in:
parent
6e787cf05a
commit
78157bd2ac
3 changed files with 2 additions and 8 deletions
|
@ -5,8 +5,6 @@ import java.sql.ResultSet;
|
||||||
import java.sql.SQLException;
|
import java.sql.SQLException;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.Arrays;
|
import java.util.Arrays;
|
||||||
import java.util.Collection;
|
|
||||||
import java.util.Collections;
|
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.LinkedList;
|
import java.util.LinkedList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
@ -466,10 +464,6 @@ public class Commands {
|
||||||
|
|
||||||
BendingPlayer bPlayer = Methods.getBendingPlayer(s.getName());
|
BendingPlayer bPlayer = Methods.getBendingPlayer(s.getName());
|
||||||
|
|
||||||
if (isToggledForAll) {
|
|
||||||
s.sendMessage(ChatColor.DARK_RED + "Bending has been toggled off for all players. You may not use this command until after it is turned back on.");
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
if (bPlayer.isToggled) {
|
if (bPlayer.isToggled) {
|
||||||
s.sendMessage(ChatColor.RED + "Your bending has been toggled off. You will not be able to use most abilities until you toggle it back.");
|
s.sendMessage(ChatColor.RED + "Your bending has been toggled off. You will not be able to use most abilities until you toggle it back.");
|
||||||
bPlayer.isToggled = false;
|
bPlayer.isToggled = false;
|
||||||
|
@ -500,6 +494,7 @@ public class Commands {
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
s.sendMessage(ChatColor.GOLD + "Proper Usage: /bending toggle <all>");
|
s.sendMessage(ChatColor.GOLD + "Proper Usage: /bending toggle <all>");
|
||||||
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (Arrays.asList(whoaliases).contains(args[0].toLowerCase())) {
|
if (Arrays.asList(whoaliases).contains(args[0].toLowerCase())) {
|
||||||
|
|
|
@ -1475,7 +1475,7 @@ public class Methods {
|
||||||
}
|
}
|
||||||
|
|
||||||
public static boolean isHarmlessAbility(String ability) {
|
public static boolean isHarmlessAbility(String ability) {
|
||||||
return Arrays.asList(AbilityModuleManager.harmlessabilities).contains(ability);
|
return AbilityModuleManager.harmlessabilities.contains(ability);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static boolean isRegionProtectedFromBuild(Player player,
|
public static boolean isRegionProtectedFromBuild(Player player,
|
||||||
|
|
|
@ -4,7 +4,6 @@ import java.util.ArrayList;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import org.bukkit.Bukkit;
|
|
||||||
import org.bukkit.ChatColor;
|
import org.bukkit.ChatColor;
|
||||||
import org.bukkit.GameMode;
|
import org.bukkit.GameMode;
|
||||||
import org.bukkit.Location;
|
import org.bukkit.Location;
|
||||||
|
|
Loading…
Reference in a new issue