Check immediate support under neighboring sand
This commit is contained in:
1 parent
142381d40f
commit
e50b9dc697
2 files changed
+38
-3
No files matched your search
@@ -37,6 +37,16 @@ class IndexedSearchTests(unittest.TestCase):
|
||||
self.assertFalse(safe)
|
||||
self.assertIn('unsafe adjacent water', reason)
|
||||
|
||||
world_blocks[(1, 64, 0)] = blocks.SAND
|
||||
safe, reason = world.sand_safety(sand)
|
||||
self.assertFalse(safe)
|
||||
self.assertIn('unsupported', reason)
|
||||
|
||||
# A sand block immediately below this neighboring sand counts as its
|
||||
# support; don't inspect the rest of that lower sand column.
|
||||
world_blocks[(1, 63, 0)] = blocks.SAND
|
||||
self.assertTrue(world.sand_safety(sand)[0])
|
||||
|
||||
def test_sand_search_targets_safe_blocks_in_3x3_slice_only(self):
|
||||
sand_position = (1, 64, 1)
|
||||
|
||||
|
||||
Reference in new issue
Block a user