From 898306aed45ff62127232854ebb7c5cf29e6512a Mon Sep 17 00:00:00 2001 From: songoda Date: Sat, 1 Feb 2020 21:56:11 -0500 Subject: [PATCH 1/3] Attempt 2 for 1.8 --- .../src/com/songoda/epicbosses/targeting/TargetHandler.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/plugin-modules/Core/src/com/songoda/epicbosses/targeting/TargetHandler.java b/plugin-modules/Core/src/com/songoda/epicbosses/targeting/TargetHandler.java index 2f53834..9eb8c58 100644 --- a/plugin-modules/Core/src/com/songoda/epicbosses/targeting/TargetHandler.java +++ b/plugin-modules/Core/src/com/songoda/epicbosses/targeting/TargetHandler.java @@ -1,5 +1,6 @@ package com.songoda.epicbosses.targeting; +import com.songoda.core.compatibility.ServerVersion; import com.songoda.epicbosses.EpicBosses; import com.songoda.epicbosses.holder.IActiveHolder; import com.songoda.epicbosses.managers.BossTargetManager; @@ -75,9 +76,9 @@ public abstract class TargetHandler implements ITa getHolder().getLivingEntityMap().values().forEach(uuid -> { LivingEntity livingEntity = (LivingEntity) ServerUtils.get().getEntity(uuid); if (livingEntity != null && !livingEntity.isDead()) { - if (livingEntity instanceof Mob) + if (ServerVersion.isServerVersionAtLeast(ServerVersion.V1_12) && livingEntity instanceof Mob) ((Mob) livingEntity).setTarget(newTarget); - else + else if (livingEntity instanceof Creature) ((Creature) livingEntity).setTarget(newTarget); } }); From 5156e3ae7ca7bc9e08d6e8ab261582ee75b37a55 Mon Sep 17 00:00:00 2001 From: Brianna Date: Tue, 11 Feb 2020 16:07:31 -0500 Subject: [PATCH 2/3] Added %player% variable to the death event command. --- .../epicbosses/listeners/after/BossDeathListener.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/plugin-modules/Core/src/com/songoda/epicbosses/listeners/after/BossDeathListener.java b/plugin-modules/Core/src/com/songoda/epicbosses/listeners/after/BossDeathListener.java index 5e703f1..31a012a 100644 --- a/plugin-modules/Core/src/com/songoda/epicbosses/listeners/after/BossDeathListener.java +++ b/plugin-modules/Core/src/com/songoda/epicbosses/listeners/after/BossDeathListener.java @@ -90,7 +90,10 @@ public class BossDeathListener implements Listener { if (commands != null) { if (activeBossHolder.getSpawningPlayerName() != null) commands.replaceAll(s -> s.replace("{spawner}", activeBossHolder.getSpawningPlayerName())); - if (event.getKiller() != null) commands.replaceAll(s -> s.replace("{killer}", event.getKiller().getName())); + if (event.getKiller() != null) { + commands.replaceAll(s -> s.replace("{killer}", event.getKiller().getName())); + commands.replaceAll(s -> s.replace("%player%", event.getKiller().getName())); + } commands.forEach(serverUtils::sendConsoleCommand); } From ee1c85fb5602cc7db5533c30b5d0e1c8d313b7f6 Mon Sep 17 00:00:00 2001 From: Brianna Date: Tue, 11 Feb 2020 15:16:12 -0500 Subject: [PATCH 3/3] version 1.2.8 --- api-modules/FactionsM/pom.xml | 2 +- api-modules/FactionsOne/pom.xml | 2 +- api-modules/FactionsUUID/pom.xml | 2 +- api-modules/LegacyFactions/pom.xml | 2 +- plugin-modules/Core/pom.xml | 2 +- plugin-modules/FactionHelper/pom.xml | 2 +- pom.xml | 4 ++-- 7 files changed, 8 insertions(+), 8 deletions(-) diff --git a/api-modules/FactionsM/pom.xml b/api-modules/FactionsM/pom.xml index 88dd70b..13ecb69 100644 --- a/api-modules/FactionsM/pom.xml +++ b/api-modules/FactionsM/pom.xml @@ -5,7 +5,7 @@ EpicBosses com.songoda.epicbosses - 1.2.7 + 1.2.8 ../../pom.xml 4.0.0 diff --git a/api-modules/FactionsOne/pom.xml b/api-modules/FactionsOne/pom.xml index 0afccc4..0ecf43e 100644 --- a/api-modules/FactionsOne/pom.xml +++ b/api-modules/FactionsOne/pom.xml @@ -5,7 +5,7 @@ EpicBosses com.songoda.epicbosses - 1.2.7 + 1.2.8 ../../pom.xml 4.0.0 diff --git a/api-modules/FactionsUUID/pom.xml b/api-modules/FactionsUUID/pom.xml index 8ace7c4..ccba6a9 100644 --- a/api-modules/FactionsUUID/pom.xml +++ b/api-modules/FactionsUUID/pom.xml @@ -5,7 +5,7 @@ EpicBosses com.songoda.epicbosses - 1.2.7 + 1.2.8 ../../pom.xml 4.0.0 diff --git a/api-modules/LegacyFactions/pom.xml b/api-modules/LegacyFactions/pom.xml index 2a20038..39c9e2b 100644 --- a/api-modules/LegacyFactions/pom.xml +++ b/api-modules/LegacyFactions/pom.xml @@ -5,7 +5,7 @@ EpicBosses com.songoda.epicbosses - 1.2.7 + 1.2.8 ../../pom.xml 4.0.0 diff --git a/plugin-modules/Core/pom.xml b/plugin-modules/Core/pom.xml index bef21f4..1e3b045 100644 --- a/plugin-modules/Core/pom.xml +++ b/plugin-modules/Core/pom.xml @@ -5,7 +5,7 @@ EpicBosses com.songoda.epicbosses - 1.2.7 + 1.2.8 ../../pom.xml 4.0.0 diff --git a/plugin-modules/FactionHelper/pom.xml b/plugin-modules/FactionHelper/pom.xml index 7f7a859..d3a7462 100644 --- a/plugin-modules/FactionHelper/pom.xml +++ b/plugin-modules/FactionHelper/pom.xml @@ -5,7 +5,7 @@ EpicBosses com.songoda.epicbosses - 1.2.7 + 1.2.8 ../../pom.xml 4.0.0 diff --git a/pom.xml b/pom.xml index 2bd0a7a..5045caa 100644 --- a/pom.xml +++ b/pom.xml @@ -4,7 +4,7 @@ com.songoda.epicbosses EpicBosses pom - 1.2.7 + 1.2.8 api-modules/FactionsM @@ -16,7 +16,7 @@ - 1.2.7 + 1.2.8 EpicBosses com.songoda.epicbosses.EpicBosses Songoda