Skip to content

Commit

Permalink
add softdepends
Browse files Browse the repository at this point in the history
  • Loading branch information
kristianvld committed Nov 29, 2020
1 parent 0b36109 commit aa6779f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -55,5 +55,6 @@ spigot {
authors = ['kristianvld']
apiVersion = '1.16'
depends = ['Oraxen']
softDepends = ['AngelProtect', 'WorldGuard']
website = 'https://github.com/kristianvld/AngelTrophies'
}
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,7 @@ public void onInteract(PlayerInteractEvent event) {
Block block = event.getClickedBlock().getRelative(event.getBlockFace());

if (!Main.getInstance().getExternal().canBuild(player, block)) {
C.error(player, "You can not place a trophy here.");
return;
}

Expand Down Expand Up @@ -129,6 +130,7 @@ public void onEntityInteract(PlayerInteractAtEntityEvent event) {
} else {
Block block = event.getRightClicked().getLocation().getBlock();
if (!Main.getInstance().getExternal().canBuild(event.getPlayer(), block)) {
C.error(event.getPlayer(), "You can not pickup that trophy.");
return;
}
trophy.pickup(event.getPlayer(), event.getRightClicked());
Expand Down

0 comments on commit aa6779f

Please sign in to comment.