2019-06-06 17:36:57 +02:00
|
|
|
From 8f33f91b12c53933a978bf85f91b8176d7043416 Mon Sep 17 00:00:00 2001
|
2018-01-21 19:23:34 +01:00
|
|
|
From: BillyGalbreath <Blake.Galbreath@GMail.com>
|
|
|
|
Date: Fri, 19 Jan 2018 08:15:29 -0600
|
|
|
|
Subject: [PATCH] PlayerAdvancementCriterionGrantEvent
|
|
|
|
|
|
|
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/AdvancementDataPlayer.java b/src/main/java/net/minecraft/server/AdvancementDataPlayer.java
|
2019-06-06 17:36:57 +02:00
|
|
|
index c254b73992..a284a940ef 100644
|
2018-01-21 19:23:34 +01:00
|
|
|
--- a/src/main/java/net/minecraft/server/AdvancementDataPlayer.java
|
|
|
|
+++ b/src/main/java/net/minecraft/server/AdvancementDataPlayer.java
|
2019-04-28 19:59:47 +02:00
|
|
|
@@ -276,6 +276,12 @@ public class AdvancementDataPlayer {
|
2018-01-21 19:23:34 +01:00
|
|
|
boolean flag1 = advancementprogress.isDone();
|
|
|
|
|
|
|
|
if (advancementprogress.a(s)) {
|
|
|
|
+ // Paper start
|
|
|
|
+ if (!new com.destroystokyo.paper.event.player.PlayerAdvancementCriterionGrantEvent(this.player.getBukkitEntity(), advancement.bukkit, s).callEvent()) {
|
|
|
|
+ advancementprogress.b(s);
|
|
|
|
+ return false;
|
|
|
|
+ }
|
|
|
|
+ // Paper end
|
|
|
|
this.d(advancement);
|
|
|
|
this.i.add(advancement);
|
|
|
|
flag = true;
|
|
|
|
--
|
2019-03-20 02:46:00 +01:00
|
|
|
2.21.0
|
2018-01-21 19:23:34 +01:00
|
|
|
|