diff options
| author | Linnea Gräf <nea@nea.moe> | 2025-03-22 18:10:06 +0100 |
|---|---|---|
| committer | Linnea Gräf <nea@nea.moe> | 2025-03-22 18:10:06 +0100 |
| commit | 40ac97026918f89a6bef77ce660efe0df6e4e6ef (patch) | |
| tree | abc407541f90825a33e925ddcb5e0480a4abe51f /src/main/kotlin/features/world/FirmWaypoints.kt | |
| parent | 487a900f15d5e2f9af2a947521e73aa6d3ece6ee (diff) | |
| download | Firmament-40ac97026918f89a6bef77ce660efe0df6e4e6ef.tar.gz Firmament-40ac97026918f89a6bef77ce660efe0df6e4e6ef.tar.bz2 Firmament-40ac97026918f89a6bef77ce660efe0df6e4e6ef.zip | |
feat: Add firmament waypoint import / export that remembers relative waypoints
Diffstat (limited to 'src/main/kotlin/features/world/FirmWaypoints.kt')
| -rw-r--r-- | src/main/kotlin/features/world/FirmWaypoints.kt | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/main/kotlin/features/world/FirmWaypoints.kt b/src/main/kotlin/features/world/FirmWaypoints.kt index 1f368f6..d149501 100644 --- a/src/main/kotlin/features/world/FirmWaypoints.kt +++ b/src/main/kotlin/features/world/FirmWaypoints.kt @@ -1,7 +1,10 @@ package moe.nea.firmament.features.world +import kotlinx.serialization.Serializable +import kotlinx.serialization.Transient import net.minecraft.util.math.BlockPos +@Serializable data class FirmWaypoints( var label: String, var id: String, @@ -13,7 +16,11 @@ data class FirmWaypoints( var isOrdered: Boolean, // TODO: val resetOnSwap: Boolean, ) { + @Transient + var lastRelativeImport: BlockPos? = null + val size get() = waypoints.size + @Serializable data class Waypoint( val x: Int, val y: Int, |
