Skip to content

Commit

Permalink
Make placing and breaking boats use containertrust (#1065)
Browse files Browse the repository at this point in the history
Consistent with minecarts
  • Loading branch information
FreeMonoid committed Oct 24, 2020
1 parent 202f03e commit 03074bf
Showing 1 changed file with 3 additions and 3 deletions.
Expand Up @@ -1867,10 +1867,10 @@ else if (clickedBlock != null && Tag.ITEMS_BOATS.isTagged(materialInHand))
Claim claim = this.dataStore.getClaimAt(clickedBlock.getLocation(), false, playerData.lastClaim);
if (claim != null)
{
String noBuildReason = claim.allowBuild(player, Material.OAK_BOAT); // Though only checks OAK_BOAT, permission should be same for all boats. Plus it being a boat doesn't seem to make a difference currently.
if (noBuildReason != null)
String reason = claim.allowContainers(player);
if (reason != null)
{
instance.sendMessage(player, TextMode.Err, noBuildReason);
instance.sendMessage(player, TextMode.Err, reason);
event.setCancelled(true);
}
}
Expand Down

0 comments on commit 03074bf

Please sign in to comment.