Merge branch 'develop' of https://github.com/BentoBoxWorld/BentoBox.git into develop

This commit is contained in:
tastybento 2023-04-22 17:43:41 -07:00
commit f05d4dc57f
3 changed files with 4 additions and 6 deletions

View File

@ -88,7 +88,7 @@
<!-- Do not change unless you want different name for local builds. --> <!-- Do not change unless you want different name for local builds. -->
<build.number>-LOCAL</build.number> <build.number>-LOCAL</build.number>
<!-- This allows to change between versions. --> <!-- This allows to change between versions. -->
<build.version>1.23.0</build.version> <build.version>1.23.2</build.version>
<sonar.organization>bentobox-world</sonar.organization> <sonar.organization>bentobox-world</sonar.organization>
<sonar.host.url>https://sonarcloud.io</sonar.host.url> <sonar.host.url>https://sonarcloud.io</sonar.host.url>
<server.jars>${project.basedir}/lib</server.jars> <server.jars>${project.basedir}/lib</server.jars>

View File

@ -15,7 +15,7 @@ import com.google.common.io.Files;
*/ */
public abstract class Pladdon extends JavaPlugin { public abstract class Pladdon extends JavaPlugin {
private static final String ADDONS_FOLDER = "BentoBox/addons"; private static final String ADDONS_FOLDER = "BentoBox" + File.separator + "addons";
/** /**
* This must return a new instance of the addon. It is called when the Pladdon is loaded. * This must return a new instance of the addon. It is called when the Pladdon is loaded.
@ -33,7 +33,7 @@ public abstract class Pladdon extends JavaPlugin {
} }
protected void moveJar() { protected void moveJar() {
getLogger().severe(getFile().getName() + " must be in the BentoBox/addons folder! Trying to move it there..."); getLogger().severe(getFile().getName() + " must be in the " + ADDONS_FOLDER + " folder! Trying to move it there...");
File addons = new File(getFile().getParent(), ADDONS_FOLDER); File addons = new File(getFile().getParent(), ADDONS_FOLDER);
if (addons.exists() || addons.mkdirs()) { if (addons.exists() || addons.mkdirs()) {
File to = new File(addons, getFile().getName()); File to = new File(addons, getFile().getName());
@ -44,7 +44,7 @@ public abstract class Pladdon extends JavaPlugin {
} catch (IOException ex) { } catch (IOException ex) {
getLogger().severe("Failed to move it. " + ex.getMessage()); getLogger().severe("Failed to move it. " + ex.getMessage());
getLogger().severe("Move " + getFile().getName() + " manually into the BentoBox/addons folder. Then restart server."); getLogger().severe("Move " + getFile().getName() + " manually into the " + ADDONS_FOLDER + " folder. Then restart server.");
} }
} else { } else {
getLogger().warning(getFile().getName() + " already is in the addons folder. Delete the one in the plugins folder."); getLogger().warning(getFile().getName() + " already is in the addons folder. Delete the one in the plugins folder.");

View File

@ -14,7 +14,6 @@ import org.bukkit.event.hanging.HangingPlaceEvent;
import org.bukkit.event.player.PlayerInteractEntityEvent; import org.bukkit.event.player.PlayerInteractEntityEvent;
import org.bukkit.event.player.PlayerInteractEvent; import org.bukkit.event.player.PlayerInteractEvent;
import world.bentobox.bentobox.BentoBox;
import world.bentobox.bentobox.api.flags.FlagListener; import world.bentobox.bentobox.api.flags.FlagListener;
import world.bentobox.bentobox.lists.Flags; import world.bentobox.bentobox.lists.Flags;
@ -71,7 +70,6 @@ public class PlaceBlocksListener extends FlagListener
@EventHandler(priority = EventPriority.LOWEST, ignoreCancelled = true) @EventHandler(priority = EventPriority.LOWEST, ignoreCancelled = true)
public void onPlayerHitItemFrame(PlayerInteractEntityEvent e) public void onPlayerHitItemFrame(PlayerInteractEntityEvent e)
{ {
BentoBox.getInstance().logDebug(e.getEventName());
if (e.getRightClicked().getType().equals(EntityType.ITEM_FRAME) || if (e.getRightClicked().getType().equals(EntityType.ITEM_FRAME) ||
e.getRightClicked().getType().equals(EntityType.GLOW_ITEM_FRAME)) e.getRightClicked().getType().equals(EntityType.GLOW_ITEM_FRAME))
{ {