1.21.9
This commit is contained in:
@@ -2,13 +2,13 @@
|
||||
org.gradle.jvmargs=-Xmx1G
|
||||
# Fabric Properties
|
||||
# check these on https://modmuss50.me/fabric.html
|
||||
minecraft_version=1.21.8
|
||||
yarn_mappings=1.21.8+build.1
|
||||
loader_version=0.16.14
|
||||
minecraft_version=1.21.9
|
||||
yarn_mappings=1.21.9+build.1
|
||||
loader_version=0.17.2
|
||||
# Mod Properties
|
||||
mod_version=1.0
|
||||
mod_version=1.1
|
||||
maven_group=com.kasetoatz
|
||||
archives_base_name=hungryfrog
|
||||
# Dependencies
|
||||
# check this on https://modmuss50.me/fabric.html
|
||||
fabric_version=0.131.0+1.21.8
|
||||
fabric_version=0.133.14+1.21.9
|
||||
|
||||
@@ -0,0 +1,14 @@
|
||||
package com.kasetoatz.hungryfrog.mixin;
|
||||
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.passive.FrogEntity;
|
||||
import net.minecraft.util.math.Vec3d;
|
||||
import org.spongepowered.asm.mixin.Mixin;
|
||||
import org.spongepowered.asm.mixin.gen.Accessor;
|
||||
|
||||
@Mixin(Entity.class)
|
||||
public interface EntityAccessor
|
||||
{
|
||||
@Accessor("pos")
|
||||
Vec3d getPos();
|
||||
}
|
||||
@@ -2,6 +2,7 @@ package com.kasetoatz.hungryfrog.task;
|
||||
|
||||
import com.google.common.collect.ImmutableMap;
|
||||
import com.kasetoatz.hungryfrog.HungryFrog;
|
||||
import com.kasetoatz.hungryfrog.mixin.EntityAccessor;
|
||||
import net.minecraft.block.*;
|
||||
import net.minecraft.command.argument.EntityAnchorArgumentType;
|
||||
import net.minecraft.entity.EntityPose;
|
||||
@@ -163,7 +164,7 @@ public class FrogEatBlockTask extends MultiTickTask<FrogEntity>
|
||||
switch (this.phase)
|
||||
{
|
||||
case MOVE_TO_TARGET:
|
||||
if (frog.getPos().distanceTo(Vec3d.of(pos)) < 1.75F)
|
||||
if (((EntityAccessor)frog).getPos().distanceTo(Vec3d.of(pos)) < 1.75F)
|
||||
{
|
||||
world.playSoundFromEntity(null, frog, TONGUE_SOUND, SoundCategory.NEUTRAL, 2.0F, 1.0F);
|
||||
frog.setPose(EntityPose.USING_TONGUE);
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
"mixins": [
|
||||
"BrainAccessor",
|
||||
"FrogBrainMixin",
|
||||
"EntityAccessor",
|
||||
"FrogEntityMixin",
|
||||
"LivingEntityMixin",
|
||||
"ProfileAccessor"
|
||||
|
||||
Reference in New Issue
Block a user