aboutsummaryrefslogtreecommitdiff
path: root/src/main/kotlin/moe/nea/notenoughupdates/util/SBData.kt
diff options
context:
space:
mode:
authornea <nea@nea.moe>2023-05-03 00:52:37 +0200
committernea <nea@nea.moe>2023-05-03 00:52:49 +0200
commit3be33bb522f468b812bb59b7f2edc8d1ca352661 (patch)
tree1292a52cb661ab71584b1ae248204e18b869afe1 /src/main/kotlin/moe/nea/notenoughupdates/util/SBData.kt
parenta8ab8f3d6326211f6e07694c64ebd8b6ba195988 (diff)
downloadfirmament-3be33bb522f468b812bb59b7f2edc8d1ca352661.tar.gz
firmament-3be33bb522f468b812bb59b7f2edc8d1ca352661.tar.bz2
firmament-3be33bb522f468b812bb59b7f2edc8d1ca352661.zip
Modernize and 1.19.4ify
Diffstat (limited to 'src/main/kotlin/moe/nea/notenoughupdates/util/SBData.kt')
-rw-r--r--src/main/kotlin/moe/nea/notenoughupdates/util/SBData.kt15
1 files changed, 1 insertions, 14 deletions
diff --git a/src/main/kotlin/moe/nea/notenoughupdates/util/SBData.kt b/src/main/kotlin/moe/nea/notenoughupdates/util/SBData.kt
index 5aad7fc..6d4af7e 100644
--- a/src/main/kotlin/moe/nea/notenoughupdates/util/SBData.kt
+++ b/src/main/kotlin/moe/nea/notenoughupdates/util/SBData.kt
@@ -1,14 +1,11 @@
package moe.nea.notenoughupdates.util
-import java.time.Instant
import kotlinx.serialization.SerializationException
import kotlinx.serialization.decodeFromString
import kotlin.time.Duration
import kotlin.time.Duration.Companion.seconds
import kotlin.time.ExperimentalTime
import kotlin.time.TimeSource
-import net.minecraft.network.message.ArgumentSignatureDataMap
-import net.minecraft.network.packet.c2s.play.CommandExecutionC2SPacket
import moe.nea.notenoughupdates.NotEnoughUpdates
import moe.nea.notenoughupdates.events.ServerChatLineReceivedEvent
import moe.nea.notenoughupdates.events.SkyblockServerUpdateEvent
@@ -62,17 +59,7 @@ object SBData {
fun sendLocraw() {
lastLocrawSent = TimeSource.Monotonic.markNow()
val nh = MC.player?.networkHandler ?: return
- val ack = nh.consumeAcknowledgment()
- nh.sendPacket(
- CommandExecutionC2SPacket(
- "locraw",
- Instant.now(),
- 0L,
- ArgumentSignatureDataMap.EMPTY,
- false,
- ack
- )
- )
+nh.sendChatCommand("locraw")
}