Updated Upstream (Bukkit/CraftBukkit/Spigot) (#5601)
Dieser Commit ist enthalten in:
Ursprung
b0a4f353b9
Commit
aeb6e7dd25
@ -3375,10 +3375,10 @@ index 2a145d851ce30360aa39549745bd87590c034584..00000000000000000000000000000000
|
||||
- // Spigot end
|
||||
-}
|
||||
diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java
|
||||
index 90c8c3eb8bc3285bf7a51da89015304e49e6602c..344aecc097c5e12476d2be53019145812b028914 100644
|
||||
index da1b5b5253c0ac0abe1019096166e6c76a50e699..586fd9ebd02039ebd2c071cbbbf60f24879f96b9 100644
|
||||
--- a/src/main/java/org/bukkit/entity/Player.java
|
||||
+++ b/src/main/java/org/bukkit/entity/Player.java
|
||||
@@ -1353,7 +1353,14 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
@@ -1368,7 +1368,14 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
*/
|
||||
public void sendMessage(@NotNull net.md_5.bungee.api.ChatMessageType position, @Nullable UUID sender, @NotNull net.md_5.bungee.api.chat.BaseComponent... components) {
|
||||
throw new UnsupportedOperationException("Not supported yet.");
|
||||
|
@ -1332,7 +1332,7 @@ index b71530e94569f8ade829e655e3a89ec70215ea39..b21fe6c631d5a6cd52f133786270c8f5
|
||||
+ // Paper end
|
||||
}
|
||||
diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java
|
||||
index 344aecc097c5e12476d2be53019145812b028914..c5e7e037493ffe1f1764c3ad5d3e12bfac498cb2 100644
|
||||
index 586fd9ebd02039ebd2c071cbbbf60f24879f96b9..171e2663301f654258dbd772a57688b5a2f8469c 100644
|
||||
--- a/src/main/java/org/bukkit/entity/Player.java
|
||||
+++ b/src/main/java/org/bukkit/entity/Player.java
|
||||
@@ -30,7 +30,28 @@ import org.jetbrains.annotations.Nullable;
|
||||
@ -1580,9 +1580,9 @@ index 344aecc097c5e12476d2be53019145812b028914..c5e7e037493ffe1f1764c3ad5d3e12bf
|
||||
+ @NotNull java.util.Locale locale();
|
||||
+ // Paper end
|
||||
/**
|
||||
* Gets the player's current locale.
|
||||
* Gets the player's estimated ping in milliseconds.
|
||||
*
|
||||
@@ -1230,8 +1359,10 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
@@ -1245,8 +1374,10 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
* they wish.
|
||||
*
|
||||
* @return the player's locale
|
||||
@ -1593,7 +1593,7 @@ index 344aecc097c5e12476d2be53019145812b028914..c5e7e037493ffe1f1764c3ad5d3e12bf
|
||||
public String getLocale();
|
||||
|
||||
/**
|
||||
@@ -1249,6 +1380,14 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
@@ -1264,6 +1395,14 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
*/
|
||||
public void openBook(@NotNull ItemStack book);
|
||||
|
||||
@ -1608,7 +1608,7 @@ index 344aecc097c5e12476d2be53019145812b028914..c5e7e037493ffe1f1764c3ad5d3e12bf
|
||||
// Spigot start
|
||||
public class Spigot extends Entity.Spigot {
|
||||
|
||||
@@ -1303,11 +1442,13 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
@@ -1318,11 +1457,13 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
throw new UnsupportedOperationException("Not supported yet.");
|
||||
}
|
||||
|
||||
@ -1622,7 +1622,7 @@ index 344aecc097c5e12476d2be53019145812b028914..c5e7e037493ffe1f1764c3ad5d3e12bf
|
||||
@Override
|
||||
public void sendMessage(@NotNull net.md_5.bungee.api.chat.BaseComponent... components) {
|
||||
throw new UnsupportedOperationException("Not supported yet.");
|
||||
@@ -1318,7 +1459,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
@@ -1333,7 +1474,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
*
|
||||
* @param position the screen position
|
||||
* @param component the components to send
|
||||
@ -1632,7 +1632,7 @@ index 344aecc097c5e12476d2be53019145812b028914..c5e7e037493ffe1f1764c3ad5d3e12bf
|
||||
public void sendMessage(@NotNull net.md_5.bungee.api.ChatMessageType position, @NotNull net.md_5.bungee.api.chat.BaseComponent component) {
|
||||
throw new UnsupportedOperationException("Not supported yet.");
|
||||
}
|
||||
@@ -1328,7 +1471,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
@@ -1343,7 +1486,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
*
|
||||
* @param position the screen position
|
||||
* @param components the components to send
|
||||
@ -1642,7 +1642,7 @@ index 344aecc097c5e12476d2be53019145812b028914..c5e7e037493ffe1f1764c3ad5d3e12bf
|
||||
public void sendMessage(@NotNull net.md_5.bungee.api.ChatMessageType position, @NotNull net.md_5.bungee.api.chat.BaseComponent... components) {
|
||||
throw new UnsupportedOperationException("Not supported yet.");
|
||||
}
|
||||
@@ -1339,7 +1484,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
@@ -1354,7 +1499,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
* @param position the screen position
|
||||
* @param sender the sender of the message
|
||||
* @param component the components to send
|
||||
@ -1652,7 +1652,7 @@ index 344aecc097c5e12476d2be53019145812b028914..c5e7e037493ffe1f1764c3ad5d3e12bf
|
||||
public void sendMessage(@NotNull net.md_5.bungee.api.ChatMessageType position, @Nullable UUID sender, @NotNull net.md_5.bungee.api.chat.BaseComponent component) {
|
||||
throw new UnsupportedOperationException("Not supported yet.");
|
||||
}
|
||||
@@ -1350,7 +1497,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
@@ -1365,7 +1512,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
* @param position the screen position
|
||||
* @param sender the sender of the message
|
||||
* @param components the components to send
|
||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] Player affects spawning API
|
||||
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java
|
||||
index c5e7e037493ffe1f1764c3ad5d3e12bfac498cb2..e3a23cef93df2bbb2f27f87150bc1dbf7fd051b5 100644
|
||||
index 171e2663301f654258dbd772a57688b5a2f8469c..76ac0b20842002ce1b593e338bea98483e7080ac 100644
|
||||
--- a/src/main/java/org/bukkit/entity/Player.java
|
||||
+++ b/src/main/java/org/bukkit/entity/Player.java
|
||||
@@ -1365,6 +1365,22 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
@@ -1380,6 +1380,22 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
@Deprecated // Paper
|
||||
public String getLocale();
|
||||
|
||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] Add player view distance API
|
||||
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java
|
||||
index e3a23cef93df2bbb2f27f87150bc1dbf7fd051b5..1ce07f925acb550c379e4deb1a013bcbe5701a8a 100644
|
||||
index 76ac0b20842002ce1b593e338bea98483e7080ac..f34601480a3b3069c30c52d258a35a2a79c981fb 100644
|
||||
--- a/src/main/java/org/bukkit/entity/Player.java
|
||||
+++ b/src/main/java/org/bukkit/entity/Player.java
|
||||
@@ -1379,6 +1379,28 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
@@ -1394,6 +1394,28 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
* @param affects Whether the player can affect mob spawning
|
||||
*/
|
||||
public void setAffectsSpawning(boolean affects);
|
||||
|
@ -5,7 +5,7 @@ Subject: [PATCH] Complete resource pack API
|
||||
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java
|
||||
index a3d3cefb3739f3cb787befb03a5ddc38fb343849..38f47517d5391696c52d8848c21dee40033458e6 100644
|
||||
index 769ad98fd7a6a866b320e1ccffd7962228d564cf..ddbe5734ac0f905b0c388e30f17a281530b82262 100644
|
||||
--- a/src/main/java/org/bukkit/entity/Player.java
|
||||
+++ b/src/main/java/org/bukkit/entity/Player.java
|
||||
@@ -1124,7 +1124,9 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
@ -18,7 +18,7 @@ index a3d3cefb3739f3cb787befb03a5ddc38fb343849..38f47517d5391696c52d8848c21dee40
|
||||
public void setResourcePack(@NotNull String url);
|
||||
|
||||
/**
|
||||
@@ -1586,6 +1588,60 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
@@ -1601,6 +1603,60 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
default net.kyori.adventure.text.event.HoverEvent<net.kyori.adventure.text.event.HoverEvent.ShowEntity> asHoverEvent(final @NotNull java.util.function.UnaryOperator<net.kyori.adventure.text.event.HoverEvent.ShowEntity> op) {
|
||||
return net.kyori.adventure.text.event.HoverEvent.showEntity(op.apply(net.kyori.adventure.text.event.HoverEvent.ShowEntity.of(this.getType().getKey(), this.getUniqueId(), this.displayName())));
|
||||
}
|
||||
|
@ -5,7 +5,7 @@ Subject: [PATCH] Add String based Action Bar API
|
||||
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java
|
||||
index 38f47517d5391696c52d8848c21dee40033458e6..f5d9899ec0788019ba14f15dc0f290abe4b3cfa8 100644
|
||||
index ddbe5734ac0f905b0c388e30f17a281530b82262..6bb0bb8052c12c5a215abf4bd9602fbefc769523 100644
|
||||
--- a/src/main/java/org/bukkit/entity/Player.java
|
||||
+++ b/src/main/java/org/bukkit/entity/Player.java
|
||||
@@ -3,6 +3,7 @@ package org.bukkit.entity;
|
||||
@ -68,7 +68,7 @@ index 38f47517d5391696c52d8848c21dee40033458e6..f5d9899ec0788019ba14f15dc0f290ab
|
||||
public default void sendMessage(net.md_5.bungee.api.ChatMessageType position, net.md_5.bungee.api.chat.BaseComponent... components) {
|
||||
spigot().sendMessage(position, components);
|
||||
}
|
||||
@@ -1713,6 +1749,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
@@ -1728,6 +1764,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
/**
|
||||
* Sends the component to the specified screen position of this player
|
||||
*
|
||||
@ -76,7 +76,7 @@ index 38f47517d5391696c52d8848c21dee40033458e6..f5d9899ec0788019ba14f15dc0f290ab
|
||||
* @param position the screen position
|
||||
* @param component the components to send
|
||||
* @deprecated use {@code sendMessage} methods that accept {@link net.kyori.adventure.text.Component}
|
||||
@@ -1725,6 +1762,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
@@ -1740,6 +1777,7 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
/**
|
||||
* Sends an array of components as a single message to the specified screen position of this player
|
||||
*
|
||||
|
@ -6,7 +6,7 @@ Subject: [PATCH] Player.setPlayerProfile API
|
||||
This can be useful for changing name or skins after a player has logged in.
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java
|
||||
index 3063f917f34a28e347daac54bc73e000d6771fed..30b97d4e20f5d89533f0aebd2245fa7578c97420 100644
|
||||
index 9a262d412b2762a33a60b1e8762a7d9c9c3f933d..3ae4d670059f80bd057870a37f4025261e397dfa 100644
|
||||
--- a/src/main/java/org/bukkit/entity/Player.java
|
||||
+++ b/src/main/java/org/bukkit/entity/Player.java
|
||||
@@ -4,6 +4,7 @@ import java.net.InetSocketAddress;
|
||||
@ -17,7 +17,7 @@ index 3063f917f34a28e347daac54bc73e000d6771fed..30b97d4e20f5d89533f0aebd2245fa75
|
||||
import org.bukkit.DyeColor;
|
||||
import org.bukkit.Effect;
|
||||
import org.bukkit.GameMode;
|
||||
@@ -1699,6 +1700,20 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
@@ -1714,6 +1715,20 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
* was {@link org.bukkit.event.player.PlayerResourcePackStatusEvent.Status#SUCCESSFULLY_LOADED}
|
||||
*/
|
||||
boolean hasResourcePack();
|
||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] Expose attack cooldown methods for Player
|
||||
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java
|
||||
index fe4b301e96f58cc41fb9789f030e00645c9a7e60..6253b43490cac138edbb59ce0647d3f37314e435 100644
|
||||
index 257bf4a75393d1e25839bcae0ca5551ee832c627..ec87c78d0f9379511467b6d13b9cdfa4c19d15ca 100644
|
||||
--- a/src/main/java/org/bukkit/entity/Player.java
|
||||
+++ b/src/main/java/org/bukkit/entity/Player.java
|
||||
@@ -1874,6 +1874,26 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
@@ -1889,6 +1889,26 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
* @param profile The new profile to use
|
||||
*/
|
||||
void setPlayerProfile(@NotNull PlayerProfile profile);
|
||||
|
@ -176,7 +176,7 @@ index 0000000000000000000000000000000000000000..f7f171c4ee0b8339b2f8fbe82442d65f
|
||||
+ }
|
||||
+}
|
||||
diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java
|
||||
index 6253b43490cac138edbb59ce0647d3f37314e435..e6b5969df34f096cec84ebb46061cb956eba4bab 100644
|
||||
index ec87c78d0f9379511467b6d13b9cdfa4c19d15ca..2530c811f52f51d6338900221b4681c952c1c752 100644
|
||||
--- a/src/main/java/org/bukkit/entity/Player.java
|
||||
+++ b/src/main/java/org/bukkit/entity/Player.java
|
||||
@@ -2,6 +2,7 @@ package org.bukkit.entity;
|
||||
@ -187,7 +187,7 @@ index 6253b43490cac138edbb59ce0647d3f37314e435..e6b5969df34f096cec84ebb46061cb95
|
||||
import com.destroystokyo.paper.Title; // Paper
|
||||
import net.kyori.adventure.text.Component;
|
||||
import com.destroystokyo.paper.profile.PlayerProfile; // Paper
|
||||
@@ -1894,6 +1895,12 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
@@ -1909,6 +1910,12 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
* Reset the cooldown counter to 0, effectively starting the cooldown period.
|
||||
*/
|
||||
void resetCooldown();
|
||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] Brand support
|
||||
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java
|
||||
index e6b5969df34f096cec84ebb46061cb956eba4bab..61c572fe69cf08aaa36a26ebed21127c14309bf4 100644
|
||||
index 2530c811f52f51d6338900221b4681c952c1c752..828b2b0538d4f936bee57d9fca55774723e13970 100644
|
||||
--- a/src/main/java/org/bukkit/entity/Player.java
|
||||
+++ b/src/main/java/org/bukkit/entity/Player.java
|
||||
@@ -2029,6 +2029,16 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
@@ -2044,6 +2044,16 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
// Paper end
|
||||
}
|
||||
|
||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] Player elytra boost API
|
||||
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java
|
||||
index 61c572fe69cf08aaa36a26ebed21127c14309bf4..5bdc48b533833f626a012b675c9c58f8b00b2400 100644
|
||||
index 828b2b0538d4f936bee57d9fca55774723e13970..7aa9fb852dce23c53fee80e97e0dcdb278ae82ba 100644
|
||||
--- a/src/main/java/org/bukkit/entity/Player.java
|
||||
+++ b/src/main/java/org/bukkit/entity/Player.java
|
||||
@@ -1901,6 +1901,19 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
@@ -1916,6 +1916,19 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
*/
|
||||
@NotNull
|
||||
<T> T getClientOption(@NotNull ClientOption<T> option);
|
||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] Add sendOpLevel API
|
||||
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java
|
||||
index 5bdc48b533833f626a012b675c9c58f8b00b2400..8a1e35952ae84ae1e41a2b7783e88eab52bd274c 100644
|
||||
index 7aa9fb852dce23c53fee80e97e0dcdb278ae82ba..68a03821a5f06308a9c51fdf107d3924c44886c8 100644
|
||||
--- a/src/main/java/org/bukkit/entity/Player.java
|
||||
+++ b/src/main/java/org/bukkit/entity/Player.java
|
||||
@@ -1914,6 +1914,17 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
@@ -1929,6 +1929,17 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
*/
|
||||
@Nullable
|
||||
Firework boostElytra(@NotNull ItemStack firework);
|
||||
|
@ -1,49 +0,0 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Aikar <aikar@aikar.co>
|
||||
Date: Sat, 16 Jan 2021 14:00:16 -0500
|
||||
Subject: [PATCH] Make ProjectileHitEvent Cancellable
|
||||
|
||||
Allows cancelling things like detonating TNT from Fire Arrows
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/event/entity/ProjectileHitEvent.java b/src/main/java/org/bukkit/event/entity/ProjectileHitEvent.java
|
||||
index 809c1098c16fe52eda47ae2335afab30e36746b2..000c9967e008d3340a08c4ee727a5d2de27dedcc 100644
|
||||
--- a/src/main/java/org/bukkit/event/entity/ProjectileHitEvent.java
|
||||
+++ b/src/main/java/org/bukkit/event/entity/ProjectileHitEvent.java
|
||||
@@ -4,6 +4,7 @@ import org.bukkit.block.Block;
|
||||
import org.bukkit.block.BlockFace;
|
||||
import org.bukkit.entity.Entity;
|
||||
import org.bukkit.entity.Projectile;
|
||||
+import org.bukkit.event.Cancellable;
|
||||
import org.bukkit.event.HandlerList;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
@@ -11,11 +12,28 @@ import org.jetbrains.annotations.Nullable;
|
||||
/**
|
||||
* Called when a projectile hits an object
|
||||
*/
|
||||
-public class ProjectileHitEvent extends EntityEvent {
|
||||
+public class ProjectileHitEvent extends EntityEvent implements Cancellable { // Paper
|
||||
private static final HandlerList handlers = new HandlerList();
|
||||
private final Entity hitEntity;
|
||||
private final Block hitBlock;
|
||||
private final BlockFace hitFace;
|
||||
+ // Paper start - make cancellable
|
||||
+ private boolean canceled;
|
||||
+ /**
|
||||
+ * @return If the arrow activating a block should be cancelled
|
||||
+ */
|
||||
+ public boolean isCancelled() {
|
||||
+ return canceled;
|
||||
+ }
|
||||
+
|
||||
+ /**
|
||||
+ * Whether or not to cancel any behavior that would occur from the arrow hitting the block
|
||||
+ * @param cancel true if you wish to cancel this event
|
||||
+ */
|
||||
+ public void setCancelled(boolean cancel) {
|
||||
+ canceled = cancel;
|
||||
+ }
|
||||
+ // Paper end
|
||||
|
||||
public ProjectileHitEvent(@NotNull final Projectile projectile) {
|
||||
this(projectile, null, null);
|
@ -6,7 +6,7 @@ Subject: [PATCH] Return chat component with empty text instead of throwing
|
||||
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/inventory/InventoryView.java b/src/main/java/org/bukkit/inventory/InventoryView.java
|
||||
index a4e3d526db2d17dc923cbe82e53d3c902d61e1f3..2448e70d75ae7a678c6befac4506c103edb78875 100644
|
||||
index 664de64b020cf9090a2fbee0afe2bfaf150adc3c..b06995aa57aa9cba0bb59f1d26d81015619a08e6 100644
|
||||
--- a/src/main/java/org/bukkit/inventory/InventoryView.java
|
||||
+++ b/src/main/java/org/bukkit/inventory/InventoryView.java
|
||||
@@ -450,7 +450,7 @@ public abstract class InventoryView {
|
@ -6,7 +6,7 @@ Subject: [PATCH] EntityMoveEvent
|
||||
|
||||
diff --git a/src/main/java/io/papermc/paper/event/entity/EntityMoveEvent.java b/src/main/java/io/papermc/paper/event/entity/EntityMoveEvent.java
|
||||
new file mode 100644
|
||||
index 0000000000000000000000000000000000000000..a5c017dc0392a4bbdccf33d9e963f96cbfbc0d9a
|
||||
index 0000000000000000000000000000000000000000..fae0b1daf733e85d8f691f5ef934b8c0b51db194
|
||||
--- /dev/null
|
||||
+++ b/src/main/java/io/papermc/paper/event/entity/EntityMoveEvent.java
|
||||
@@ -0,0 +1,140 @@
|
@ -5,7 +5,7 @@ Subject: [PATCH] Expose Tracked Players
|
||||
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/entity/Player.java b/src/main/java/org/bukkit/entity/Player.java
|
||||
index 8a1e35952ae84ae1e41a2b7783e88eab52bd274c..2ea531eaef8c455fdd503f0c0258813fe9136085 100644
|
||||
index 68a03821a5f06308a9c51fdf107d3924c44886c8..34b51466ffb281b05f531b3f7deda245ae7fd96a 100644
|
||||
--- a/src/main/java/org/bukkit/entity/Player.java
|
||||
+++ b/src/main/java/org/bukkit/entity/Player.java
|
||||
@@ -1,6 +1,7 @@
|
||||
@ -16,7 +16,7 @@ index 8a1e35952ae84ae1e41a2b7783e88eab52bd274c..2ea531eaef8c455fdd503f0c0258813f
|
||||
import java.util.UUID;
|
||||
import com.destroystokyo.paper.ClientOption; // Paper
|
||||
import com.destroystokyo.paper.Title; // Paper
|
||||
@@ -1927,6 +1928,14 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
@@ -1942,6 +1943,14 @@ public interface Player extends HumanEntity, Conversable, OfflinePlayer, PluginM
|
||||
void sendOpLevel(byte level);
|
||||
// Paper end
|
||||
|
@ -5,7 +5,7 @@ Subject: [PATCH] Add Block#isValidTool
|
||||
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/block/Block.java b/src/main/java/org/bukkit/block/Block.java
|
||||
index a7bc431ea8e25abdc1bc575eb73d26b37a2049b3..85ff6ce3bf75ab78f066a508d130def5913fff0e 100644
|
||||
index 181658c679d306ffc4ad45259494571ee224ef47..08e6f1741685f54506c8a4ff29bbd30f62cf8e45 100644
|
||||
--- a/src/main/java/org/bukkit/block/Block.java
|
||||
+++ b/src/main/java/org/bukkit/block/Block.java
|
||||
@@ -218,6 +218,15 @@ public interface Block extends Metadatable {
|
@ -50,7 +50,7 @@ index a79fa08b9e6fb924b2da933eb6e4b365d14d938d..f3e27d2d02a9407bb1b091b8c1125ad5
|
||||
* Gets the map from the given item ID.
|
||||
*
|
||||
diff --git a/src/main/java/org/bukkit/World.java b/src/main/java/org/bukkit/World.java
|
||||
index 3c50a10fda033c139993ed5465a92f95d5b10c17..064497506e6a5ab89ca43b99968ca79d51d67c46 100644
|
||||
index ced33fc6de6bfa2767123131d532e7ae9ef3a5be..98512bddbb0c8bd6a3f487c60b1ec77b274b991e 100644
|
||||
--- a/src/main/java/org/bukkit/World.java
|
||||
+++ b/src/main/java/org/bukkit/World.java
|
||||
@@ -43,7 +43,7 @@ import org.jetbrains.annotations.Nullable;
|
@ -6,7 +6,7 @@ Subject: [PATCH] Added PlayerBedFailEnterEvent
|
||||
|
||||
diff --git a/src/main/java/io/papermc/paper/event/player/PlayerBedFailEnterEvent.java b/src/main/java/io/papermc/paper/event/player/PlayerBedFailEnterEvent.java
|
||||
new file mode 100644
|
||||
index 0000000000000000000000000000000000000000..b7a8c8f0a5ba1b4d8e3d7a6f9381cb9a81315336
|
||||
index 0000000000000000000000000000000000000000..e0028733615ddc9e34359f673ca1c3cadb133948
|
||||
--- /dev/null
|
||||
+++ b/src/main/java/io/papermc/paper/event/player/PlayerBedFailEnterEvent.java
|
||||
@@ -0,0 +1,119 @@
|
@ -278,10 +278,10 @@ index 1c500e1193296f92f03a94e2cf085b215daaad6c..51ef4adf66c1e21093e63ab46fa47e66
|
||||
}
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/level/WorldServer.java b/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
index 1eeb9b9ca01357ae32358737a12fdc2e8cd389d8..634f34b8b88a1ef86cebf3126da9989a88707711 100644
|
||||
index 144c80a4f3f827d5ee0a9220d12c49ee9aa3f096..7f9a1d64d123ce54608497a0e0a37d161d8c9d3c 100644
|
||||
--- a/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
+++ b/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
@@ -1920,7 +1920,7 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
@@ -1919,7 +1919,7 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
}
|
||||
|
||||
// CraftBukkit - decompile error
|
||||
|
@ -3639,7 +3639,7 @@ index 9cae7fed34df3ff81d75105b2fcbc4510f2a0e71..285a03b57431bd6a4d26bb84e916d2c6
|
||||
public static <T> TicketType<T> a(String s, Comparator<T> comparator) {
|
||||
return new TicketType<>(s, comparator, 0L);
|
||||
diff --git a/src/main/java/net/minecraft/server/level/WorldServer.java b/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
index 634f34b8b88a1ef86cebf3126da9989a88707711..da53050c6c3d0a6ef3d5b96a88517e694536a268 100644
|
||||
index 7f9a1d64d123ce54608497a0e0a37d161d8c9d3c..780e541b8d594a8a6dc3a8626a82218f2502a5c7 100644
|
||||
--- a/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
+++ b/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
@@ -12,6 +12,7 @@ import it.unimi.dsi.fastutil.ints.Int2ObjectMap.Entry;
|
||||
@ -3659,7 +3659,7 @@ index 634f34b8b88a1ef86cebf3126da9989a88707711..da53050c6c3d0a6ef3d5b96a88517e69
|
||||
boolean tickingEntities;
|
||||
private final MinecraftServer server;
|
||||
public final WorldDataServer worldDataServer; // CraftBukkit - type
|
||||
@@ -1689,7 +1690,7 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
@@ -1688,7 +1689,7 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
ObjectIterator objectiterator = spawnercreature_d.b().object2IntEntrySet().iterator();
|
||||
|
||||
while (objectiterator.hasNext()) {
|
||||
|
@ -1249,7 +1249,7 @@ index 0bf95b97140a67682ec2953ccc773f6faad7b7da..9eae9d7e9d18d73b1050e1d9b8859802
|
||||
|
||||
protected void broadcast(Entity entity, Packet<?> packet) {
|
||||
diff --git a/src/main/java/net/minecraft/server/level/WorldServer.java b/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
index da53050c6c3d0a6ef3d5b96a88517e694536a268..4170743875d2fb16987e513713b2d141918219a5 100644
|
||||
index 780e541b8d594a8a6dc3a8626a82218f2502a5c7..cf38d517821659e25e786a805e229ef2d626d75f 100644
|
||||
--- a/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
+++ b/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
@@ -2,6 +2,8 @@ package net.minecraft.server.level;
|
||||
@ -2016,10 +2016,10 @@ index ebf2c62e9ea126577a6cbcbbeb3f3aba259a1f63..e69de29bb2d1d6434b8b29ae775ad8c2
|
||||
- }
|
||||
-}
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
index 97387235e883fd53950a88c244ac1bc9b24ec225..597b3b061c707081e7665d5896f5d73676e691d6 100644
|
||||
index c3a06eabbff3c37c88b1f09fe4bf806418e3a4d4..b51a874e4665f977a154792e6216e03e04525f39 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
@@ -1803,6 +1803,14 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||
@@ -1808,6 +1808,14 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||
packet.components = components;
|
||||
getHandle().playerConnection.sendPacket(packet);
|
||||
}
|
||||
|
@ -2066,7 +2066,7 @@ index 3a4e2261d0b0cd17df3f96e75f3c509156679c48..105d0388998d1e35e634d2163fe1a44a
|
||||
player.activeContainer.addSlotListener(player);
|
||||
}
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
index 597b3b061c707081e7665d5896f5d73676e691d6..137870c7d18c9ef3ae637e83c5457d42ec40c669 100644
|
||||
index b51a874e4665f977a154792e6216e03e04525f39..fd1fd9bfee34b88864187d9004eb9d6cb968dec5 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
@@ -240,14 +240,39 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||
@ -2249,9 +2249,9 @@ index 597b3b061c707081e7665d5896f5d73676e691d6..137870c7d18c9ef3ae637e83c5457d42
|
||||
+ }
|
||||
+ // Paper end
|
||||
@Override
|
||||
public String getLocale() {
|
||||
return getHandle().locale;
|
||||
@@ -1711,6 +1787,138 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||
public int getPing() {
|
||||
return getHandle().ping;
|
||||
@@ -1716,6 +1792,138 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||
getInventory().setItemInMainHand(hand);
|
||||
}
|
||||
|
||||
@ -2391,10 +2391,10 @@ index 597b3b061c707081e7665d5896f5d73676e691d6..137870c7d18c9ef3ae637e83c5457d42
|
||||
private final Player.Spigot spigot = new Player.Spigot()
|
||||
{
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
index 731ee453d962b375c280b2ad3b63c7141a687da7..f3801a88711a3431fd135efca4d5c15385593a41 100644
|
||||
index 8e83eb95ffce62aad10f4d9b259dc5dd076b7640..418becfe2b4fe5ca808f250469bbb46414a5cbc0 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
@@ -781,9 +781,9 @@ public class CraftEventFactory {
|
||||
@@ -785,9 +785,9 @@ public class CraftEventFactory {
|
||||
return event;
|
||||
}
|
||||
|
||||
@ -2406,7 +2406,7 @@ index 731ee453d962b375c280b2ad3b63c7141a687da7..f3801a88711a3431fd135efca4d5c153
|
||||
event.setKeepInventory(keepInventory);
|
||||
org.bukkit.World world = entity.getWorld();
|
||||
Bukkit.getServer().getPluginManager().callEvent(event);
|
||||
@@ -807,7 +807,7 @@ public class CraftEventFactory {
|
||||
@@ -811,7 +811,7 @@ public class CraftEventFactory {
|
||||
* Server methods
|
||||
*/
|
||||
public static ServerListPingEvent callServerListPingEvent(Server craftServer, InetAddress address, String motd, int numPlayers, int maxPlayers) {
|
||||
|
@ -5,7 +5,7 @@ Subject: [PATCH] Player affects spawning API
|
||||
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
|
||||
index d7dfb89faa47817c51257bb124cfb3806c5e27da..ca620977666f4d4173089876f506f041ab278bd3 100644
|
||||
index 20e4ff812960a54872f2fea8fe6baf7bb1ef077d..cae9da158f54438d2a397665c7ce964f6f755469 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/Entity.java
|
||||
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
|
||||
@@ -1354,6 +1354,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, ne
|
||||
@ -131,10 +131,10 @@ index 33cba4e475edc0573b901f70c61d3659fd63ad62..8d8b03074df1635946f81bec0feae18d
|
||||
|
||||
public void c() {
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
index 137870c7d18c9ef3ae637e83c5457d42ec40c669..e9f5ef73de6fd100dda7ed006dde6635f65b1ab5 100644
|
||||
index fd1fd9bfee34b88864187d9004eb9d6cb968dec5..cbedfb3525ba34490b84926800bbd61b9997947e 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
@@ -1767,8 +1767,20 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||
@@ -1772,8 +1772,20 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||
@Override
|
||||
public String getLocale() {
|
||||
return getHandle().locale;
|
||||
|
@ -22,7 +22,7 @@ index 6a8567c355202560ee523c6dc68cac1ac3e562fd..69dc4431a430461ce242de5c1a1c3023
|
||||
// CraftBukkit end
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
index da193bfc1d98e489eedc373ee87ab58b75d4377e..144faef77e69c6c3bf963327179a51bb4c37cc18 100644
|
||||
index f473808393b8440f457dfa1b2e1b9e8ccd60ec48..628f34f3855f0c8359b1e916dd3419345f690575 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
@@ -138,6 +138,10 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||
@ -36,7 +36,7 @@ index da193bfc1d98e489eedc373ee87ab58b75d4377e..144faef77e69c6c3bf963327179a51bb
|
||||
|
||||
public CraftPlayer(CraftServer server, EntityPlayer entity) {
|
||||
super(server, entity);
|
||||
@@ -1871,6 +1875,32 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||
@@ -1876,6 +1880,32 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||
public boolean getAffectsSpawning() {
|
||||
return this.getHandle().affectsSpawning;
|
||||
}
|
||||
|
@ -6,10 +6,10 @@ Subject: [PATCH] Remove unused World Tile Entity List
|
||||
Massive hit to performance and it is completely unnecessary.
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/level/WorldServer.java b/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
index b40089319329a0843c4d74ebd6189fc4089e319a..2412c2fa22abe171254f7fe49d319bcd6cc533ff 100644
|
||||
index 24a45e5ac9b17feb528e9a047d1ad1761569ebfa..75424a5dd6db57dded3b6d895e6b5b102e91c77e 100644
|
||||
--- a/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
+++ b/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
@@ -1722,7 +1722,7 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
@@ -1721,7 +1721,7 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
}
|
||||
|
||||
bufferedwriter.write(String.format("entities: %d\n", this.entitiesById.size()));
|
||||
@ -18,7 +18,7 @@ index b40089319329a0843c4d74ebd6189fc4089e319a..2412c2fa22abe171254f7fe49d319bcd
|
||||
bufferedwriter.write(String.format("block_ticks: %d\n", this.getBlockTickList().a()));
|
||||
bufferedwriter.write(String.format("fluid_ticks: %d\n", this.getFluidTickList().a()));
|
||||
bufferedwriter.write("distance_manager: " + playerchunkmap.e().c() + "\n");
|
||||
@@ -1861,7 +1861,7 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
@@ -1860,7 +1860,7 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
|
||||
private void a(Writer writer) throws IOException {
|
||||
CSVWriter csvwriter = CSVWriter.a().a("x").a("y").a("z").a("type").a(writer);
|
||||
|
@ -30,11 +30,11 @@ index ad55212370e3d814a397680927a1514ea0fe85b5..120cad4e7330900fa11d278cf87a6ab4
|
||||
this.locale = packetplayinsettings.locale;
|
||||
// Paper start
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
index facf2a79144a2d0fbea907c084becaea7bbdc48c..6d7f1dee9ae2fb0b9620d85969de86eee09020cc 100644
|
||||
index 46af184cd8280822170f28464eb32595733234c3..26396ca131d81b7357c31b3475eea8b2a7fb8638 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
@@ -1874,8 +1874,10 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||
// Paper end
|
||||
@@ -1879,8 +1879,10 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||
|
||||
@Override
|
||||
public String getLocale() {
|
||||
- return getHandle().locale;
|
||||
|
@ -21,7 +21,7 @@ index cc31c8f31a385f3a8bfe334e75c3553689397750..d6e1697f64e60f2a567288c604a16901
|
||||
if (CraftEventFactory.callPigZapEvent(this, entitylightning, entitypigzombie).isCancelled()) {
|
||||
return;
|
||||
diff --git a/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java b/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java
|
||||
index 39071f82ae539c98499e9db37483ccecafc5f186..3604fffb9ba13a019e98e0a1a0ef7ba81c8dc329 100644
|
||||
index 651ee45431c22b944fac640f936608ae587c055d..6df58fe8084d866de1697ef3fdbfe6648fe42b5f 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java
|
||||
+++ b/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java
|
||||
@@ -787,6 +787,12 @@ public class EntityVillager extends EntityVillagerAbstract implements Reputation
|
||||
@ -38,10 +38,10 @@ index 39071f82ae539c98499e9db37483ccecafc5f186..3604fffb9ba13a019e98e0a1a0ef7ba8
|
||||
entitywitch.prepare(worldserver, worldserver.getDamageScaler(entitywitch.getChunkCoordinates()), EnumMobSpawn.CONVERSION, (GroupDataEntity) null, (NBTTagCompound) null);
|
||||
entitywitch.setNoAI(this.isNoAI());
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
index f3801a88711a3431fd135efca4d5c15385593a41..b2f41bc3406d43f71eba270174386d875aecd932 100644
|
||||
index 418becfe2b4fe5ca808f250469bbb46414a5cbc0..3951ccb8821a1363d9b5f76568f5e7f6dcbc675b 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
@@ -1091,6 +1091,14 @@ public class CraftEventFactory {
|
||||
@@ -1095,6 +1095,14 @@ public class CraftEventFactory {
|
||||
return event;
|
||||
}
|
||||
|
||||
|
@ -18,7 +18,7 @@ index a52cd6d0318e0fee28fc5d252a4b596b92860320..a17812943b5402684c68ddeac5408dc9
|
||||
|
||||
this.die();
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
index b2f41bc3406d43f71eba270174386d875aecd932..a7c371694a7c6be117501b1dd816acbd304290f5 100644
|
||||
index 3951ccb8821a1363d9b5f76568f5e7f6dcbc675b..2127455979b25055c38a4e8088419069d948e539 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
@@ -119,6 +119,7 @@ import org.bukkit.entity.ThrownPotion;
|
||||
@ -29,7 +29,7 @@ index b2f41bc3406d43f71eba270174386d875aecd932..a7c371694a7c6be117501b1dd816acbd
|
||||
import org.bukkit.event.Cancellable;
|
||||
import org.bukkit.event.Event;
|
||||
import org.bukkit.event.Event.Result;
|
||||
@@ -1050,6 +1051,17 @@ public class CraftEventFactory {
|
||||
@@ -1054,6 +1055,17 @@ public class CraftEventFactory {
|
||||
return event;
|
||||
}
|
||||
|
||||
|
@ -5,7 +5,7 @@ Subject: [PATCH] Add ProjectileCollideEvent
|
||||
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/world/entity/projectile/EntityArrow.java b/src/main/java/net/minecraft/world/entity/projectile/EntityArrow.java
|
||||
index 9bd4a283a99f86c9a26f73e0bad0c3414d66ad55..5ecbe9135a71dd84e0722fa9c039c272a11d206f 100644
|
||||
index 7868259a94766a6100d7b278c4296dde0a7f9397..c325c9fe680d9033b20909bcd6100ecc4b0195f6 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/projectile/EntityArrow.java
|
||||
+++ b/src/main/java/net/minecraft/world/entity/projectile/EntityArrow.java
|
||||
@@ -198,6 +198,17 @@ public abstract class EntityArrow extends IProjectile {
|
||||
@ -24,10 +24,10 @@ index 9bd4a283a99f86c9a26f73e0bad0c3414d66ad55..5ecbe9135a71dd84e0722fa9c039c272
|
||||
+ // Paper end
|
||||
+
|
||||
if (object != null && !flag) {
|
||||
this.a((MovingObjectPosition) object);
|
||||
this.preOnHit((MovingObjectPosition) object); // CraftBukkit - projectile hit event
|
||||
this.impulse = true;
|
||||
diff --git a/src/main/java/net/minecraft/world/entity/projectile/EntityFireball.java b/src/main/java/net/minecraft/world/entity/projectile/EntityFireball.java
|
||||
index ed76aec99f46a7923d139e347779c24f512ac131..ede7b4dbf2dce7bac83c5e17eecfdaf0e8a84fe7 100644
|
||||
index 2ceae34365c437f2a15ae8587fa9517ea47ad6f2..9660dc2263c48a5818b767843658eeb9ee1748ea 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/projectile/EntityFireball.java
|
||||
+++ b/src/main/java/net/minecraft/world/entity/projectile/EntityFireball.java
|
||||
@@ -13,6 +13,7 @@ import net.minecraft.world.entity.EntityLiving;
|
||||
@ -53,11 +53,11 @@ index ed76aec99f46a7923d139e347779c24f512ac131..ede7b4dbf2dce7bac83c5e17eecfdaf0
|
||||
+ // Paper end
|
||||
+
|
||||
+ if (movingobjectposition != null && movingobjectposition.getType() != MovingObjectPosition.EnumMovingObjectType.MISS) { // Paper - add null check in case cancelled
|
||||
this.a(movingobjectposition);
|
||||
this.preOnHit(movingobjectposition); // CraftBukkit - projectile hit event
|
||||
|
||||
// CraftBukkit start - Fire ProjectileHitEvent
|
||||
diff --git a/src/main/java/net/minecraft/world/entity/projectile/EntityProjectile.java b/src/main/java/net/minecraft/world/entity/projectile/EntityProjectile.java
|
||||
index 829b4f28896bcb0eb6e48242bd00585eeaae62c2..3b379e83b79bd9b46dbdd4a48ac3842abc4dfbb8 100644
|
||||
index 149588433cd0ea0f71b45267e39b28697ccfd2c0..8bc65e9c0fa5e134a8eb4e03f0da5b2ccd06cd7c 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/projectile/EntityProjectile.java
|
||||
+++ b/src/main/java/net/minecraft/world/entity/projectile/EntityProjectile.java
|
||||
@@ -14,6 +14,7 @@ import net.minecraft.world.level.block.entity.TileEntityEndGateway;
|
||||
@ -81,16 +81,16 @@ index 829b4f28896bcb0eb6e48242bd00585eeaae62c2..3b379e83b79bd9b46dbdd4a48ac3842a
|
||||
+ }
|
||||
+ if (movingobjectposition != null) {
|
||||
+ // Paper end
|
||||
this.a(movingobjectposition);
|
||||
this.preOnHit(movingobjectposition); // CraftBukkit - projectile hit event
|
||||
+ } // Paper
|
||||
}
|
||||
|
||||
this.checkBlockCollisions();
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
index a7c371694a7c6be117501b1dd816acbd304290f5..54d4d2363cb343c059c5676d2b351b8ad8bbe529 100644
|
||||
index 2127455979b25055c38a4e8088419069d948e539..2ca0d109b148321964ac68259df82e4b1d7c57b2 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
@@ -1195,6 +1195,16 @@ public class CraftEventFactory {
|
||||
@@ -1199,6 +1199,16 @@ public class CraftEventFactory {
|
||||
return CraftItemStack.asNMSCopy(bitem);
|
||||
}
|
||||
|
||||
|
@ -20,10 +20,10 @@ index 90ca51dfdbb3045dd528450225cba96f5834166e..6c692e58cde22003ecbf6dc569579914
|
||||
+ }
|
||||
}
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
index 54d4d2363cb343c059c5676d2b351b8ad8bbe529..dcc7096f35f8cf6935d30b115b824c6bd8623ce5 100644
|
||||
index 2ca0d109b148321964ac68259df82e4b1d7c57b2..d7a0a978411d56c93bec0d510060216eb592fed8 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
@@ -592,16 +592,32 @@ public class CraftEventFactory {
|
||||
@@ -596,16 +596,32 @@ public class CraftEventFactory {
|
||||
EntityExperienceOrb xp = (EntityExperienceOrb) entity;
|
||||
double radius = world.spigotConfig.expMerge;
|
||||
if (radius > 0) {
|
||||
|
@ -8,10 +8,10 @@ Plugins can cancel this if they want to ensure experience orbs do not lose impor
|
||||
metadata such as spawn reason, or conditionally move data from source to target.
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
index dcc7096f35f8cf6935d30b115b824c6bd8623ce5..8bbd5f9d64f105dc7888862f09b02b10bf0f5dd5 100644
|
||||
index d7a0a978411d56c93bec0d510060216eb592fed8..e068896b1b8aab8bba8acd641bf0479c89ad3321 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
@@ -602,7 +602,7 @@ public class CraftEventFactory {
|
||||
@@ -606,7 +606,7 @@ public class CraftEventFactory {
|
||||
if (e instanceof EntityExperienceOrb) {
|
||||
EntityExperienceOrb loopItem = (EntityExperienceOrb) e;
|
||||
// Paper start
|
||||
|
@ -69,7 +69,7 @@ index 41f1aecbf6b506231a1b3b525fe0ce23b35c7840..6c01e460d3a1ff7f865ebc34dfd28d55
|
||||
entityliving.getBehaviorController().a(MemoryModuleType.GOLEM_DETECTED_RECENTLY, true, 600L);
|
||||
}
|
||||
diff --git a/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java b/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java
|
||||
index adce6f17a5dd33004f8a67cd55d195de029e0263..534efe39beee393d11705b8f0b13ce4ca727c3eb 100644
|
||||
index 0c579cff2fcabd15a2a0af919fcc60b4e7ce25ad..858bbfbc08a5f2e1ef93ff52d6708059b32fbbbf 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java
|
||||
+++ b/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java
|
||||
@@ -30,6 +30,7 @@ import net.minecraft.network.protocol.game.PacketDebug;
|
||||
@ -80,7 +80,7 @@ index adce6f17a5dd33004f8a67cd55d195de029e0263..534efe39beee393d11705b8f0b13ce4c
|
||||
import net.minecraft.server.MinecraftServer;
|
||||
import net.minecraft.server.level.WorldServer;
|
||||
import net.minecraft.sounds.SoundEffect;
|
||||
@@ -936,6 +937,21 @@ public class EntityVillager extends EntityVillagerAbstract implements Reputation
|
||||
@@ -943,6 +944,21 @@ public class EntityVillager extends EntityVillagerAbstract implements Reputation
|
||||
BlockPosition blockposition1 = this.a(blockposition, d0, d1);
|
||||
|
||||
if (blockposition1 != null) {
|
||||
|
@ -27,10 +27,10 @@ index cebf1a623a9bec72d60fdd23dda01868ef6431d4..e8e1e7dafaf1c105b2f58cf3e118e3d6
|
||||
+ }
|
||||
}
|
||||
diff --git a/src/main/java/net/minecraft/world/entity/projectile/IProjectile.java b/src/main/java/net/minecraft/world/entity/projectile/IProjectile.java
|
||||
index 33b3643922f1d703221afb538cda6c097ddbae43..65cea9282467cb362ac6e9e0bb03c5d36085ee43 100644
|
||||
index 5c9ffd02b4f2977ee13a962a214887f74c91594f..8f14e1ebefe172e056a04bd7b6f55b9bbb1e7b2e 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/projectile/IProjectile.java
|
||||
+++ b/src/main/java/net/minecraft/world/entity/projectile/IProjectile.java
|
||||
@@ -59,6 +59,7 @@ public abstract class IProjectile extends Entity {
|
||||
@@ -63,6 +63,7 @@ public abstract class IProjectile extends Entity {
|
||||
protected void loadData(NBTTagCompound nbttagcompound) {
|
||||
if (nbttagcompound.b("Owner")) {
|
||||
this.shooter = nbttagcompound.a("Owner");
|
||||
|
@ -10,7 +10,7 @@ Adds an option to control the force mode of the particle.
|
||||
This adds a new Builder API which is much friendlier to use.
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/level/WorldServer.java b/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
index 6137a88e1dc8d19a4e35ad97500dabeddba008a8..96d67fc3cbe61c1fb6e639b1838b2fd198c3f3d5 100644
|
||||
index 744ec6f09a1b3ccdf0d74fe50f1e1c913ee2df86..b73315df7dae243dd76e44d586dfc1d8f9017a56 100644
|
||||
--- a/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
+++ b/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
@@ -170,7 +170,7 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
@ -22,7 +22,7 @@ index 6137a88e1dc8d19a4e35ad97500dabeddba008a8..96d67fc3cbe61c1fb6e639b1838b2fd1
|
||||
public final ChunkProviderServer chunkProvider; // Paper - public
|
||||
boolean tickingEntities;
|
||||
private final MinecraftServer server;
|
||||
@@ -1479,12 +1479,17 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
@@ -1478,12 +1478,17 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
}
|
||||
|
||||
public <T extends ParticleParam> int sendParticles(EntityPlayer sender, T t0, double d0, double d1, double d2, int i, double d3, double d4, double d5, double d6, boolean force) {
|
||||
@ -43,7 +43,7 @@ index 6137a88e1dc8d19a4e35ad97500dabeddba008a8..96d67fc3cbe61c1fb6e639b1838b2fd1
|
||||
|
||||
if (this.a(entityplayer, force, d0, d1, d2, packetplayoutworldparticles)) { // CraftBukkit
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||
index 2513e9a5b66598337f5d380a036ee10fdbab38c3..3855b8264d3223f3b1609a3cb81e009b1cd61268 100644
|
||||
index d7d58a0feac2d0b4303c625b7952103613e8c33e..13d3b6accfb86383660a7d0e991519fd930bd518 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||
@@ -2352,11 +2352,17 @@ public class CraftWorld implements World {
|
||||
|
@ -61,7 +61,7 @@ index 3d517ab98da5fd56101e97b5678f7180839269f8..7b07d17f8ae425418ff3cafdfd30d72a
|
||||
this.o();
|
||||
}
|
||||
diff --git a/src/main/java/net/minecraft/server/level/WorldServer.java b/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
index 96d67fc3cbe61c1fb6e639b1838b2fd198c3f3d5..c7e54920b40bdf049f2192310bfdb9d1749580d0 100644
|
||||
index b73315df7dae243dd76e44d586dfc1d8f9017a56..eb19b6fc87bfd4e500ea7836c1010a80b36abab2 100644
|
||||
--- a/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
+++ b/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
@@ -1125,7 +1125,7 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
@ -193,10 +193,10 @@ index 871c0e0b0c6df68c0f8c87828a01fe006d0646fb..32228b4eddaadabbae46ebbc5eb3404a
|
||||
|
||||
// Check if the fromWorld and toWorld are the same.
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
index 8bbd5f9d64f105dc7888862f09b02b10bf0f5dd5..5a606af5993d372db297e6572cc0ee28ba3d1981 100644
|
||||
index e068896b1b8aab8bba8acd641bf0479c89ad3321..69bcd6dcfc62ab7b5666b8e185efa07a9adbc179 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
@@ -1180,7 +1180,7 @@ public class CraftEventFactory {
|
||||
@@ -1184,7 +1184,7 @@ public class CraftEventFactory {
|
||||
|
||||
public static Container callInventoryOpenEvent(EntityPlayer player, Container container, boolean cancelled) {
|
||||
if (player.activeContainer != player.defaultContainer) { // fire INVENTORY_CLOSE if one already open
|
||||
@ -205,7 +205,7 @@ index 8bbd5f9d64f105dc7888862f09b02b10bf0f5dd5..5a606af5993d372db297e6572cc0ee28
|
||||
}
|
||||
|
||||
CraftServer server = player.world.getServer();
|
||||
@@ -1345,8 +1345,18 @@ public class CraftEventFactory {
|
||||
@@ -1350,8 +1350,18 @@ public class CraftEventFactory {
|
||||
return event;
|
||||
}
|
||||
|
||||
|
@ -18,7 +18,7 @@ index c88eea18e2e219f242c53ffb4e28cfc6d7bf318a..3a46a5001cda7402a97ac8552650cf64
|
||||
protected int j;
|
||||
@Nullable
|
||||
diff --git a/src/main/java/net/minecraft/world/entity/projectile/IProjectile.java b/src/main/java/net/minecraft/world/entity/projectile/IProjectile.java
|
||||
index 65cea9282467cb362ac6e9e0bb03c5d36085ee43..65cee640040bdd1229149409ff046b765ee08c34 100644
|
||||
index 8f14e1ebefe172e056a04bd7b6f55b9bbb1e7b2e..b44b18341331e5176e0f1851aa60cc425ccbd439 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/projectile/IProjectile.java
|
||||
+++ b/src/main/java/net/minecraft/world/entity/projectile/IProjectile.java
|
||||
@@ -4,6 +4,7 @@ import java.util.Iterator;
|
||||
@ -29,7 +29,7 @@ index 65cea9282467cb362ac6e9e0bb03c5d36085ee43..65cee640040bdd1229149409ff046b76
|
||||
import net.minecraft.server.level.WorldServer;
|
||||
import net.minecraft.util.MathHelper;
|
||||
import net.minecraft.world.entity.Entity;
|
||||
@@ -140,8 +141,14 @@ public abstract class IProjectile extends Entity {
|
||||
@@ -158,8 +159,14 @@ public abstract class IProjectile extends Entity {
|
||||
protected boolean a(Entity entity) {
|
||||
if (!entity.isSpectator() && entity.isAlive() && entity.isInteractable()) {
|
||||
Entity entity1 = this.getShooter();
|
||||
@ -174,10 +174,10 @@ index fdd9e37a8c90fc3311e515355af0a0593efbdacc..cf32a4f63e8e59535c02a3f9c57f9883
|
||||
if (operatorboolean.apply(false, false)) {
|
||||
throw (IllegalArgumentException) SystemUtils.c((Throwable) (new IllegalArgumentException()));
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
index 5a606af5993d372db297e6572cc0ee28ba3d1981..025fd258c052b398f8b4ad189cc63ab26f49f931 100644
|
||||
index 69bcd6dcfc62ab7b5666b8e185efa07a9adbc179..6d08487ff25b474b2372de37ea77aa0eb997d89a 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
@@ -1216,6 +1216,14 @@ public class CraftEventFactory {
|
||||
@@ -1220,6 +1220,14 @@ public class CraftEventFactory {
|
||||
Projectile projectile = (Projectile) entity.getBukkitEntity();
|
||||
org.bukkit.entity.Entity collided = position.getEntity().getBukkitEntity();
|
||||
com.destroystokyo.paper.event.entity.ProjectileCollideEvent event = new com.destroystokyo.paper.event.entity.ProjectileCollideEvent(projectile, collided);
|
||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] Add hand to bucket events
|
||||
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/level/WorldServer.java b/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
index 4eda8d2065d72c67b1e1cf9e9560e13e7f24d470..0c1867c00be9ecda5294298c5b9d22098e213a81 100644
|
||||
index 9151d84e2f6fb316525c74466589178769fbc8ef..ecb4cb5df868673e5aa2eec3fdd8618dbea09655 100644
|
||||
--- a/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
+++ b/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
@@ -1658,15 +1658,17 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
@@ -1657,15 +1657,17 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
this.getMinecraftServer().getPlayerList().sendAll(new PacketPlayOutSpawnPosition(blockposition, f));
|
||||
}
|
||||
|
||||
@ -126,10 +126,10 @@ index 07c5cdd00930a55fd412ef95f71f55ee908189a1..88b1a0235bfc0b41ae1855f8900632e4
|
||||
public boolean s_() {
|
||||
return this.isClientSide;
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
index 025fd258c052b398f8b4ad189cc63ab26f49f931..02e3d72529dfe9d5ad2b7681458df1c50dfd0ea8 100644
|
||||
index 6d08487ff25b474b2372de37ea77aa0eb997d89a..877a0ea25f3cea970fa3827b12efc1a44bdcdf9c 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
@@ -230,7 +230,7 @@ public class CraftEventFactory {
|
||||
@@ -231,7 +231,7 @@ public class CraftEventFactory {
|
||||
public static Entity entityDamage; // For use in EntityDamageByEntityEvent
|
||||
|
||||
// helper methods
|
||||
@ -138,7 +138,7 @@ index 025fd258c052b398f8b4ad189cc63ab26f49f931..02e3d72529dfe9d5ad2b7681458df1c5
|
||||
int spawnSize = Bukkit.getServer().getSpawnRadius();
|
||||
|
||||
if (world.getDimensionKey() != World.OVERWORLD) return true;
|
||||
@@ -420,6 +420,20 @@ public class CraftEventFactory {
|
||||
@@ -421,6 +421,20 @@ public class CraftEventFactory {
|
||||
}
|
||||
|
||||
private static PlayerEvent getPlayerBucketEvent(boolean isFilling, WorldServer world, EntityHuman who, BlockPosition changed, BlockPosition clicked, EnumDirection clickedFace, ItemStack itemstack, net.minecraft.world.item.Item item) {
|
||||
@ -159,7 +159,7 @@ index 025fd258c052b398f8b4ad189cc63ab26f49f931..02e3d72529dfe9d5ad2b7681458df1c5
|
||||
Player player = (Player) who.getBukkitEntity();
|
||||
CraftItemStack itemInHand = CraftItemStack.asNewCraftStack(item);
|
||||
Material bucket = CraftMagicNumbers.getMaterial(itemstack.getItem());
|
||||
@@ -432,10 +446,10 @@ public class CraftEventFactory {
|
||||
@@ -433,10 +447,10 @@ public class CraftEventFactory {
|
||||
|
||||
PlayerEvent event;
|
||||
if (isFilling) {
|
||||
|
@ -17,10 +17,10 @@ index b6effe1037f3ae59e6faa5f5d039b6ad54bca5d4..87374174dcbf9e7ee448a1cdd9a35285
|
||||
return (float) (1.0D / this.b(GenericAttributes.ATTACK_SPEED) * 20.0D);
|
||||
}
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
index 32228b4eddaadabbae46ebbc5eb3404acf73fb29..9d3e01f7ad743dbe60685e9b111308ed06a0b4b7 100644
|
||||
index 5d75a1f838b8ef21c3eaa6dca6e0d82b0ab5e825..577fa407e436fd3b65eb8a40a7f2ec0a7b2abfac 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
@@ -2186,6 +2186,18 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||
@@ -2191,6 +2191,18 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||
connection.sendPacket(new net.minecraft.network.protocol.game.PacketPlayOutOpenBook(net.minecraft.world.EnumHand.MAIN_HAND));
|
||||
connection.sendPacket(new net.minecraft.network.protocol.game.PacketPlayOutSetSlot(0, slot, inventory.getItemInHand()));
|
||||
}
|
||||
|
@ -346,7 +346,7 @@ index 9d3e01f7ad743dbe60685e9b111308ed06a0b4b7..2334a9a95ab0e2395744343a5a1e3d26
|
||||
|
||||
public void injectScaledMaxHealth(Collection<AttributeModifiable> collection, boolean force) {
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
index 02e3d72529dfe9d5ad2b7681458df1c50dfd0ea8..a8f7b7c1430839a533f2ca26a4e7b109179db58d 100644
|
||||
index 877a0ea25f3cea970fa3827b12efc1a44bdcdf9c..fbd24e10b1b966898e7e1556c5f9bd607497d970 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
@@ -18,6 +18,8 @@ import net.minecraft.network.protocol.game.PacketPlayInCloseWindow;
|
||||
@ -358,7 +358,7 @@ index 02e3d72529dfe9d5ad2b7681458df1c50dfd0ea8..a8f7b7c1430839a533f2ca26a4e7b109
|
||||
import net.minecraft.util.Unit;
|
||||
import net.minecraft.world.EnumHand;
|
||||
import net.minecraft.world.IInventory;
|
||||
@@ -798,9 +800,16 @@ public class CraftEventFactory {
|
||||
@@ -802,9 +804,16 @@ public class CraftEventFactory {
|
||||
public static EntityDeathEvent callEntityDeathEvent(EntityLiving victim, List<org.bukkit.inventory.ItemStack> drops) {
|
||||
CraftLivingEntity entity = (CraftLivingEntity) victim.getBukkitEntity();
|
||||
EntityDeathEvent event = new EntityDeathEvent(entity, drops, victim.getExpReward());
|
||||
@ -375,7 +375,7 @@ index 02e3d72529dfe9d5ad2b7681458df1c50dfd0ea8..a8f7b7c1430839a533f2ca26a4e7b109
|
||||
victim.expToDrop = event.getDroppedExp();
|
||||
|
||||
for (org.bukkit.inventory.ItemStack stack : event.getDrops()) {
|
||||
@@ -816,8 +825,15 @@ public class CraftEventFactory {
|
||||
@@ -820,8 +829,15 @@ public class CraftEventFactory {
|
||||
CraftPlayer entity = victim.getBukkitEntity();
|
||||
PlayerDeathEvent event = new PlayerDeathEvent(entity, drops, victim.getExpReward(), 0, deathMessage, stringDeathMessage); // Paper - Adventure
|
||||
event.setKeepInventory(keepInventory);
|
||||
@ -391,7 +391,7 @@ index 02e3d72529dfe9d5ad2b7681458df1c50dfd0ea8..a8f7b7c1430839a533f2ca26a4e7b109
|
||||
|
||||
victim.keepLevel = event.getKeepLevel();
|
||||
victim.newLevel = event.getNewLevel();
|
||||
@@ -834,6 +850,31 @@ public class CraftEventFactory {
|
||||
@@ -838,6 +854,31 @@ public class CraftEventFactory {
|
||||
return event;
|
||||
}
|
||||
|
||||
|
@ -8,7 +8,7 @@ our own relocation. Also lets us rewrite NMS calls for when we're
|
||||
debugging in an IDE pre-relocate.
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/util/Commodore.java b/src/main/java/org/bukkit/craftbukkit/util/Commodore.java
|
||||
index 6ccfd49c43d0e896ee0f15dfbe577a541367dab8..21f265e3c6d9952f9e0e9a28f8c8de9ee733bf1e 100644
|
||||
index 45cbdcfc131bbc0e2bf23cc30a572df72eecd51c..49e5a86c223f1b28ce7da6ced276b2f880777856 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/util/Commodore.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/util/Commodore.java
|
||||
@@ -6,7 +6,9 @@ import java.io.FileOutputStream;
|
||||
@ -167,7 +167,7 @@ index 6ccfd49c43d0e896ee0f15dfbe577a541367dab8..21f265e3c6d9952f9e0e9a28f8c8de9e
|
||||
if ( owner.equals( "org/bukkit/block/Biome" ) )
|
||||
{
|
||||
switch ( name )
|
||||
@@ -260,6 +374,14 @@ public class Commodore
|
||||
@@ -270,6 +384,14 @@ public class Commodore
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -11,10 +11,10 @@ If the projectile fails to find the shooter in the current world, check
|
||||
other worlds.
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/world/entity/projectile/IProjectile.java b/src/main/java/net/minecraft/world/entity/projectile/IProjectile.java
|
||||
index 65cee640040bdd1229149409ff046b765ee08c34..a33f3924a95b86c2337c455f30de9bb257cb8db4 100644
|
||||
index b44b18341331e5176e0f1851aa60cc425ccbd439..29834a3613c7701d46e879d170779eb7e6f664e1 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/projectile/IProjectile.java
|
||||
+++ b/src/main/java/net/minecraft/world/entity/projectile/IProjectile.java
|
||||
@@ -41,7 +41,18 @@ public abstract class IProjectile extends Entity {
|
||||
@@ -45,7 +45,18 @@ public abstract class IProjectile extends Entity {
|
||||
|
||||
@Nullable
|
||||
public Entity getShooter() {
|
||||
|
@ -12,10 +12,10 @@ Player we will look at limiting the scope of this change. It appears to
|
||||
be unintentional in the few cases we've seen so far.
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
index c2ebf264d9d150541aeb2d89f24853c2f887cde5..e645a3386df6334e99d80ec6961399461c9545a9 100644
|
||||
index 3e07e93a272bb65db9f191ae7c3ed18ccc9d3657..5cdefb8978cdd3d29cc120c35040189c4f86f7bf 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
@@ -2231,6 +2231,15 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||
@@ -2236,6 +2236,15 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||
public void resetCooldown() {
|
||||
getHandle().resetAttackCooldown();
|
||||
}
|
||||
|
@ -40,10 +40,10 @@ index 145767e8b0fc4105a0afa47af17dcdbb75e952bc..174eb12722872182b2d9b54841e5bb57
|
||||
double deltaZ = this.locZ() - player.locZ();
|
||||
double distanceSquared = deltaX * deltaX + deltaZ * deltaZ;
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
index e645a3386df6334e99d80ec6961399461c9545a9..43e4ade73619d430be7ee93687e98ef5a27cb329 100644
|
||||
index 5cdefb8978cdd3d29cc120c35040189c4f86f7bf..c0d2abd31272e35c0a0a4f8c31cfd89e56552bea 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
@@ -2240,6 +2240,16 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||
@@ -2245,6 +2245,16 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||
super.remove();
|
||||
}
|
||||
}
|
||||
|
@ -84,7 +84,7 @@ index 5020b1ef1e0fc08a00a40aecfd3eeb74348865d1..0aa723d9940f4b33cd587aef6e23e238
|
||||
// CraftBukkit start
|
||||
// this.updateSpawnFlags();
|
||||
diff --git a/src/main/java/net/minecraft/server/level/WorldServer.java b/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
index a7fbbb755b2e829022efb0ae63fc1020d5adda4f..a9c0d3fc4aa07d9d580a31106169796b7bde4e63 100644
|
||||
index fbff779fa581a661cc03850bffa0da346ce15625..d308197995a92f5be8f5b928fa9ae83dd659545c 100644
|
||||
--- a/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
+++ b/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
@@ -67,6 +67,7 @@ import net.minecraft.network.protocol.game.PacketPlayOutWorldEvent;
|
||||
@ -95,7 +95,7 @@ index a7fbbb755b2e829022efb0ae63fc1020d5adda4f..a9c0d3fc4aa07d9d580a31106169796b
|
||||
import net.minecraft.server.MinecraftServer;
|
||||
import net.minecraft.server.ScoreboardServer;
|
||||
import net.minecraft.server.level.progress.WorldLoadListener;
|
||||
@@ -1674,12 +1675,88 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
@@ -1673,12 +1674,88 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
return ((PersistentIdCounts) this.getMinecraftServer().E().getWorldPersistentData().a(PersistentIdCounts::new, "idcounts")).a();
|
||||
}
|
||||
|
||||
@ -230,7 +230,7 @@ index 872d00de41533ab7f4b43874de6c1747022e2ac5..ca81664d884e80e5cb1eb376a2c2ef1e
|
||||
@Override
|
||||
public void a(ChunkCoordIntPair chunkcoordintpair) {
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||
index 206289adb3294b7be15aaf54748c8da7e263bebb..dd9fe7d04666ff6173f9b39e6450bb1165cc9e8a 100644
|
||||
index 5a5f920954effbe549cacdaa39474989dc98ad75..ec9f9fdf1be4f1e68eea5554a6721efd11a53958 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||
@@ -1972,15 +1972,21 @@ public class CraftWorld implements World {
|
||||
|
@ -39,10 +39,10 @@ index 384cb363eed794551bee6b0ec11ba1be92a3d7ac..1ee2cced100626e48eb36ee14f84b925
|
||||
+ }
|
||||
}
|
||||
diff --git a/src/main/java/net/minecraft/world/entity/projectile/IProjectile.java b/src/main/java/net/minecraft/world/entity/projectile/IProjectile.java
|
||||
index a33f3924a95b86c2337c455f30de9bb257cb8db4..37b1febb45b900dfe4b225152e66bc4be83df220 100644
|
||||
index 29834a3613c7701d46e879d170779eb7e6f664e1..8fe98404ebb8b3b5d1fdac0896b27da10736026d 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/projectile/IProjectile.java
|
||||
+++ b/src/main/java/net/minecraft/world/entity/projectile/IProjectile.java
|
||||
@@ -126,7 +126,7 @@ public abstract class IProjectile extends Entity {
|
||||
@@ -130,7 +130,7 @@ public abstract class IProjectile extends Entity {
|
||||
this.shoot((double) f5, (double) f6, (double) f7, f3, f4);
|
||||
Vec3D vec3d = entity.getMot();
|
||||
|
||||
@ -50,4 +50,4 @@ index a33f3924a95b86c2337c455f30de9bb257cb8db4..37b1febb45b900dfe4b225152e66bc4b
|
||||
+ if (!entity.world.paperConfig.disableRelativeProjectileVelocity) this.setMot(this.getMot().add(vec3d.x, entity.isOnGround() ? 0.0D : vec3d.y, vec3d.z)); // Paper - allow disabling relative velocity
|
||||
}
|
||||
|
||||
protected void a(MovingObjectPosition movingobjectposition) {
|
||||
// CraftBukkit start - call projectile hit event
|
||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] Mark entities as being ticked when notifying navigation
|
||||
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/level/WorldServer.java b/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
index caf3d4df460d2d6dad6e68a68e1256e3603e3891..1b05d2394244d85a63ecd8336f7dd1d05f4fdffe 100644
|
||||
index e2c0d30c5b25f9c44025f0619ba254c89402d9f9..9012c837c2f284e9f2f11462e6dc7e2f6e190939 100644
|
||||
--- a/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
+++ b/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
@@ -1476,6 +1476,7 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
@@ -1475,6 +1475,7 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
VoxelShape voxelshape1 = iblockdata1.getCollisionShape(this, blockposition);
|
||||
|
||||
if (VoxelShapes.c(voxelshape, voxelshape1, OperatorBoolean.NOT_SAME)) {
|
||||
@ -16,7 +16,7 @@ index caf3d4df460d2d6dad6e68a68e1256e3603e3891..1b05d2394244d85a63ecd8336f7dd1d0
|
||||
Iterator iterator = this.navigators.iterator();
|
||||
|
||||
while (iterator.hasNext()) {
|
||||
@@ -1497,6 +1498,7 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
@@ -1496,6 +1497,7 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -2348,7 +2348,7 @@ index 191a74bd9b894f9d64d0a55747cb17e07ceef597..1732fc552c290d294b68d6f92f2a58d9
|
||||
DedicatedServer dedicatedserver1 = new DedicatedServer(optionset, datapackconfiguration1, thread, iregistrycustom_dimension, convertable_conversionsession, resourcepackrepository, datapackresources, null, dedicatedserversettings, DataConverterRegistry.a(), minecraftsessionservice, gameprofilerepository, usercache, WorldLoadListenerLogger::new);
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java
|
||||
index 4da16809f8f084fc4af4c50b5232914ea8aee04e..74c4462bc32e966055732944dfb931e75d7fad1f 100644
|
||||
index 9e6d70bdf4d1cf524e45b55ee51d87a30394ac84..baafdffabf28415da66eccb6e14466cd428f5832 100644
|
||||
--- a/src/main/java/net/minecraft/server/MinecraftServer.java
|
||||
+++ b/src/main/java/net/minecraft/server/MinecraftServer.java
|
||||
@@ -921,7 +921,7 @@ public abstract class MinecraftServer extends IAsyncTaskHandlerReentrant<TickTas
|
||||
@ -3071,7 +3071,7 @@ index 285a03b57431bd6a4d26bb84e916d2c6e1eb0213..218dc900e125a11548485887b1918742
|
||||
public static <T> TicketType<T> a(String s, Comparator<T> comparator) {
|
||||
return new TicketType<>(s, comparator, 0L);
|
||||
diff --git a/src/main/java/net/minecraft/server/level/WorldServer.java b/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
index 1b05d2394244d85a63ecd8336f7dd1d05f4fdffe..a68be9b72daca6353d51141a8771e00240375315 100644
|
||||
index 9012c837c2f284e9f2f11462e6dc7e2f6e190939..bb6c59237702bf82d2c344c864f233c606fd429f 100644
|
||||
--- a/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
+++ b/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
@@ -51,6 +51,7 @@ import net.minecraft.core.IRegistry;
|
||||
@ -3179,7 +3179,7 @@ index 1b05d2394244d85a63ecd8336f7dd1d05f4fdffe..a68be9b72daca6353d51141a8771e002
|
||||
}
|
||||
|
||||
// CraftBukkit start
|
||||
@@ -1744,7 +1821,10 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
@@ -1743,7 +1820,10 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
}
|
||||
|
||||
MCUtil.getSpiralOutChunks(spawn, radiusInBlocks >> 4).forEach(pair -> {
|
||||
@ -4060,7 +4060,7 @@ index 8ad97a8a2189553da88810380b1c240079eacc93..d3b9a9e4695655860c72db5f21884726
|
||||
+ // Paper end
|
||||
}
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||
index daa5c52a690ce33d2b2cd32c4fbaa147f25dd144..e880ce299bd81ad790da7b94fb28c49a5ebab1e7 100644
|
||||
index d46c513512c25e55ccdb0be16524f19444c358c5..6aaf868cf3213e1935080c64c652c3055cb58e0c 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||
@@ -563,22 +563,23 @@ public class CraftWorld implements World {
|
||||
|
@ -14,7 +14,7 @@ Adds flying monsters to control ghast and phantoms
|
||||
Adds villagers as separate config
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/level/WorldServer.java b/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
index 07b2f7f13044ace4db48274da8309c37aaa2d2c4..18169d48598b873b0d7507bb55a1a0bad0ab6566 100644
|
||||
index 6cbf8d00da6d99719f9ece14aa46c0abf38666e3..fda19e1639cfbae00c8ba946b41c16faa09acbd5 100644
|
||||
--- a/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
+++ b/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
@@ -861,17 +861,17 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
@ -351,7 +351,7 @@ index 8b09aaa30dd753fd34bea155890bdd9e5cb180f5..2005cb484ba6b5929ad81d3d120521f2
|
||||
return this.bB != null;
|
||||
}
|
||||
diff --git a/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java b/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java
|
||||
index 534efe39beee393d11705b8f0b13ce4ca727c3eb..07f87ee8f5df9d7a40001dd28f50457344308a03 100644
|
||||
index 858bbfbc08a5f2e1ef93ff52d6708059b32fbbbf..d7e152f7147bb599ce21dc605ebbd76e82eced26 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java
|
||||
+++ b/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java
|
||||
@@ -213,17 +213,29 @@ public class EntityVillager extends EntityVillagerAbstract implements Reputation
|
||||
@ -405,7 +405,7 @@ index 534efe39beee393d11705b8f0b13ce4ca727c3eb..07f87ee8f5df9d7a40001dd28f504573
|
||||
|
||||
super.mobTick();
|
||||
}
|
||||
@@ -894,6 +907,7 @@ public class EntityVillager extends EntityVillagerAbstract implements Reputation
|
||||
@@ -901,6 +914,7 @@ public class EntityVillager extends EntityVillagerAbstract implements Reputation
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] add hand to BlockMultiPlaceEvent
|
||||
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
index a8f7b7c1430839a533f2ca26a4e7b109179db58d..0b734398905ad4a0e45cb7d17aac8b0c50e4449c 100644
|
||||
index fbd24e10b1b966898e7e1556c5f9bd607497d970..dbfd500ad18262e4c1af40308229802fa0cb2e5d 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
@@ -345,13 +345,18 @@ public class CraftEventFactory {
|
||||
@@ -346,13 +346,18 @@ public class CraftEventFactory {
|
||||
}
|
||||
|
||||
org.bukkit.inventory.ItemStack item;
|
||||
|
@ -149,7 +149,7 @@ index 8981dfacd10cae9de052e1b36ce5181cd0e6752d..202fa94d5dc55b549475ae0309bbcfca
|
||||
protected static final DataWatcherObject<NBTTagCompound> bk = DataWatcher.a(EntityHuman.class, DataWatcherRegistry.p);
|
||||
protected static final DataWatcherObject<NBTTagCompound> bl = DataWatcher.a(EntityHuman.class, DataWatcherRegistry.p);
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
index 43e4ade73619d430be7ee93687e98ef5a27cb329..7a240739ac6e043e590b380659d8e6d794954f84 100644
|
||||
index c0d2abd31272e35c0a0a4f8c31cfd89e56552bea..f518fb4cabf53971daf635e3d82967c9baf0d086 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
@@ -1,5 +1,8 @@
|
||||
@ -161,7 +161,7 @@ index 43e4ade73619d430be7ee93687e98ef5a27cb329..7a240739ac6e043e590b380659d8e6d7
|
||||
import com.destroystokyo.paper.Title;
|
||||
import com.google.common.base.Preconditions;
|
||||
import com.google.common.collect.ImmutableSet;
|
||||
@@ -2250,6 +2253,24 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||
@@ -2255,6 +2258,24 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||
public void setViewDistance(int viewDistance) {
|
||||
throw new NotImplementedException("Per-Player View Distance APIs need further understanding to properly implement (There are per world view distances though!)"); // TODO
|
||||
}
|
||||
|
@ -102,10 +102,10 @@ index 69361caebf0d3caa5195b519a16691705ac5e16a..5eb900619951083b9a777b1645cb5495
|
||||
}
|
||||
}
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
index 0b734398905ad4a0e45cb7d17aac8b0c50e4449c..ca60ced988b46c4ef01b1b83a9ce12c5a8170845 100644
|
||||
index dbfd500ad18262e4c1af40308229802fa0cb2e5d..ce02da607d07d22cb0b71e032efa0a8f45148d0c 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
@@ -820,7 +820,8 @@ public class CraftEventFactory {
|
||||
@@ -824,7 +824,8 @@ public class CraftEventFactory {
|
||||
for (org.bukkit.inventory.ItemStack stack : event.getDrops()) {
|
||||
if (stack == null || stack.getType() == Material.AIR || stack.getAmount() == 0) continue;
|
||||
|
||||
|
@ -76,10 +76,10 @@ index a7f5e4a499c1f6fb1450e536dbf117a8af3b3b84..9cc3a18636a356977577076e96cb7be7
|
||||
|
||||
static class b {
|
||||
diff --git a/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java b/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java
|
||||
index c37dd836c284ed8beac6699ec4f5f91886cf3f63..80a9eecfd2eb17db6a7d0b3973f4acdb80f873e8 100644
|
||||
index d2850b003f8672122e70da0d52da1de59b2b01dd..b7c16dfa4ed7d68596c5b5d5037ce0ac3810ecfa 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java
|
||||
+++ b/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java
|
||||
@@ -1031,6 +1031,7 @@ public class EntityVillager extends EntityVillagerAbstract implements Reputation
|
||||
@@ -1038,6 +1038,7 @@ public class EntityVillager extends EntityVillagerAbstract implements Reputation
|
||||
this.bD = 0;
|
||||
}
|
||||
|
||||
|
@ -106,10 +106,10 @@ index cfcb2469569edd51bbb74ca8d7a35a1ec0ecb434..1589d9ca201d386d11d9fd57fa8ba684
|
||||
|
||||
private void a(IInventory iinventory, ItemStack itemstack) {
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
index ca60ced988b46c4ef01b1b83a9ce12c5a8170845..f0c0c69a0d67d90cededdfe602e8fb7382b36c11 100644
|
||||
index ce02da607d07d22cb0b71e032efa0a8f45148d0c..703f2648dde7ad1620e83f88ac4184e5803ed9b4 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
@@ -1526,19 +1526,44 @@ public class CraftEventFactory {
|
||||
@@ -1531,19 +1531,44 @@ public class CraftEventFactory {
|
||||
return event;
|
||||
}
|
||||
|
||||
|
@ -73,10 +73,10 @@ index 92d5a58f7d18aebf06e3cb868abf3f41825f2f84..1d154ef60fd979340cf925748251669e
|
||||
return (!this.player.joining && !this.networkManager.isConnected()) || this.processedDisconnect; // Paper
|
||||
}
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
index ba8c36c9fa7a1fdc3047b14042da8703802f9275..a4726747c066d623f37162e2637403efee7f5708 100644
|
||||
index 54e509091452de26587d16bfd31973cb3909ddd4..a632f6ad9c5d4ce0ae73019ac74db8e14b57b61c 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
@@ -2385,6 +2385,13 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||
@@ -2390,6 +2390,13 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||
// Paper end
|
||||
};
|
||||
|
||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] Fix SpawnChangeEvent not firing for all use-cases
|
||||
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/level/WorldServer.java b/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
index 1a7d06d8a3d1fe0a2a943eae5efd23d28fe4bd62..246708808cbcd9a5c1b8690c869a514d02fddb5c 100644
|
||||
index 5401db70b4516ab960cffae0aae9b3ea297288b5..68a2fef79eae006ea7a8de1fc903e7000b6aab85 100644
|
||||
--- a/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
+++ b/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
@@ -1988,12 +1988,14 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
@@ -1987,12 +1987,14 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
}
|
||||
// Paper end
|
||||
|
||||
|
@ -5,7 +5,7 @@ Subject: [PATCH] Player elytra boost API
|
||||
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
index a4726747c066d623f37162e2637403efee7f5708..204d3e879c736f44e01f9246af26f6cccf8d72a7 100644
|
||||
index a632f6ad9c5d4ce0ae73019ac74db8e14b57b61c..e8512dfde1364c57a6dd263f711d70cf429f9214 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
@@ -69,12 +69,14 @@ import net.minecraft.world.entity.ai.attributes.AttributeMapBase;
|
||||
@ -23,7 +23,7 @@ index a4726747c066d623f37162e2637403efee7f5708..204d3e879c736f44e01f9246af26f6cc
|
||||
import net.minecraft.world.level.biome.BiomeManager;
|
||||
import net.minecraft.world.level.block.entity.TileEntitySign;
|
||||
import net.minecraft.world.level.saveddata.maps.MapIcon;
|
||||
@@ -2281,6 +2283,20 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||
@@ -2286,6 +2288,20 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||
}
|
||||
throw new RuntimeException("Unknown settings type");
|
||||
}
|
||||
|
@ -34,10 +34,10 @@ index 7d34d1157786227ac210edc1595a024ccb61a3e9..ce8a4cc9f642a740947c4e63d6eb78ad
|
||||
this.a.removeInt(reputationtype);
|
||||
}
|
||||
diff --git a/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java b/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java
|
||||
index 382059b2c2b6a7b8231b3c3a5c9a401091b1ad18..2d0b83923d58cc7b6918b4e2ff2bece13ca26899 100644
|
||||
index e24c598c9d662144b91075ac80a193db2e0cb111..3f081177814dc874047e35e294ed18609f082d76 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java
|
||||
+++ b/src/main/java/net/minecraft/world/entity/npc/EntityVillager.java
|
||||
@@ -1007,6 +1007,15 @@ public class EntityVillager extends EntityVillagerAbstract implements Reputation
|
||||
@@ -1014,6 +1014,15 @@ public class EntityVillager extends EntityVillagerAbstract implements Reputation
|
||||
@Override
|
||||
public void a(ReputationEvent reputationevent, Entity entity) {
|
||||
if (reputationevent == ReputationEvent.a) {
|
||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] Add OBSTRUCTED reason to BedEnterResult
|
||||
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
index f0c0c69a0d67d90cededdfe602e8fb7382b36c11..76caad31c073a03ae82ff023042489bd0399f5bc 100644
|
||||
index 703f2648dde7ad1620e83f88ac4184e5803ed9b4..62fcf390e5cf5b76e1f7b34fea856911d9494044 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
@@ -267,6 +267,10 @@ public class CraftEventFactory {
|
||||
@@ -268,6 +268,10 @@ public class CraftEventFactory {
|
||||
return BedEnterResult.TOO_FAR_AWAY;
|
||||
case NOT_SAFE:
|
||||
return BedEnterResult.NOT_SAFE;
|
||||
|
@ -29,7 +29,7 @@ index ccab4714bf5a6be8afd92430874fd6f881d4f92f..223cc0ba06cf4b007049880daad881e5
|
||||
} else {
|
||||
ItemStack itemstack = tileentitydispenser.getItem(i);
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
index 76caad31c073a03ae82ff023042489bd0399f5bc..b7287868c26bc023c423b8ecbdf28ea99b3d1716 100644
|
||||
index 62fcf390e5cf5b76e1f7b34fea856911d9494044..d4b288e127cbd03ded93977fac0c40359525b92d 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
@@ -4,6 +4,7 @@ import com.google.common.base.Function;
|
||||
@ -48,7 +48,7 @@ index 76caad31c073a03ae82ff023042489bd0399f5bc..b7287868c26bc023c423b8ecbdf28ea9
|
||||
import org.bukkit.event.Cancellable;
|
||||
import org.bukkit.event.Event;
|
||||
import org.bukkit.event.Event.Result;
|
||||
@@ -1776,4 +1776,12 @@ public class CraftEventFactory {
|
||||
@@ -1787,4 +1787,12 @@ public class CraftEventFactory {
|
||||
|
||||
return event;
|
||||
}
|
||||
|
@ -18,7 +18,7 @@ index 31012963815a5c7355753b8cd2749976282ef0d2..87722285690d9d3370610e2a2eb809e0
|
||||
interactResult = event.useItemInHand() == Event.Result.DENY;
|
||||
interactPosition = blockposition.immutableCopy();
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
index b7287868c26bc023c423b8ecbdf28ea99b3d1716..08b3adcd1ab8c8872a40b2faecc95471c3236292 100644
|
||||
index d4b288e127cbd03ded93977fac0c40359525b92d..d2f471b8af997cfedaba8e6b5932f8f6079f3392 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
@@ -69,7 +69,9 @@ import net.minecraft.world.level.storage.loot.parameters.LootContextParameters;
|
||||
@ -31,7 +31,7 @@ index b7287868c26bc023c423b8ecbdf28ea99b3d1716..08b3adcd1ab8c8872a40b2faecc95471
|
||||
import org.bukkit.Material;
|
||||
import org.bukkit.NamespacedKey;
|
||||
import org.bukkit.Server;
|
||||
@@ -483,7 +485,13 @@ public class CraftEventFactory {
|
||||
@@ -484,7 +486,13 @@ public class CraftEventFactory {
|
||||
return callPlayerInteractEvent(who, action, position, direction, itemstack, false, hand);
|
||||
}
|
||||
|
||||
@ -45,7 +45,7 @@ index b7287868c26bc023c423b8ecbdf28ea99b3d1716..08b3adcd1ab8c8872a40b2faecc95471
|
||||
Player player = (who == null) ? null : (Player) who.getBukkitEntity();
|
||||
CraftItemStack itemInHand = CraftItemStack.asCraftMirror(itemstack);
|
||||
|
||||
@@ -509,7 +517,10 @@ public class CraftEventFactory {
|
||||
@@ -510,7 +518,10 @@ public class CraftEventFactory {
|
||||
itemInHand = null;
|
||||
}
|
||||
|
||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] Remove stale POIs
|
||||
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/level/WorldServer.java b/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
index 4a87b9ebc2a584d8a2fca874342057e81fbbc1c6..c38ef337f9a662d689994a0d530e8e655b843177 100644
|
||||
index 7942f492f7688fab52acbefbe5703221b0435752..530963c1435985e17d0e3181c2d8affe003f81de 100644
|
||||
--- a/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
+++ b/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
@@ -2078,6 +2078,11 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
@@ -2077,6 +2077,11 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
});
|
||||
optional1.ifPresent((villageplacetype) -> {
|
||||
this.getMinecraftServer().execute(() -> {
|
||||
@ -20,7 +20,7 @@ index 4a87b9ebc2a584d8a2fca874342057e81fbbc1c6..c38ef337f9a662d689994a0d530e8e65
|
||||
this.y().a(blockposition1, villageplacetype);
|
||||
PacketDebug.a(this, blockposition1);
|
||||
});
|
||||
@@ -2085,6 +2090,7 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
@@ -2084,6 +2089,7 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -32,10 +32,10 @@ index 0757cfcb96778258ba2593756e4ca9cbb16e2f87..24b3a893a2b76a4ecfbc6b2cc1eac242
|
||||
|
||||
// Paper start
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
index 5a245184d6290a58bb9aed139cc4c7b5511ce491..e97ad53eb8bdc4c71d8014d060710cb3a29ab7f8 100644
|
||||
index aff89527372faeb1e1be0f5cd1618c637a000979..b4d4fac69439c2256ab31f93f94db5b314f76f0e 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
@@ -2297,6 +2297,13 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||
@@ -2302,6 +2302,13 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||
? (org.bukkit.entity.Firework) entity.getBukkitEntity()
|
||||
: null;
|
||||
}
|
||||
|
@ -1,58 +0,0 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Aikar <aikar@aikar.co>
|
||||
Date: Sat, 16 Jan 2021 14:30:12 -0500
|
||||
Subject: [PATCH] Make ProjectileHitEvent Cancellable
|
||||
|
||||
Allows cancelling things like detonating TNT from Fire Arrows
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/world/entity/projectile/EntityFireball.java b/src/main/java/net/minecraft/world/entity/projectile/EntityFireball.java
|
||||
index 09e547a299286c47750325fe3c44ee9cd45748a0..c4248531d4a6a11259d9d78ce1d7683a86840d40 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/projectile/EntityFireball.java
|
||||
+++ b/src/main/java/net/minecraft/world/entity/projectile/EntityFireball.java
|
||||
@@ -87,7 +87,7 @@ public abstract class EntityFireball extends IProjectile {
|
||||
|
||||
// CraftBukkit start - Fire ProjectileHitEvent
|
||||
if (this.dead) {
|
||||
- CraftEventFactory.callProjectileHitEvent(this, movingobjectposition);
|
||||
+ if (!CraftEventFactory.callProjectileHitEvent(this, movingobjectposition)) return; // Paper - this is an undesired duplicate event, but make cancellable
|
||||
}
|
||||
// CraftBukkit end
|
||||
}
|
||||
diff --git a/src/main/java/net/minecraft/world/entity/projectile/IProjectile.java b/src/main/java/net/minecraft/world/entity/projectile/IProjectile.java
|
||||
index 37b1febb45b900dfe4b225152e66bc4be83df220..9f2e7d345d98f50e6d47cbf4bb35714852fa42da 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/projectile/IProjectile.java
|
||||
+++ b/src/main/java/net/minecraft/world/entity/projectile/IProjectile.java
|
||||
@@ -130,7 +130,7 @@ public abstract class IProjectile extends Entity {
|
||||
}
|
||||
|
||||
protected void a(MovingObjectPosition movingobjectposition) {
|
||||
- org.bukkit.craftbukkit.event.CraftEventFactory.callProjectileHitEvent(this, movingobjectposition); // CraftBukkit - Call event
|
||||
+ if (!org.bukkit.craftbukkit.event.CraftEventFactory.callProjectileHitEvent(this, movingobjectposition)) return; // CraftBukkit - Call event // Paper - make cancellable
|
||||
MovingObjectPosition.EnumMovingObjectType movingobjectposition_enummovingobjecttype = movingobjectposition.getType();
|
||||
|
||||
if (movingobjectposition_enummovingobjecttype == MovingObjectPosition.EnumMovingObjectType.ENTITY) {
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
index 08b3adcd1ab8c8872a40b2faecc95471c3236292..5f40bc588971bae14e500755697db3290aa4af3b 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
@@ -1312,9 +1312,9 @@ public class CraftEventFactory {
|
||||
return event;
|
||||
}
|
||||
|
||||
- public static void callProjectileHitEvent(Entity entity, MovingObjectPosition position) {
|
||||
+ public static boolean callProjectileHitEvent(Entity entity, MovingObjectPosition position) { // Paper - make cancellable
|
||||
if (position.getType() == MovingObjectPosition.EnumMovingObjectType.MISS) {
|
||||
- return;
|
||||
+ return false; // Paper - make cancellable
|
||||
}
|
||||
|
||||
Block hitBlock = null;
|
||||
@@ -1331,7 +1331,7 @@ public class CraftEventFactory {
|
||||
}
|
||||
|
||||
ProjectileHitEvent event = new ProjectileHitEvent((Projectile) entity.getBukkitEntity(), hitEntity, hitBlock, hitFace);
|
||||
- entity.world.getServer().getPluginManager().callEvent(event);
|
||||
+ return event.callEvent(); // Paper
|
||||
}
|
||||
|
||||
public static ExpBottleEvent callExpBottleEvent(Entity entity, int exp) {
|
@ -0,0 +1,20 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: Aikar <aikar@aikar.co>
|
||||
Date: Sat, 16 Jan 2021 14:30:12 -0500
|
||||
Subject: [PATCH] Respect ProjectileHitEvent cancel where missing
|
||||
|
||||
The duplicate ProjectileHitEvent in EntityFireball was not cancelled
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/world/entity/projectile/EntityFireball.java b/src/main/java/net/minecraft/world/entity/projectile/EntityFireball.java
|
||||
index 9660dc2263c48a5818b767843658eeb9ee1748ea..243b24e7c304b379aeb925fe1e2435853f80397d 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/projectile/EntityFireball.java
|
||||
+++ b/src/main/java/net/minecraft/world/entity/projectile/EntityFireball.java
|
||||
@@ -87,7 +87,7 @@ public abstract class EntityFireball extends IProjectile {
|
||||
|
||||
// CraftBukkit start - Fire ProjectileHitEvent
|
||||
if (this.dead) {
|
||||
- CraftEventFactory.callProjectileHitEvent(this, movingobjectposition);
|
||||
+ if (CraftEventFactory.callProjectileHitEvent(this, movingobjectposition).isCancelled()) return; // Paper - this is an undesired duplicate event, but make cancellable
|
||||
}
|
||||
// CraftBukkit end
|
||||
}
|
@ -17,7 +17,7 @@ index 966051ab3e720e5b3f0fb9ab852c8908c5f23f3b..9b92824f1c2797e321ced953d33d2c2f
|
||||
tileentitydispenser.setItem(i, idispensebehavior.dispense(sourceblock, itemstack));
|
||||
}
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
index 5f40bc588971bae14e500755697db3290aa4af3b..8afb966d6fc8787b7f427c756d82c37e9313ae67 100644
|
||||
index d2f471b8af997cfedaba8e6b5932f8f6079f3392..f0ab3d42bc34bf8c1b81642e600360110a88115b 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
@@ -70,6 +70,7 @@ import net.minecraft.world.phys.MovingObjectPosition;
|
||||
@ -28,7 +28,7 @@ index 5f40bc588971bae14e500755697db3290aa4af3b..8afb966d6fc8787b7f427c756d82c37e
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.Location; // Paper
|
||||
import org.bukkit.Material;
|
||||
@@ -1794,5 +1795,11 @@ public class CraftEventFactory {
|
||||
@@ -1805,5 +1806,11 @@ public class CraftEventFactory {
|
||||
BlockFailedDispenseEvent event = new BlockFailedDispenseEvent(block);
|
||||
return event.callEvent();
|
||||
}
|
||||
|
@ -138,10 +138,10 @@ index 8f6d2a6a388021f437ac5554e9ece8eca89e1f46..519f0cabadcf97a44a112fd963a8d3ab
|
||||
}
|
||||
}
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
index 8afb966d6fc8787b7f427c756d82c37e9313ae67..1c018288927fc142ed094a911d710b13a4a30919 100644
|
||||
index f0ab3d42bc34bf8c1b81642e600360110a88115b..bbc7f97748f5b61047a9b01a2ecb8c2d0a7b677c 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
@@ -1464,8 +1464,10 @@ public class CraftEventFactory {
|
||||
@@ -1469,8 +1469,10 @@ public class CraftEventFactory {
|
||||
return itemInHand;
|
||||
}
|
||||
|
||||
|
@ -19,10 +19,10 @@ index 1ceacb6bbfe99069763845a8aef48a3fb4841e32..d2f6e1308a4dfec663770e2c7f4de0cf
|
||||
+ }
|
||||
}
|
||||
diff --git a/src/main/java/net/minecraft/server/level/WorldServer.java b/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
index bab75b2232f1fa1def09517610179ca1529d195e..bea183ba796f2acf5465ad91e4e7fe3e73c9da74 100644
|
||||
index c7a661d4f43fad04ebada1bbebf4e4274fc9c452..325eba4e30ddcdfd038a215fbfde3bdc3e7c9b2a 100644
|
||||
--- a/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
+++ b/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
@@ -1685,6 +1685,7 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
@@ -1684,6 +1684,7 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
@Override
|
||||
public void notify(BlockPosition blockposition, IBlockData iblockdata, IBlockData iblockdata1, int i) {
|
||||
this.getChunkProvider().flagDirty(blockposition);
|
||||
@ -30,7 +30,7 @@ index bab75b2232f1fa1def09517610179ca1529d195e..bea183ba796f2acf5465ad91e4e7fe3e
|
||||
VoxelShape voxelshape = iblockdata.getCollisionShape(this, blockposition);
|
||||
VoxelShape voxelshape1 = iblockdata1.getCollisionShape(this, blockposition);
|
||||
|
||||
@@ -1713,6 +1714,7 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
@@ -1712,6 +1713,7 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
|
||||
this.tickingEntities = wasTicking; // Paper
|
||||
}
|
||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] Allow adding items to BlockDropItemEvent
|
||||
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
index 1c018288927fc142ed094a911d710b13a4a30919..ac89b7f0de0e5015c599648dc93cbcae760744f2 100644
|
||||
index bbc7f97748f5b61047a9b01a2ecb8c2d0a7b677c..b14cec316b16e46d54d389650372c5c9ce1e5a4d 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
|
||||
@@ -397,13 +397,30 @@ public class CraftEventFactory {
|
||||
@@ -398,13 +398,30 @@ public class CraftEventFactory {
|
||||
}
|
||||
|
||||
public static void handleBlockDropItemEvent(Block block, BlockState state, EntityPlayer player, List<EntityItem> items) {
|
||||
|
@ -18,7 +18,7 @@ index f7223f214f911dd25abcf3a52745588ec630241d..7abeeefeb579a43bc9ee85fd4150afac
|
||||
public Throwable addedToWorldStack; // Paper - entity debug
|
||||
public CraftEntity getBukkitEntity() {
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
index e97ad53eb8bdc4c71d8014d060710cb3a29ab7f8..e5549439b3d4d608cf37dd33b6c8c9e10dfe9328 100644
|
||||
index b4d4fac69439c2256ab31f93f94db5b314f76f0e..f150ba393bc62e52840e6ebbf3d7696b670ff7e4 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||
@@ -16,6 +16,7 @@ import java.net.InetSocketAddress;
|
||||
@ -29,7 +29,7 @@ index e97ad53eb8bdc4c71d8014d060710cb3a29ab7f8..e5549439b3d4d608cf37dd33b6c8c9e1
|
||||
import java.util.HashMap;
|
||||
import java.util.HashSet;
|
||||
import java.util.LinkedHashMap;
|
||||
@@ -2306,6 +2307,21 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||
@@ -2311,6 +2312,21 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||
}
|
||||
// Paper end
|
||||
|
||||
|
@ -5,10 +5,10 @@ Subject: [PATCH] More World API
|
||||
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/level/WorldServer.java b/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
index bea183ba796f2acf5465ad91e4e7fe3e73c9da74..47fbb8df04b2b77e10314666e87eaef621cffb3b 100644
|
||||
index 325eba4e30ddcdfd038a215fbfde3bdc3e7c9b2a..7e032845fe9a46d33236444d62405a41e29daa17 100644
|
||||
--- a/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
+++ b/src/main/java/net/minecraft/server/level/WorldServer.java
|
||||
@@ -1870,6 +1870,7 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
@@ -1869,6 +1869,7 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
return !this.worldDataServer.getGeneratorSettings().shouldGenerateMapFeatures() ? null : this.getChunkProvider().getChunkGenerator().findNearestMapFeature(this, structuregenerator, blockposition, i, flag); // CraftBukkit
|
||||
}
|
||||
|
||||
@ -16,7 +16,7 @@ index bea183ba796f2acf5465ad91e4e7fe3e73c9da74..47fbb8df04b2b77e10314666e87eaef6
|
||||
@Nullable
|
||||
public BlockPosition a(BiomeBase biomebase, BlockPosition blockposition, int i, int j) {
|
||||
return this.getChunkProvider().getChunkGenerator().getWorldChunkManager().a(blockposition.getX(), blockposition.getY(), blockposition.getZ(), i, j, (biomebase1) -> {
|
||||
@@ -1892,6 +1893,7 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
@@ -1891,6 +1892,7 @@ public class WorldServer extends World implements GeneratorAccessSeed {
|
||||
return this.savingDisabled;
|
||||
}
|
||||
|
||||
|
@ -1 +1 @@
|
||||
Subproject commit 5eece9f8580658aff45ba851b79059c0e16b921a
|
||||
Subproject commit b9ef9229d4c10b4068d9fbdce8845cfd4a9f8fc5
|
Einige Dateien werden nicht angezeigt, da zu viele Dateien in diesem Diff geändert wurden Mehr anzeigen
In neuem Issue referenzieren
Einen Benutzer sperren