Remap CraftBukkit to Mojang+Yarn Mappings
By: Initial Source <noreply+automated@papermc.io>
This commit is contained in:
parent
a265d64138
commit
30e4583dbe
1780 changed files with 44628 additions and 41274 deletions
|
@ -0,0 +1,15 @@
|
|||
--- a/net/minecraft/stats/StatsCounter.java
|
||||
+++ b/net/minecraft/stats/StatsCounter.java
|
||||
@@ -16,6 +16,12 @@
|
||||
public void increment(Player player, Stat<?> stat, int value) {
|
||||
int j = (int) Math.min((long) this.getValue(stat) + (long) value, 2147483647L);
|
||||
|
||||
+ // CraftBukkit start - fire Statistic events
|
||||
+ org.bukkit.event.Cancellable cancellable = org.bukkit.craftbukkit.event.CraftEventFactory.handleStatisticsIncrease(player, stat, this.getValue(stat), j);
|
||||
+ if (cancellable != null && cancellable.isCancelled()) {
|
||||
+ return;
|
||||
+ }
|
||||
+ // CraftBukkit end
|
||||
this.setValue(player, stat, j);
|
||||
}
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue