From b3bc98b1871243957045205a59d8ea093ef7f7b5 Mon Sep 17 00:00:00 2001 From: YuRaNnNzZZ Date: Tue, 8 Oct 2024 03:36:40 +0300 Subject: [PATCH] =?UTF-8?q?AMD=20User=20=E2=80=94=20=D0=A1=D0=B5=D0=B3?= =?UTF-8?q?=D0=BE=D0=B4=D0=BD=D1=8F,=20=D0=B2=203:32=20=D0=AF=20=D1=81?= =?UTF-8?q?=D0=BF=D0=B5=D1=86=D0=B8=D0=B0=D0=BB=D1=8C=D0=BD=D0=BE=20=D1=8D?= =?UTF-8?q?=D1=82=D0=BE=20=D1=84=D0=B8=D0=BA=D1=81=D0=B8=D0=BB=20=D0=9D?= =?UTF-8?q?=D0=BE=20=D1=81=D0=BF=D0=B0=D1=81=D0=B8=D0=B1=D0=BE=20=D1=87?= =?UTF-8?q?=D1=82=D0=BE=20=D1=83=D0=B1=D1=80=D0=B0=D0=BB=D0=B8=20fakeplaye?= =?UTF-8?q?r=20=D0=B1=D0=B0=D0=B7=D1=83=20=D0=A2=D0=B5=D0=BF=D0=B5=D1=80?= =?UTF-8?q?=D1=8C=20=D1=8F=20=D1=85=D0=B7=20=D0=BA=D0=B0=D0=BA=20=D1=8D?= =?UTF-8?q?=D1=82=D0=BE=20=D1=84=D0=B8=D0=BA=D1=81=D0=B8=D1=82=D1=8C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../mc/otm/data/condition/KilledByRealPlayerOrIndirectly.kt | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/main/kotlin/ru/dbotthepony/mc/otm/data/condition/KilledByRealPlayerOrIndirectly.kt b/src/main/kotlin/ru/dbotthepony/mc/otm/data/condition/KilledByRealPlayerOrIndirectly.kt index 624ad09fb..ba2834900 100644 --- a/src/main/kotlin/ru/dbotthepony/mc/otm/data/condition/KilledByRealPlayerOrIndirectly.kt +++ b/src/main/kotlin/ru/dbotthepony/mc/otm/data/condition/KilledByRealPlayerOrIndirectly.kt @@ -6,6 +6,7 @@ import net.minecraft.world.level.storage.loot.parameters.LootContextParams import net.minecraft.world.level.storage.loot.predicates.InvertedLootItemCondition import net.minecraft.world.level.storage.loot.predicates.LootItemCondition import net.minecraft.world.level.storage.loot.predicates.LootItemConditionType +import net.neoforged.neoforge.common.util.FakePlayer import ru.dbotthepony.mc.otm.NULLABLE_MINECRAFT_SERVER import ru.dbotthepony.mc.otm.data.get import ru.dbotthepony.mc.otm.registry.MLootItemConditions @@ -22,12 +23,12 @@ object KilledByRealPlayerOrIndirectly : LootItemCondition, LootItemCondition.Bui if (killer != null) { val owner = killer.owner - if (owner != null /*&& owner !is FakePlayer*/) { + if (owner != null && owner !is FakePlayer) { return true } val ply = NULLABLE_MINECRAFT_SERVER?.playerList?.getPlayer(killer.ownerUUID ?: return false) - return ply != null //&& ply !is FakePlayer + return ply != null && ply !is FakePlayer } }