Fix sending DeviceRemovedPacket on client

This commit is contained in:
Shadowfacts 2021-02-14 16:04:03 -05:00
parent e0dfefb72b
commit 0dcb647de4
Signed by: shadowfacts
GPG Key ID: 94A5AB95422746E5
1 changed files with 3 additions and 1 deletions

View File

@ -161,7 +161,9 @@ abstract class DeviceBlockEntity(type: BlockEntityType<*>): BlockEntity(type),
} }
fun onBreak() { fun onBreak() {
sendPacket(DeviceRemovedPacket(this)) if (!world!!.isClient) {
sendPacket(DeviceRemovedPacket(this))
}
} }
data class PendingPacket( data class PendingPacket(