Skip to content

Commit

Permalink
update version to 1.20
Browse files Browse the repository at this point in the history
  • Loading branch information
bunnyi116 committed Jun 10, 2023
1 parent 8bb57fc commit 41fa428
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 13 deletions.
8 changes: 4 additions & 4 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,12 @@ org.gradle.jvmargs=-Xmx1G

# # Dependencies

minecraft_version=1.19.4
yarn_mappings=1.19.4+build.2
loader_version=0.14.19
minecraft_version=1.20
yarn_mappings=1.20+build.1
loader_version=0.14.21

#Fabric api
fabric_version=0.78.0+1.19.4
fabric_version=0.83.0+1.20

## 代理
#systemProp.http.proxyHost=127.0.0.1
Expand Down
12 changes: 6 additions & 6 deletions src/main/java/yan/lx/bedrockminer/utils/CheckingEnvironment.java
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,13 @@
public class CheckingEnvironment {

public static BlockPos findNearbyFlatBlockToPlaceRedstoneTorch(ClientWorld world, BlockPos blockPos) {
if ((sideCoversSmallSquare(world, blockPos.east(), Direction.UP) && (world.getBlockState(blockPos.east().up()).getMaterial().isReplaceable()) || world.getBlockState(blockPos.east().up()).isOf(Blocks.REDSTONE_TORCH))) {
if ((sideCoversSmallSquare(world, blockPos.east(), Direction.UP) && (world.getBlockState(blockPos.east().up()).isReplaceable()) || world.getBlockState(blockPos.east().up()).isOf(Blocks.REDSTONE_TORCH))) {
return blockPos.east();
} else if ((sideCoversSmallSquare(world, blockPos.west(), Direction.UP) && (world.getBlockState(blockPos.west().up()).getMaterial().isReplaceable()) || world.getBlockState(blockPos.west().up()).isOf(Blocks.REDSTONE_TORCH))) {
} else if ((sideCoversSmallSquare(world, blockPos.west(), Direction.UP) && (world.getBlockState(blockPos.west().up()).isReplaceable()) || world.getBlockState(blockPos.west().up()).isOf(Blocks.REDSTONE_TORCH))) {
return blockPos.west();
} else if ((sideCoversSmallSquare(world, blockPos.north(), Direction.UP) && (world.getBlockState(blockPos.north().up()).getMaterial().isReplaceable()) || world.getBlockState(blockPos.north().up()).isOf(Blocks.REDSTONE_TORCH))) {
} else if ((sideCoversSmallSquare(world, blockPos.north(), Direction.UP) && (world.getBlockState(blockPos.north().up()).isReplaceable()) || world.getBlockState(blockPos.north().up()).isOf(Blocks.REDSTONE_TORCH))) {
return blockPos.north();
} else if ((sideCoversSmallSquare(world, blockPos.south(), Direction.UP) && (world.getBlockState(blockPos.south().up()).getMaterial().isReplaceable()) || world.getBlockState(blockPos.south().up()).isOf(Blocks.REDSTONE_TORCH))) {
} else if ((sideCoversSmallSquare(world, blockPos.south(), Direction.UP) && (world.getBlockState(blockPos.south().up()).isReplaceable()) || world.getBlockState(blockPos.south().up()).isOf(Blocks.REDSTONE_TORCH))) {
return blockPos.south();
}
return null;
Expand All @@ -31,7 +31,7 @@ public static BlockPos findNearbyFlatBlockToPlaceRedstoneTorch(ClientWorld world
public static BlockPos findPossibleSlimeBlockPos(ClientWorld world, BlockPos blockPos) {
for (Direction direction :Direction.Type.HORIZONTAL){
BlockPos newBlockPos = blockPos.offset(direction);
if (!world.getBlockState(newBlockPos).getMaterial().isReplaceable()){
if (!world.getBlockState(newBlockPos).isReplaceable()){
continue;
}
if (CheckingEnvironment.isBlocked(newBlockPos)){
Expand All @@ -49,7 +49,7 @@ public static boolean has2BlocksOfPlaceToPlacePiston(ClientWorld world, BlockPos
if (isBlocked(blockPos.up())) {
return false;
}
return world.getBlockState(blockPos.up().up()).getMaterial().isReplaceable();
return world.getBlockState(blockPos.up().up()).isReplaceable();
}

public static ArrayList<BlockPos> findNearbyRedstoneTorch(ClientWorld world, BlockPos pistonBlockPos) {
Expand Down
6 changes: 3 additions & 3 deletions src/main/resources/fabric.mod.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,12 +22,12 @@
]
},
"mixins": [
"bedrock-miner.json"
"bedrock-miner.mixins.json"
],

"depends": {
"fabricloader": ">=0.14.7",
"minecraft": "1.19.x",
"fabricloader": ">=0.14.21",
"minecraft": "1.20.x",
"java": ">=17"
},
"suggests": {
Expand Down

0 comments on commit 41fa428

Please sign in to comment.