Mirror von
https://github.com/PaperMC/Paper.git
synchronisiert 2024-12-18 20:40:08 +01:00
Removed Block.getRawData
Dieser Commit ist enthalten in:
Ursprung
332b0c2ca9
Commit
770bb9e3b5
@ -347,8 +347,8 @@ public class NetServerHandler extends NetHandler implements ICommandListener {
|
|||||||
// if we are destroying either a redstone wire with a current greater than 0 or
|
// if we are destroying either a redstone wire with a current greater than 0 or
|
||||||
// a redstone torch that is on, then we should notify plugins that this block has
|
// a redstone torch that is on, then we should notify plugins that this block has
|
||||||
// returned to a current value of 0 (since it will once the redstone is destroyed)
|
// returned to a current value of 0 (since it will once the redstone is destroyed)
|
||||||
if ((blockId == Block.REDSTONE_WIRE.id && block.getRawData() > 0) || blockId == Block.REDSTONE_TORCH_ON.id) {
|
if ((blockId == Block.REDSTONE_WIRE.id && block.getData() > 0) || blockId == Block.REDSTONE_TORCH_ON.id) {
|
||||||
server.getPluginManager().callEvent( new BlockRedstoneEvent(block, (blockId == Block.REDSTONE_WIRE.id ? block.getRawData() : 15), 0));
|
server.getPluginManager().callEvent( new BlockRedstoneEvent(block, (blockId == Block.REDSTONE_WIRE.id ? block.getData() : 15), 0));
|
||||||
}
|
}
|
||||||
event = new BlockDamageEvent(Type.BLOCK_DAMAGED, block, BlockDamageLevel.BROKEN, player);
|
event = new BlockDamageEvent(Type.BLOCK_DAMAGED, block, BlockDamageLevel.BROKEN, player);
|
||||||
} else {
|
} else {
|
||||||
|
@ -95,7 +95,7 @@ public class CraftBlock implements Block {
|
|||||||
*
|
*
|
||||||
* @return block specific metadata
|
* @return block specific metadata
|
||||||
*/
|
*/
|
||||||
public byte getRawData() {
|
public byte getData() {
|
||||||
return (byte) chunk.getHandle().b(this.x & 0xF, this.y & 0x7F, this.z & 0xF);
|
return (byte) chunk.getHandle().b(this.x & 0xF, this.y & 0x7F, this.z & 0xF);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -354,9 +354,4 @@ public class CraftBlock implements Block {
|
|||||||
public boolean isBlockFaceIndirectlyPowered(BlockFace face) {
|
public boolean isBlockFaceIndirectlyPowered(BlockFace face) {
|
||||||
return chunk.getHandle().d.j(x, y, z, blockFaceToNotch(face));
|
return chunk.getHandle().d.j(x, y, z, blockFaceToNotch(face));
|
||||||
}
|
}
|
||||||
|
|
||||||
@Deprecated
|
|
||||||
public byte getData() {
|
|
||||||
return getRawData();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
@ -30,7 +30,7 @@ public class CraftBlockState implements BlockState {
|
|||||||
this.light = block.getLightLevel();
|
this.light = block.getLightLevel();
|
||||||
this.chunk = (CraftChunk)block.getChunk();
|
this.chunk = (CraftChunk)block.getChunk();
|
||||||
|
|
||||||
createData(block.getRawData());
|
createData(block.getData());
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren