Gjallarhorn: Timelapse Mode

This commit is contained in:
Kenneth Endfinger
2022-01-07 06:15:26 -05:00
parent cc6fbaae83
commit bc2d3e28ae
26 changed files with 251 additions and 163 deletions

View File

@ -1,7 +1,6 @@
package cloud.kubelet.foundation.heimdall.event
import cloud.kubelet.foundation.heimdall.storageBlockName
import cloud.kubelet.foundation.heimdall.table.BlockBreakTable
import cloud.kubelet.foundation.heimdall.table.BlockPlaceTable
import org.bukkit.Location
import org.bukkit.Material
@ -22,15 +21,15 @@ class BlockPlace(
override fun store(transaction: Transaction) {
transaction.apply {
BlockPlaceTable.insert {
it[BlockBreakTable.time] = timestamp
it[BlockBreakTable.player] = playerUniqueIdentity
it[BlockBreakTable.world] = location.world.uid
it[BlockBreakTable.x] = location.x
it[BlockBreakTable.y] = location.y
it[BlockBreakTable.z] = location.z
it[BlockBreakTable.pitch] = location.pitch.toDouble()
it[BlockBreakTable.yaw] = location.yaw.toDouble()
it[BlockBreakTable.block] = material.storageBlockName
it[time] = timestamp
it[player] = playerUniqueIdentity
it[world] = location.world.uid
it[x] = location.x
it[y] = location.y
it[z] = location.z
it[pitch] = location.pitch.toDouble()
it[yaw] = location.yaw.toDouble()
it[block] = material.storageBlockName
}
}
}