mirror of
https://github.com/curioustorvald/Terrarum.git
synced 2026-06-18 22:44:04 +09:00
fluids to their own block layer
This commit is contained in:
@@ -66,11 +66,7 @@ class BlockLayerI16I8 (val width: Int, val height: Int) : BlockLayer {
|
||||
|
||||
override fun unsafeToBytes(x: Int, y: Int): ByteArray {
|
||||
val offset = BYTES_PER_BLOCK * (y * width + x)
|
||||
val lsb = ptr[offset]
|
||||
val msb = ptr[offset + 1]
|
||||
val placement = ptr[offset + 2]
|
||||
|
||||
return byteArrayOf(msb, lsb, placement)
|
||||
return byteArrayOf(ptr[offset + 1], ptr[offset + 0], ptr[offset + 2])
|
||||
}
|
||||
|
||||
internal fun unsafeSetTile(x: Int, y: Int, tile: Int, placement: Int) {
|
||||
|
||||
Reference in New Issue
Block a user