Skip to content

Commit

Permalink
Bump adapter definition to 1.11.64
Browse files Browse the repository at this point in the history
Fixes #1126
  • Loading branch information
Su5eD committed Jun 4, 2024
1 parent 9c2392d commit 711b649
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 10 deletions.
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ org.gradle.daemon=true
# Versions
versionConnector=1.0.0-beta.44
versionAdapter=1.11.55-1.20.1-20240428.153904
versionAdapterDefinition=1.11.63
versionAdapterDefinition=1.11.64
versionAdapterRuntime=1.0.0

versionMc=1.20.1
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ public static List<Patch> getPatches() {
Patch.builder()
.targetClass("net/minecraft/world/entity/LivingEntity")
.targetMethod("m_21208_()V")
.targetMixinType(MixinConstants.MODIFY_CONST)
.targetConstant(-0.03999999910593033D)
.extractMixin("net/minecraftforge/common/extensions/IForgeLivingEntity")
.modifyTarget("sinkInFluid(Lnet/minecraftforge/fluids/FluidType;)V")
.build(),
Expand Down Expand Up @@ -456,14 +456,7 @@ public static List<Patch> getPatches() {
.targetClass("net/minecraft/world/entity/LivingEntity")
.targetMethod("m_7023_") // travel
.targetMixinType(MixinConstants.MODIFY_VAR)
.targetAnnotationValues(handle -> handle.getNested("at")
.filter(at -> at.getValue("value")
.filter(h -> h.get().equals("CONSTANT"))
.isPresent())
.flatMap(at -> at.getValue("args"))
.map(v -> (List<String>) v.get())
.map(v -> v.size() == 1 && v.get(0).equals("doubleValue=0.01"))
.orElse(false))
.targetConstant(0.01)
.modifyMixinType(MixinConstants.WRAP_OPERATION, builder -> builder
.sameTarget()
.injectionPoint("INVOKE", "Lnet/minecraft/world/entity/ai/attributes/AttributeInstance;m_22135_()D") // getValue
Expand Down

0 comments on commit 711b649

Please sign in to comment.