mirror of
https://github.com/TotalFreedomMC/TF-EssentialsX.git
synced 2024-09-10 12:19:57 +00:00
Less sign checking if certain signs aren't enabled.
This commit is contained in:
parent
8e6d4b1595
commit
d722e6a9f0
|
@ -98,9 +98,8 @@ public class SignBlockListener implements Listener
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
for (Signs signs : Signs.values())
|
for (EssentialsSign sign : ess.getSettings().enabledSigns())
|
||||||
{
|
{
|
||||||
final EssentialsSign sign = signs.getSign();
|
|
||||||
if (event.getLine(0).equalsIgnoreCase(sign.getSuccessName()))
|
if (event.getLine(0).equalsIgnoreCase(sign.getSuccessName()))
|
||||||
{
|
{
|
||||||
event.setCancelled(true);
|
event.setCancelled(true);
|
||||||
|
@ -137,9 +136,8 @@ public class SignBlockListener implements Listener
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
for (Signs signs : Signs.values())
|
for (EssentialsSign sign : ess.getSettings().enabledSigns())
|
||||||
{
|
{
|
||||||
final EssentialsSign sign = signs.getSign();
|
|
||||||
if (sign.getBlocks().contains(block.getType())
|
if (sign.getBlocks().contains(block.getType())
|
||||||
&& !sign.onBlockPlace(block, event.getPlayer(), ess))
|
&& !sign.onBlockPlace(block, event.getPlayer(), ess))
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue