diff --git a/src/main/java/world/bentobox/bentobox/blueprints/dataobjects/BlueprintEntity.java b/src/main/java/world/bentobox/bentobox/blueprints/dataobjects/BlueprintEntity.java index bf6257d59..4c4eb1de1 100644 --- a/src/main/java/world/bentobox/bentobox/blueprints/dataobjects/BlueprintEntity.java +++ b/src/main/java/world/bentobox/bentobox/blueprints/dataobjects/BlueprintEntity.java @@ -286,6 +286,9 @@ public class BlueprintEntity { * @return the mythicMobsRecord */ public MythicMobRecord getMythicMobsRecord() { + if (this.MMtype == null || this.MMLevel == null || this.MMpower == null || this.MMStance == null) { + return null; + } return new MythicMobRecord(this.MMtype, this.getCustomName(), this.MMLevel, this.MMpower, this.MMStance); } diff --git a/src/main/java/world/bentobox/bentobox/hooks/MythicMobsHook.java b/src/main/java/world/bentobox/bentobox/hooks/MythicMobsHook.java index 5db726a27..616ea0622 100644 --- a/src/main/java/world/bentobox/bentobox/hooks/MythicMobsHook.java +++ b/src/main/java/world/bentobox/bentobox/hooks/MythicMobsHook.java @@ -55,6 +55,9 @@ public class MythicMobsHook extends Hook { * @return true if spawn is successful */ public boolean spawnMythicMob(MythicMobRecord mmr, Location spawnLocation) { + if (!this.isPluginAvailable()) { + return false; + } return MythicBukkit.inst().getMobManager().getMythicMob(mmr.type()).map(mob -> { // A delay is required before spawning, I assume because the blocks are pasted using NMS Bukkit.getScheduler().runTaskLater(getPlugin(), () -> {