Skip to content

Commit d09d8e1

Browse files
committed
made it so you can't break bedrock
1 parent 6fb16a7 commit d09d8e1

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/dungeon/items/dungeon_breaker.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,6 @@ pub fn dungeon_breaker_dig(
3737
position.as_dvec3() + dvec3(1.5, 1.5, 1.5),
3838
);
3939

40-
4140
// check if room doesn't allow, check if overlaps with secrets
4241

4342
let mut volume_inside = 0.0;
@@ -48,6 +47,9 @@ pub fn dungeon_breaker_dig(
4847

4948
if block_aabb.volume() == volume_inside {
5049
let previous = chunk_grid.get_block_at(position.x, position.y, position.z);
50+
if previous == Blocks::Bedrock {
51+
return false;
52+
}
5153
player.extension.broken_blocks.push((position, previous, 200));
5254

5355
chunk_grid.set_block_at(Blocks::Air, position.x, position.y, position.z);

0 commit comments

Comments
 (0)