Fixed KittyCannon

This commit is contained in:
Norbi Peti 2015-11-28 01:09:01 +01:00
parent 77bc93d674
commit 682af5c0a0
6 changed files with 14 additions and 6 deletions

Binary file not shown.

View file

@ -46,18 +46,21 @@ public class Commands implements CommandExecutor {
.getUniqueId()); // 2015.08.08.
if (!p.CommentedOnReddit
&& !args[0].toLowerCase().equals("admin")
&& !args[0].toLowerCase().equals("ignore")) {
&& !args[0].toLowerCase().equals("ignore")
&& !args[0].toLowerCase().equals("kittycannon")) {
player.sendMessage("§cError: You need to write your username to the reddit thread at /r/TheButtonMinecraft§r");
return true;
}
if (!p.FlairRecognised
&& !args[0].toLowerCase().equals("admin")
&& !args[0].toLowerCase().equals("ignore")) {
&& !args[0].toLowerCase().equals("ignore")
&& !args[0].toLowerCase().equals("kittycannon")) {
player.sendMessage("Sorry, but your flair isn't recorded. Please ask a mod to set it for you.");
return true;
}
if (!p.FlairDecided && !args[0].toLowerCase().equals("admin")
&& !args[0].toLowerCase().equals("ignore")) {
&& !args[0].toLowerCase().equals("ignore")
&& !args[0].toLowerCase().equals("kittycannon")) {
player.sendMessage("Please select between /u nonpresser and /u cantpress");
return true;
}

View file

@ -334,9 +334,14 @@ public class PlayerListener implements Listener { // 2015.07.16.
MinigamePlayer mp = Minigames.plugin.pdata.getMinigamePlayer(e
.getPlayer());
// System.out.println("B");
if (!e.getPlayer().isOp()
&& (!mp.isInMinigame() || mp.getMinigame().getName(false)
.equalsIgnoreCase(Commands.KittyCannonMinigame)))
/*
* if (!e.getPlayer().isOp() && (!mp.isInMinigame() ||
* mp.getMinigame().getName(false)
* .equalsIgnoreCase(Commands.KittyCannonMinigame))) return;
*/
if (!(mp.isInMinigame() && mp.getMinigame().getName(false)
.equalsIgnoreCase(Commands.KittyCannonMinigame)))
return;
// System.out.println("C");
ItemStack item = e.getItem().getItemStack();