* Fixed bug with allowedCommands.
This commit is contained in:
		@@ -45,7 +45,7 @@ public class Arena implements ConfigurationSerializable {
 | 
			
		||||
			ArrayList<ItemStack> disguiseBlocks,
 | 
			
		||||
			LocationSerializable lobbyWarp, LocationSerializable hidersWarp,
 | 
			
		||||
			LocationSerializable seekersWarp, List<String> seekersWinCommands,
 | 
			
		||||
			List<String> allowedCommands, List<String> hidersWinCommands,
 | 
			
		||||
			List<String> hidersWinCommands, List<String> allowedCommands,
 | 
			
		||||
			List<Player> playersInArena, ArenaState gameState, int timer,
 | 
			
		||||
			List<Player> seekers) {
 | 
			
		||||
		this.arenaName = arenaName;
 | 
			
		||||
 
 | 
			
		||||
@@ -32,8 +32,10 @@ public class OnPlayerCommandPreprocessEvent implements Listener {
 | 
			
		||||
					return;
 | 
			
		||||
				}
 | 
			
		||||
 | 
			
		||||
				if (arena.allowedCommands.contains(m)) {
 | 
			
		||||
					return;
 | 
			
		||||
				for (String command : arena.allowedCommands) {
 | 
			
		||||
					if (m.startsWith("/" + command)) {
 | 
			
		||||
						return;
 | 
			
		||||
					}
 | 
			
		||||
				}
 | 
			
		||||
 | 
			
		||||
				MessageM.sendFMessage(player, ConfigC.warning_unableToCommand,
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user