mirror of
https://github.com/PaperMC/Paper.git
synced 2024-11-23 02:55:47 +01:00
Restore portal fix
This commit is contained in:
parent
4bb44d2fcb
commit
646ddfd6f9
@ -1,11 +1,11 @@
|
||||
From cb5d0df8f262c31ce24f9cd39a70d2974420b95f Mon Sep 17 00:00:00 2001
|
||||
From 0e37166c412ab13ae4514136d1313cf404909ef7 Mon Sep 17 00:00:00 2001
|
||||
From: MiniDigger <admin@minidigger.me>
|
||||
Date: Sun, 18 Mar 2018 15:44:44 +0100
|
||||
Subject: [PATCH] Call PortalCreateEvent for exit portals
|
||||
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/PortalTravelAgent.java b/src/main/java/net/minecraft/server/PortalTravelAgent.java
|
||||
index 402d8d7d63..7444f4621e 100644
|
||||
index 402d8d7d..72b85bf6 100644
|
||||
--- a/src/main/java/net/minecraft/server/PortalTravelAgent.java
|
||||
+++ b/src/main/java/net/minecraft/server/PortalTravelAgent.java
|
||||
@@ -48,6 +48,9 @@ public class PortalTravelAgent {
|
||||
@ -25,7 +25,7 @@ index 402d8d7d63..7444f4621e 100644
|
||||
- this.world.setTypeUpdate(new BlockPosition(k1, l1, i2), flag2 ? Blocks.OBSIDIAN.getBlockData() : Blocks.AIR.getBlockData());
|
||||
+ // Paper start
|
||||
+ BlockPosition pos = new BlockPosition(k1, l1, i2);
|
||||
+ nmsBlocks.putIfAbsent(pos, flag2 ? Blocks.OBSIDIAN.getBlockData() : Blocks.AIR.getBlockData());
|
||||
+ nmsBlocks.put(pos, flag2 ? Blocks.OBSIDIAN.getBlockData() : Blocks.AIR.getBlockData());
|
||||
+ bukkitBlocks.add(this.world.getWorld().getBlockAt(pos.getX(), pos.getY(), pos.getZ()));
|
||||
+ // Paper end
|
||||
}
|
||||
@ -60,7 +60,7 @@ index 402d8d7d63..7444f4621e 100644
|
||||
- this.world.setTypeUpdate(blockposition_mutableblockposition, flag1 ? Blocks.OBSIDIAN.getBlockData() : Blocks.AIR.getBlockData());
|
||||
+ // Paper start
|
||||
+ BlockPosition pos = new BlockPosition(j3, k3, l3);
|
||||
+ nmsBlocks.putIfAbsent(pos, flag1 ? Blocks.OBSIDIAN.getBlockData() : Blocks.AIR.getBlockData());
|
||||
+ nmsBlocks.put(pos, flag1 ? Blocks.OBSIDIAN.getBlockData() : Blocks.AIR.getBlockData());
|
||||
+ bukkitBlocks.add(this.world.getWorld().getBlockAt(pos.getX(), pos.getY(), pos.getZ()));
|
||||
+ // Paper end
|
||||
}
|
||||
@ -73,7 +73,7 @@ index 402d8d7d63..7444f4621e 100644
|
||||
- this.world.setTypeAndData(blockposition_mutableblockposition, Blocks.OBSIDIAN.getBlockData(), 3);
|
||||
+ // Paper start
|
||||
+ BlockPosition pos = new BlockPosition(blockposition_mutableblockposition.getX(), blockposition_mutableblockposition.getY(), blockposition_mutableblockposition.getZ());
|
||||
+ nmsBlocks.putIfAbsent(pos, Blocks.OBSIDIAN.getBlockData());
|
||||
+ nmsBlocks.put(pos, Blocks.OBSIDIAN.getBlockData());
|
||||
+ bukkitBlocks.add(this.world.getWorld().getBlockAt(pos.getX(), pos.getY(), pos.getZ()));
|
||||
+ // Paper end
|
||||
}
|
||||
@ -87,7 +87,7 @@ index 402d8d7d63..7444f4621e 100644
|
||||
+
|
||||
+ // Paper start
|
||||
+ BlockPosition pos = new BlockPosition(blockposition_mutableblockposition.getX(), blockposition_mutableblockposition.getY(), blockposition_mutableblockposition.getZ());
|
||||
+ nmsBlocks.putIfAbsent(pos, iblockdata);
|
||||
+ nmsBlocks.put(pos, iblockdata);
|
||||
+ bukkitBlocks.add(this.world.getWorld().getBlockAt(pos.getX(), pos.getY(), pos.getZ()));
|
||||
+ // Paper end
|
||||
}
|
||||
@ -104,5 +104,5 @@ index 402d8d7d63..7444f4621e 100644
|
||||
}
|
||||
|
||||
--
|
||||
2.18.0
|
||||
2.18.0.windows.1
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user