Skip to content

Commit

Permalink
1.20.1 -> 1.20.2
Browse files Browse the repository at this point in the history
  • Loading branch information
Sollace committed Oct 22, 2023
1 parent 38a545e commit b6f17ba
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 42 deletions.
16 changes: 8 additions & 8 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@ org.gradle.daemon=false

# Fabric Properties
# check these on https://fabricmc.net/develop
minecraft_version=1.20.1
yarn_mappings=1.20.1+build.9
loader_version=0.14.21
fabric_version=0.86.0+1.20.1
minecraft_version=1.20.2-rc1
yarn_mappings=1.20.2-rc1+build.2
loader_version=0.14.22
fabric_version=0.88.5+1.20.2

# Mod Properties
group=com.presencefootsteps
Expand All @@ -16,12 +16,12 @@ org.gradle.daemon=false
url=http://presencefootsteps.ha3.eu

# Publishing
minecraft_version_range=>=1.20.0
minecraft_version_range=>=1.20.2
modrinth_loader_type=fabric
modrinth_project_id=rcTfTZr3

# Dependencies
modmenu_version=7.0.0-beta.2
minelp_version=4.10.1+1.20
kirin_version=1.15.4+1.20
modmenu_version=8.0.0-beta.1
minelp_version=4.11.0+1.20.2
kirin_version=1.16.0+1.20.2
pehkui_version=3.7.2
7 changes: 0 additions & 7 deletions src/main/java/eu/ha3/presencefootsteps/PFOptionsScreen.java
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@

import eu.ha3.mc.quick.update.Versions;
import eu.ha3.presencefootsteps.util.BlockReport;
import net.minecraft.client.gui.DrawContext;
import net.minecraft.client.gui.screen.Screen;
import net.minecraft.text.Text;

Expand Down Expand Up @@ -122,12 +121,6 @@ public void init() {
.setText("gui.done");
}

@Override
public void render(DrawContext context, int mouseX, int mouseY, float partialTicks) {
renderBackground(context);
super.render(context, mouseX, mouseY, partialTicks);
}

private void redrawUpdateButton(Button button) {
Optional<Versions> versions = PresenceFootsteps.getInstance().getUpdateChecker().getNewer();
boolean hasUpdate = versions.isPresent();
Expand Down
33 changes: 7 additions & 26 deletions src/main/java/eu/ha3/presencefootsteps/sound/generator/MineLP.java
Original file line number Diff line number Diff line change
@@ -1,15 +1,9 @@
package eu.ha3.presencefootsteps.sound.generator;

import org.jetbrains.annotations.Nullable;

import com.minelittlepony.api.pony.meta.Race;
import com.minelittlepony.client.MineLittlePony;

import com.minelittlepony.api.pony.Pony;
import net.fabricmc.loader.api.FabricLoader;
import net.minecraft.client.MinecraftClient;
import net.minecraft.entity.Entity;
import net.minecraft.entity.player.PlayerEntity;
import net.minecraft.util.Identifier;

public class MineLP {
private static boolean checkCompleted = false;
Expand All @@ -25,27 +19,14 @@ public static boolean hasPonies() {
}

public static Locomotion getLocomotion(Entity entity, Locomotion fallback) {

@Nullable
Identifier texture = MinecraftClient.getInstance().getEntityRenderDispatcher().getRenderer(entity).getTexture(entity);

if (texture == null) {
// Bad modder. /slap
return fallback;
}

Race race = MineLittlePony.getInstance().getManager().getPony(texture).race();

if (race.isHuman()) {
return fallback;
}

return race.hasWings() ? Locomotion.FLYING : Locomotion.QUADRUPED;
return Pony.getManager().getPony(entity)
.map(Pony::race)
.filter(race -> !race.isHuman())
.map(race -> race.hasWings() ? Locomotion.FLYING : Locomotion.QUADRUPED)
.orElse(fallback);
}

public static Locomotion getLocomotion(PlayerEntity ply) {
return MineLittlePony.getInstance().getManager().getPony(ply).race().hasWings()
? Locomotion.FLYING
: Locomotion.QUADRUPED;
return getLocomotion(ply, Locomotion.BIPED);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -312,7 +312,7 @@ private void simulateBrushes(LivingEntity ply) {

Association assos = solver.findAssociation(ply, BlockPos.ofFloored(
ply.getX(),
ply.getY() - 0.1D - (ply.hasVehicle() ? ply.getHeightOffset() : 0) - (ply.isOnGround() ? 0 : 0.25D),
ply.getY() - 0.1D - (ply.hasVehicle() ? ply.getRidingOffset(ply.getVehicle()) : 0) - (ply.isOnGround() ? 0 : 0.25D),
ply.getZ()
), Solver.MESSY_FOLIAGE_STRATEGY);

Expand Down

0 comments on commit b6f17ba

Please sign in to comment.