Skip to content

Commit

Permalink
1.19.2 -> 1.19.3 (1.20)
Browse files Browse the repository at this point in the history
  • Loading branch information
Sollace committed Dec 11, 2022
1 parent c784956 commit 7c073fa
Show file tree
Hide file tree
Showing 7 changed files with 23 additions and 25 deletions.
3 changes: 1 addition & 2 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
buildscript {
dependencies {
classpath 'com.github.dexman545:Outlet:1.3.6'
classpath 'com.github.dexman545:Outlet:1.3.10'
}
}
plugins {
id 'java-library'
id 'fabric-loom' version '0.12-SNAPSHOT'
id 'maven-publish'
id 'com.modrinth.minotaur' version '2.+'
Expand Down
18 changes: 9 additions & 9 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.19.2
yarn_mappings=1.19.2+build.3
loader_version=0.14.9
fabric_version=0.59.0+1.19.2
minecraft_version=1.19.3
yarn_mappings=1.19.3+build.2
loader_version=0.14.11
fabric_version=0.68.1+1.19.3

# Mod Properties
group=com.minelittlepony
Expand All @@ -15,12 +15,12 @@ org.gradle.daemon=false
description=Ah am a big pony!

# Publishing
minecraft_version_range=>=1.18
minecraft_version_range=>=1.19.3
modrinth_loader_type=fabric
modrinth_project_id=h9pJxJR9

# Dependencies
modmenu_version=4.0.6
minelp_version=4.6.1
hd_skins_version=6.6.1
kirin_version=1.11.0
modmenu_version=5.0.0-alpha.3
minelp_version=4.7.1
hd_skins_version=6.7.2
kirin_version=1.13.2
4 changes: 2 additions & 2 deletions src/main/java/com/minelittlepony/bigpony/BigPony.java
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,13 @@ public static BigPony getInstance() {
return instance;
}

private final Config config = new Config(GamePaths.getConfigDirectory().resolve("bigpony.json"));
private final BigPonyConfig config = new BigPonyConfig(GamePaths.getConfigDirectory().resolve("bigpony.json"));

public BigPony() {
instance = this;
}

public Config getConfig() {
public BigPonyConfig getConfig() {
return config;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,17 @@

import java.nio.file.Path;

import com.minelittlepony.common.util.settings.JsonConfig;
import com.minelittlepony.common.util.settings.Config;
import com.minelittlepony.common.util.settings.Setting;

public class Config extends JsonConfig {

public class BigPonyConfig extends Config {
public final Setting<Scaling> scale = value("scale", new Scaling(new Triple(1), new Cam(1)));

public final Setting<Boolean> allowHitboxChanges = value("allowHitboxChanges", true);
public final Setting<Boolean> allowCameraChanges = value("allowCameraChanges", true);
public final Setting<Boolean> allowFreeformResizing = value("allowFreeformResizing", true);

public Config(Path path) {
super(path);
public BigPonyConfig(Path path) {
super(FLATTENED_JSON_ADAPTER, path);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ public boolean isFillyCam() {

@Override
public boolean isPony(PlayerEntity player) {
return !MineLittlePony.getInstance().getManager().getPony(player).getRace(false).isHuman();
return !MineLittlePony.getInstance().getManager().getPony(player).race().isHuman();
}

@Override
Expand All @@ -60,8 +60,8 @@ public CompletableFuture<Identifier> detectPreset(GameProfile profile, Scaling i
// Turn on filly cam so we can get the camera parameters
MineLittlePony.getInstance().getConfig().fillycam.set(true);

IPony pony = IPony.forResource(skin);
Size size = pony.getMetadata().getSize();
IPony pony = IPony.getManager().getPony(skin);
Size size = pony.metadata().getSize();

into.setScale(new Triple(size.getScaleFactor()));
into.setCamera(new Cam(size.getEyeDistanceFactor(), size.getEyeHeightFactor()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@

@Mixin(ServerPlayerEntity.class)
abstract class MixinServerPlayerEntity extends PlayerEntity implements ScreenHandlerListener {
MixinServerPlayerEntity() { super(null, null, 0, null, null); }
MixinServerPlayerEntity() { super(null, null, 0, null); }

@Inject(method = "copyFrom(Lnet/minecraft/server/network/ServerPlayerEntity;Z)V", at = @At("RETURN"))
public void injectCopyFrom(ServerPlayerEntity other, boolean alive, CallbackInfo info) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
import net.minecraft.entity.player.PlayerEntity;
import net.minecraft.resource.SynchronousResourceReloader;
import net.minecraft.util.math.MathHelper;
import net.minecraft.util.math.Vec3f;
import net.minecraft.util.math.RotationAxis;

@Mixin(GameRenderer.class)
abstract class MixinGameRenderer implements SynchronousResourceReloader, AutoCloseable {
Expand Down Expand Up @@ -42,10 +42,10 @@ private void onBobView(MatrixStack matrices, float f, CallbackInfo info) {
-Math.abs(MathHelper.cos(h * (float)Math.PI) * i) * scale.y,
0
);
matrices.multiply(Vec3f.POSITIVE_Z.getDegreesQuaternion(
matrices.multiply(RotationAxis.POSITIVE_Z.rotationDegrees(
MathHelper.sin(h * (float)Math.PI) * i * 3 * scale.z
));
matrices.multiply(Vec3f.POSITIVE_X.getDegreesQuaternion(
matrices.multiply(RotationAxis.POSITIVE_X.rotationDegrees(
Math.abs(MathHelper.cos(h * (float)Math.PI - 0.2f) * i) * 5 * scale.x
));
}
Expand Down

0 comments on commit 7c073fa

Please sign in to comment.