1.0.4
EnergonRelics/pipeline/head This commit looks good Details

This commit is contained in:
TheBrokenRail 2020-09-10 19:10:56 -04:00
parent 40de5445d1
commit 9dde7b4288
3 changed files with 14 additions and 9 deletions

View File

@ -1,5 +1,8 @@
# Changelog
**1.0.4**
* Fix Crash When Sneak-Using Dye On A Block
**1.0.3**
* Fix Gravity Crash

View File

@ -10,7 +10,7 @@ org.gradle.jvmargs = -Xmx1G
fabric_loader_version = 0.9.2+build.206
# Mod Properties
mod_version = 1.0.3
mod_version = 1.0.4
maven_group = com.thebrokenrail
# Dependencies

View File

@ -106,6 +106,7 @@ public class PhaseShifterBlock extends EnergyBlock {
UseBlockCallback.EVENT.register((player, world, hand, hit) -> {
if (!player.isSpectator() && player.shouldCancelInteraction()) {
BlockState state = world.getBlockState(hit.getBlockPos());
if (state.getBlock() == PhaseShifterBlock.this) {
ItemStack stack = player.getStackInHand(hand);
if (stack.getItem() instanceof DyeItem) {
DyeColor newColor = ((DyeItem) stack.getItem()).getColor();
@ -118,6 +119,7 @@ public class PhaseShifterBlock extends EnergyBlock {
}
}
}
}
return ActionResult.PASS;
});
}