mirror of
https://github.com/PaperMC/Paper.git
synced 2025-01-10 10:17:38 +01:00
[Slightly breaking] setType(Id) will not longer reuse the previous data value
of the block and instead reset the the data value to the block's default By: Thinkofdeath <thinkofdeath@spigotmc.org>
This commit is contained in:
parent
503f116feb
commit
05d746d1e4
@ -121,7 +121,8 @@ public class CraftBlock implements Block {
|
||||
}
|
||||
|
||||
public boolean setTypeId(final int type, final boolean applyPhysics) {
|
||||
return setTypeIdAndData(type, getData(), applyPhysics);
|
||||
net.minecraft.server.Block block = getNMSBlock(type);
|
||||
return setTypeIdAndData(type, (byte) block.toLegacyData(block.getBlockData()), applyPhysics);
|
||||
}
|
||||
|
||||
public boolean setTypeIdAndData(final int type, final byte data, final boolean applyPhysics) {
|
||||
|
Loading…
Reference in New Issue
Block a user