Skip to content

Commit

Permalink
Update to 1.21
Browse files Browse the repository at this point in the history
  • Loading branch information
andantet committed Jun 1, 2024
1 parent 96275cc commit 0a3d1fa
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 8 deletions.
10 changes: 5 additions & 5 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@ org.gradle.parallel=true

# Fabric Properties
# check these on https://fabricmc.net/develop
minecraft_version=1.20.5-rc2
yarn_build=1
loader_version=0.15.10
fabric_kotlin_version=1.10.19+kotlin.1.9.23
minecraft_version=1.21-pre2
yarn_build=2
loader_version=0.15.11
fabric_kotlin_version=1.10.20+kotlin.1.9.24

# Mod Properties
mod_version=1.5.0
mod_version=1.6.0
maven_group=dev.andante
4 changes: 1 addition & 3 deletions src/main/kotlin/dev/andante/codex/Codex.kt
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
package dev.andante.codex

import com.mojang.datafixers.util.Pair
import com.mojang.serialization.Codec
import com.mojang.serialization.Decoder
import com.mojang.serialization.DynamicOps
Expand Down Expand Up @@ -38,8 +37,7 @@ fun <A, T> Encoder<A>.encodeQuick(ops: DynamicOps<T>, input: A): T? {
* Decodes from a dynamic ops format.
*/
fun <A, T> Decoder<A>.decodeQuick(ops: DynamicOps<T>, input: T): A? {
return decode(ops, input)
return parse(ops, input)
.result()
.map(Pair<A, T>::getFirst)
.orElse(null)
}

0 comments on commit 0a3d1fa

Please sign in to comment.