Skip to content

Commit

Permalink
Give more Info to Admins ingame on Error
Browse files Browse the repository at this point in the history
  • Loading branch information
Sn0wStorm committed Jan 17, 2019
1 parent c063037 commit 13d13dc
Showing 1 changed file with 29 additions and 5 deletions.
34 changes: 29 additions & 5 deletions src/com/dre/brewery/Barrel.java
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,12 @@ public boolean hasPermsOpen(Player player, PlayerInteractEvent event) {
P.p.errorLog("Brewery was tested with version 5.8, 6.1 to 7.0 of WorldGuard!");
P.p.errorLog("Disable the WorldGuard support in the config and do /brew reload");
e.printStackTrace();
P.p.msg(player, "&cError opening Barrel, please report to an Admin!");
if (player.hasPermission("brewery.admin") || player.hasPermission("brewery.mod")) {
P.p.msg(player, "&cWorldGuard check Error, Brewery was tested with up to v7.0 of Worldguard");
P.p.msg(player, "&cSet &7useWorldGuard: false &cin the config and /brew reload");
} else {
P.p.msg(player, "&cError opening Barrel, please report to an Admin!");
}
return false;
}
}
Expand All @@ -146,7 +151,12 @@ public boolean hasPermsOpen(Player player, PlayerInteractEvent event) {
P.p.errorLog("Brewery was tested with GriefPrevention v14.5 - v16.9");
P.p.errorLog("Disable the GriefPrevention support in the config and do /brew reload");
e.printStackTrace();
P.p.msg(player, "&cError opening Barrel, please report to an Admin!");
if (player.hasPermission("brewery.admin") || player.hasPermission("brewery.mod")) {
P.p.msg(player, "&cGriefPrevention check Error, Brewery was tested with up to v16.9 of GriefPrevention");
P.p.msg(player, "&cSet &7useGriefPrevention: false &cin the config and /brew reload");
} else {
P.p.msg(player, "&cError opening Barrel, please report to an Admin!");
}
return false;
}
}
Expand All @@ -168,7 +178,12 @@ public boolean hasPermsOpen(Player player, PlayerInteractEvent event) {
P.p.errorLog("Brewery was tested with version 4.5.0 of LWC!");
P.p.errorLog("Disable the LWC support in the config and do /brew reload");
e.printStackTrace();
P.p.msg(player, "&cError opening Barrel, please report to an Admin!");
if (player.hasPermission("brewery.admin") || player.hasPermission("brewery.mod")) {
P.p.msg(player, "&cLWC check Error, Brewery was tested with up to v4.5.0 of LWC");
P.p.msg(player, "&cSet &7useLWC: false &cin the config and /brew reload");
} else {
P.p.msg(player, "&cError opening Barrel, please report to an Admin!");
}
return false;
}
}
Expand All @@ -190,7 +205,11 @@ public boolean hasPermsOpen(Player player, PlayerInteractEvent event) {
P.p.errorLog("Brewery was tested with version 3.9.1 of Citadel!");
P.p.errorLog("Disable Citadel support in the config and do /brew reload");
e.printStackTrace();
P.p.msg(player, "&cError opening Barrel, please report to an admin!");
if (player.hasPermission("brewery.admin") || player.hasPermission("brewery.mod")) {
P.p.msg(player, "&cCitadel check Error, Brewery was tested with up to v3.9.1 of Citadel");
} else {
P.p.msg(player, "&cError opening Barrel, please report to an Admin!");
}
return false;
}
}
Expand All @@ -213,7 +232,12 @@ public boolean hasPermsDestroy(Player player) {
P.p.errorLog("Brewery was tested with version 4.5.0 of LWC!");
P.p.errorLog("Disable the LWC support in the config and do /brew reload");
e.printStackTrace();
P.p.msg(player, "&cError breaking Barrel, please report to an Admin!");
if (player.hasPermission("brewery.admin") || player.hasPermission("brewery.mod")) {
P.p.msg(player, "&cLWC check Error, Brewery was tested with up to v4.5.0 of LWC");
P.p.msg(player, "&cSet &7useLWC: false &cin the config and /brew reload");
} else {
P.p.msg(player, "&cError breaking Barrel, please report to an Admin!");
}
return false;
}
}
Expand Down

0 comments on commit 13d13dc

Please sign in to comment.