Skip to content

Commit 399e4d1

Browse files
committed
Update to v1.19.4
1 parent c603b75 commit 399e4d1

29 files changed

+97
-356
lines changed

build.gradle

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -71,8 +71,6 @@ dependencies {
7171
include "com.github.LlamaLad7:MixinExtras:${project.mixinextras_version}"
7272
implementation("com.github.LlamaLad7:MixinExtras:${project.mixinextras_version}")
7373
annotationProcessor("com.github.LlamaLad7:MixinExtras:${project.mixinextras_version}")
74-
75-
modRuntimeOnly "com.github.astei:lazydfu:0.1.2"
7674
}
7775

7876
processResources {

gradle.properties

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -3,24 +3,24 @@ org.gradle.jvmargs=-Xmx2G
33

44
# Fabric Properties
55
# check these on https://fabricmc.net/use or https://modmuss50.me/fabric.html
6-
display_minecraft_version=1.19.3
7-
minecraft_version=1.19.3
8-
yarn_mappings=1.19.3+build.2
6+
display_minecraft_version=1.19.4
7+
minecraft_version=1.19.4
8+
yarn_mappings=1.19.4+build.2
99
loader_version=0.14.3
10-
carpet_minecraft_version=1.19.3
10+
carpet_minecraft_version=1.19.4
1111
# check available versions on maven for the given minecraft version you are using
12-
carpet_core_version=1.4.91+v221207
12+
carpet_core_version=1.4.101+v230319
1313

1414
# Mod Properties
15-
mod_version = 1.13.0
15+
mod_version = 1.14.0
1616
maven_group = carpet-fixes
1717
archives_base_name = carpet-fixes
1818

1919

2020
# Dependencies
21-
# https://github.com/Fallen-Breath/conditional-mixin
22-
conditionalmixin_version = v0.3.1
23-
# https://github.com/2No2Name/McTester
24-
mctester_version = v0.3.0
25-
# https://github.com/LlamaLad7/MixinExtras
26-
mixinextras_version = 0.0.6
21+
# https://github.com/Fallen-Breath/conditional-mixin
22+
conditionalmixin_version = v0.3.1
23+
# https://github.com/2No2Name/McTester
24+
mctester_version = v0.3.0
25+
# https://github.com/LlamaLad7/MixinExtras
26+
mixinextras_version = 0.0.6

src/main/java/carpetfixes/CFSettings.java

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -678,18 +678,6 @@ public class CFSettings {
678678
)
679679
public static boolean structureManagerCantLoadSnbtFix = false;
680680

681-
//by FX - PR0CESS
682-
@Rule(
683-
categories = {BUGFIX}
684-
)
685-
public static boolean stepAndDestroyBlockGoalUsesOriginFix = false;
686-
687-
//by FX - PR0CESS
688-
@Rule(
689-
categories = {BUGFIX}
690-
)
691-
public static boolean hopperMinecartSlowerAtOriginFix = false;
692-
693681
//By FX - PR0CESS
694682
@Rule(
695683
categories = {BUGFIX}
@@ -852,12 +840,6 @@ public class CFSettings {
852840
)
853841
public static boolean witchAndCatSpawnMergedFix = false;
854842

855-
//By FX - PR0CESS
856-
@Rule(
857-
categories = {BUGFIX}
858-
)
859-
public static boolean jukeboxDiscItemOffsetOnBreakFix = false;
860-
861843
//By FX - PR0CESS
862844
@Rule(
863845
categories = {BUGFIX}

src/main/java/carpetfixes/helpers/CenterUtils.java

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,8 @@ public class CenterUtils {
1818

1919
public static void iterateTouchingBlocks(Entity entity, Consumer<BlockPos.Mutable> perBlock) {
2020
Box box = entity.getBoundingBox();
21-
BlockPos blockPos = new BlockPos(box.minX + OFFSET, entity.getBlockY(), box.minZ + OFFSET);
22-
BlockPos blockPos2 = new BlockPos(box.maxX - OFFSET, entity.getBlockY(), box.maxZ - OFFSET);
21+
BlockPos blockPos = BlockPos.ofFloored(box.minX + OFFSET, entity.getBlockY(), box.minZ + OFFSET);
22+
BlockPos blockPos2 = BlockPos.ofFloored(box.maxX - OFFSET, entity.getBlockY(), box.maxZ - OFFSET);
2323
if (entity.world.isRegionLoaded(blockPos, blockPos2)) {
2424
BlockPos.Mutable mutable = new BlockPos.Mutable();
2525
for(int i = blockPos.getX(); i <= blockPos2.getX(); ++i)
@@ -30,8 +30,8 @@ public static void iterateTouchingBlocks(Entity entity, Consumer<BlockPos.Mutabl
3030

3131
public static void checkFallCollision(Entity entity, float fallDistance) {
3232
Box box = entity.getBoundingBox();
33-
BlockPos blockPos = new BlockPos(box.minX + OFFSET, entity.getBlockY(), box.minZ + OFFSET);
34-
BlockPos blockPos2 = new BlockPos(box.maxX - OFFSET, entity.getBlockY(), box.maxZ - OFFSET);
33+
BlockPos blockPos = BlockPos.ofFloored(box.minX + OFFSET, entity.getBlockY(), box.minZ + OFFSET);
34+
BlockPos blockPos2 = BlockPos.ofFloored(box.maxX - OFFSET, entity.getBlockY(), box.maxZ - OFFSET);
3535
if (entity.world.isRegionLoaded(blockPos, blockPos2)) {
3636
BlockPos.Mutable mutable = new BlockPos.Mutable();
3737
boolean createdEvent = false;
@@ -51,8 +51,8 @@ public static void checkFallCollision(Entity entity, float fallDistance) {
5151

5252
public static float checkJumpVelocityOnCollision(Entity entity, World world) {
5353
Box box = entity.getBoundingBox();
54-
BlockPos blockPos = new BlockPos(box.minX + OFFSET, entity.getBlockY(), box.minZ + OFFSET);
55-
BlockPos blockPos2 = new BlockPos(box.maxX - OFFSET, entity.getBlockY(), box.maxZ - OFFSET);
54+
BlockPos blockPos = BlockPos.ofFloored(box.minX + OFFSET, entity.getBlockY(), box.minZ + OFFSET);
55+
BlockPos blockPos2 = BlockPos.ofFloored(box.maxX - OFFSET, entity.getBlockY(), box.maxZ - OFFSET);
5656
if (world.isRegionLoaded(blockPos, blockPos2)) {
5757
double newY = box.minY - VELOCITY_AFFECTING_POS_Y_OFFSET;
5858
BlockPos.Mutable mutable = new BlockPos.Mutable();
@@ -80,8 +80,8 @@ public static float checkJumpVelocityOnCollision(Entity entity, World world) {
8080

8181
public static float checkVelocityOnCollision(Entity entity, World world) {
8282
Box box = entity.getBoundingBox();
83-
BlockPos blockPos = new BlockPos(box.minX + OFFSET, entity.getBlockY(), box.minZ + OFFSET);
84-
BlockPos blockPos2 = new BlockPos(box.maxX - OFFSET, entity.getBlockY(), box.maxZ - OFFSET);
83+
BlockPos blockPos = BlockPos.ofFloored(box.minX + OFFSET, entity.getBlockY(), box.minZ + OFFSET);
84+
BlockPos blockPos2 = BlockPos.ofFloored(box.maxX - OFFSET, entity.getBlockY(), box.maxZ - OFFSET);
8585
if (world.isRegionLoaded(blockPos, blockPos2)) {
8686
double newY = box.minY - VELOCITY_AFFECTING_POS_Y_OFFSET;
8787
BlockPos.Mutable mutable = new BlockPos.Mutable();

src/main/java/carpetfixes/helpers/DelayedWorldEventManager.java

Lines changed: 14 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,9 @@
22

33
import net.minecraft.util.Pair;
44
import net.minecraft.util.math.BlockPos;
5+
import net.minecraft.util.math.Vec3d;
56
import net.minecraft.world.World;
7+
import net.minecraft.world.event.GameEvent;
68

79
import java.util.ArrayList;
810
import java.util.HashMap;
@@ -14,13 +16,13 @@ public class DelayedWorldEventManager {
1416

1517
private static final HashMap<World,List<Pair<Integer,DelayedWorldEvent>>> delayedWorldEvents = new HashMap<>();
1618

17-
public static void addDelayedWorldEvent(World world, int eventId, BlockPos pos, int data) {
18-
addDelayedWorldEvent(world, eventId, pos, data, 1);
19+
public static void addDelayedWorldEvent(World world, GameEvent gameEvent, Vec3d emitterPos, GameEvent.Emitter emitter) {
20+
addDelayedWorldEvent(world, gameEvent, emitterPos, emitter, 1);
1921
}
2022

21-
public static void addDelayedWorldEvent(World world, int eventId, BlockPos pos, int data, int delay) {
23+
public static void addDelayedWorldEvent(World world, GameEvent gameEvent, Vec3d emitterPos, GameEvent.Emitter emitter, int delay) {
2224
delayedWorldEvents.computeIfAbsent(world,(a) -> new ArrayList<>())
23-
.add(new Pair<>(delay,new DelayedWorldEvent(eventId, pos, data)));
25+
.add(new Pair<>(delay, new DelayedWorldEvent(gameEvent, emitterPos, emitter)));
2426
}
2527

2628
public static void tick(World world) {
@@ -38,18 +40,18 @@ public static void tick(World world) {
3840

3941
static class DelayedWorldEvent {
4042

41-
private final int eventId;
42-
private final BlockPos pos;
43-
private final int data;
43+
private final GameEvent event;
44+
private final Vec3d emitterPos;
45+
private final GameEvent.Emitter emitter;
4446

45-
DelayedWorldEvent(int eventId, BlockPos pos, int data) {
46-
this.eventId = eventId;
47-
this.pos = pos;
48-
this.data = data;
47+
DelayedWorldEvent(GameEvent event, Vec3d emitterPos, GameEvent.Emitter emitter) {
48+
this.event = event;
49+
this.emitterPos = emitterPos;
50+
this.emitter = emitter;
4951
}
5052

5153
public void sendWorldEvent(World world) {
52-
world.syncWorldEvent(null, this.eventId, this.pos, this.data);
54+
world.emitGameEvent(this.event, this.emitterPos, this.emitter);
5355
}
5456
}
5557
}

src/main/java/carpetfixes/helpers/RaycastUtils.java

Lines changed: 0 additions & 113 deletions
This file was deleted.

src/main/java/carpetfixes/mixins/blockFixes/JukeboxBlock_itemOffsetMixin.java

Lines changed: 0 additions & 71 deletions
This file was deleted.

src/main/java/carpetfixes/mixins/blockFixes/PressurePlateBlock_collisionOnPlaceMixin.java

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,11 @@
22

33
import carpetfixes.CFSettings;
44
import net.minecraft.block.AbstractPressurePlateBlock;
5+
import net.minecraft.block.BlockSetType;
56
import net.minecraft.block.BlockState;
67
import net.minecraft.block.PressurePlateBlock;
78
import net.minecraft.entity.Entity;
9+
import net.minecraft.sound.SoundCategory;
810
import net.minecraft.state.property.BooleanProperty;
911
import net.minecraft.util.math.BlockPos;
1012
import net.minecraft.world.World;
@@ -26,8 +28,8 @@ public abstract class PressurePlateBlock_collisionOnPlaceMixin extends AbstractP
2628
@Final
2729
public static BooleanProperty POWERED;
2830

29-
public PressurePlateBlock_collisionOnPlaceMixin(Settings settings) {
30-
super(settings);
31+
public PressurePlateBlock_collisionOnPlaceMixin(Settings settings, BlockSetType blockSetType) {
32+
super(settings, blockSetType);
3133
}
3234

3335
@Override
@@ -47,10 +49,10 @@ private void tryPowerOnPlace(BlockState state, World world, BlockPos pos) {
4749
world.setBlockState(pos, state.with(POWERED, bl), 3);
4850
this.updateNeighbors(world, pos);
4951
if (bl) {
50-
this.playPressSound(world, pos);
52+
world.playSound(null, pos, this.blockSetType.pressurePlateClickOff(), SoundCategory.BLOCKS);
5153
world.emitGameEvent(list.stream().findFirst().orElse(null), GameEvent.BLOCK_DEACTIVATE, pos);
5254
} else {
53-
this.playDepressSound(world, pos);
55+
world.playSound(null, pos, this.blockSetType.pressurePlateClickOn(), SoundCategory.BLOCKS);
5456
world.emitGameEvent(list.stream().findFirst().orElse(null), GameEvent.BLOCK_ACTIVATE, pos);
5557
}
5658
}

0 commit comments

Comments
 (0)