mirror of
https://github.com/PurpurMC/Purpur.git
synced 2026-02-17 16:37:43 +01:00
[ci-skip] fix this too, now.. jfc
This commit is contained in:
@@ -534,7 +534,7 @@ index 28a1fe3af1546daa779df46468e0ff8ad823f9ca..7a3be414ef9d54d7a852ba92d704011f
|
||||
|
||||
@NotNull
|
||||
diff --git a/src/main/java/org/bukkit/UnsafeValues.java b/src/main/java/org/bukkit/UnsafeValues.java
|
||||
index 6dbd520182b1e7713a68baad09b7f613424ef619..7899609b7a3041477d5240deaeee9b80159c2db3 100644
|
||||
index 6dbd520182b1e7713a68baad09b7f613424ef619..14244cc7f11035c4da4613bbdf49dac51f0da3cf 100644
|
||||
--- a/src/main/java/org/bukkit/UnsafeValues.java
|
||||
+++ b/src/main/java/org/bukkit/UnsafeValues.java
|
||||
@@ -87,6 +87,8 @@ public interface UnsafeValues {
|
||||
@@ -582,35 +582,6 @@ index 6dbd520182b1e7713a68baad09b7f613424ef619..7899609b7a3041477d5240deaeee9b80
|
||||
*/
|
||||
public int nextEntityId();
|
||||
|
||||
@@ -162,4 +172,28 @@ public interface UnsafeValues {
|
||||
*/
|
||||
int getProtocolVersion();
|
||||
// Paper end
|
||||
+
|
||||
+ // Purpur start
|
||||
+
|
||||
+ /**
|
||||
+ * Serialize entity to byte array
|
||||
+ *
|
||||
+ * @param entity entity to serialize
|
||||
+ * @return serialized entity
|
||||
+ */
|
||||
+ byte[] serializeEntity(org.bukkit.entity.Entity entity);
|
||||
+
|
||||
+ /**
|
||||
+ * Deserialize an entity from byte array
|
||||
+ * <p>
|
||||
+ * The entity is not automatically spawned in the world. You will have to spawn
|
||||
+ * the entity yourself with {@link org.bukkit.entity.Entity#spawnAt(Location)} or
|
||||
+ * {@link org.bukkit.entity.Entity#spawnAt(Location, org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason)}
|
||||
+ *
|
||||
+ * @param data serialized entity
|
||||
+ * @param world world entity belongs in
|
||||
+ * @return deserialized entity
|
||||
+ */
|
||||
+ org.bukkit.entity.Entity deserializeEntity(byte[] data, org.bukkit.World world);
|
||||
+ // Purpur end
|
||||
}
|
||||
diff --git a/src/main/java/org/bukkit/WorldBorder.java b/src/main/java/org/bukkit/WorldBorder.java
|
||||
index afb7b136b461202026290624836446cff9f9e45d..087579fdff09237409c9f80446e7a15a78f9040c 100644
|
||||
--- a/src/main/java/org/bukkit/WorldBorder.java
|
||||
|
||||
@@ -16,6 +16,39 @@ GNU General Public License for more details.
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/UnsafeValues.java b/src/main/java/org/bukkit/UnsafeValues.java
|
||||
index 14244cc7f11035c4da4613bbdf49dac51f0da3cf..7899609b7a3041477d5240deaeee9b80159c2db3 100644
|
||||
--- a/src/main/java/org/bukkit/UnsafeValues.java
|
||||
+++ b/src/main/java/org/bukkit/UnsafeValues.java
|
||||
@@ -172,4 +172,28 @@ public interface UnsafeValues {
|
||||
*/
|
||||
int getProtocolVersion();
|
||||
// Paper end
|
||||
+
|
||||
+ // Purpur start
|
||||
+
|
||||
+ /**
|
||||
+ * Serialize entity to byte array
|
||||
+ *
|
||||
+ * @param entity entity to serialize
|
||||
+ * @return serialized entity
|
||||
+ */
|
||||
+ byte[] serializeEntity(org.bukkit.entity.Entity entity);
|
||||
+
|
||||
+ /**
|
||||
+ * Deserialize an entity from byte array
|
||||
+ * <p>
|
||||
+ * The entity is not automatically spawned in the world. You will have to spawn
|
||||
+ * the entity yourself with {@link org.bukkit.entity.Entity#spawnAt(Location)} or
|
||||
+ * {@link org.bukkit.entity.Entity#spawnAt(Location, org.bukkit.event.entity.CreatureSpawnEvent.SpawnReason)}
|
||||
+ *
|
||||
+ * @param data serialized entity
|
||||
+ * @param world world entity belongs in
|
||||
+ * @return deserialized entity
|
||||
+ */
|
||||
+ org.bukkit.entity.Entity deserializeEntity(byte[] data, org.bukkit.World world);
|
||||
+ // Purpur end
|
||||
}
|
||||
diff --git a/src/main/java/org/bukkit/entity/Entity.java b/src/main/java/org/bukkit/entity/Entity.java
|
||||
index b47e31d2b9b41b39b46892fe10bf36d82c5d8e1b..7fa5242bd44c9b19648d79fa8fecbb7ee125288e 100644
|
||||
--- a/src/main/java/org/bukkit/entity/Entity.java
|
||||
|
||||
Reference in New Issue
Block a user