Fix TreeFarmer (#1157)

This commit is contained in:
Рома Данилов 2020-07-30 00:52:38 +05:00 committed by GitHub
parent b5c7dc4fc4
commit 432f55460d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -26,25 +26,20 @@ public class TreeFarmer : ChatBot
case Material.OakLog: case Material.OakLog:
// Tree has grown, dig 4 blocks // Tree has grown, dig 4 blocks
ChangeSlot(0); ChangeSlot(0);
DigBlock(0, sapling, 1); DigBlock(sapling);
Thread.Sleep(100); Thread.Sleep(100);
DigBlock(2, sapling, 1);
// 1 // 1
DigBlock(0, new Location(sapling.X, sapling.Y + 1, sapling.Z), 1); DigBlock(new Location(sapling.X, sapling.Y + 1, sapling.Z));
Thread.Sleep(100); Thread.Sleep(100);
DigBlock(2, new Location(sapling.X, sapling.Y + 1, sapling.Z), 1);
// 2 // 2
DigBlock(0, new Location(sapling.X, sapling.Y + 2, sapling.Z), 1); DigBlock(new Location(sapling.X, sapling.Y + 2, sapling.Z));
Thread.Sleep(100); Thread.Sleep(100);
DigBlock(2, new Location(sapling.X, sapling.Y + 2, sapling.Z), 1);
// 3 // 3
DigBlock(0, new Location(sapling.X, sapling.Y + 3, sapling.Z), 1); DigBlock(new Location(sapling.X, sapling.Y + 3, sapling.Z));
Thread.Sleep(100); Thread.Sleep(100);
DigBlock(2, new Location(sapling.X, sapling.Y + 3, sapling.Z), 1);
// 4 // 4
DigBlock(0, new Location(sapling.X, sapling.Y + 4, sapling.Z), 1); DigBlock(new Location(sapling.X, sapling.Y + 4, sapling.Z);
Thread.Sleep(100); Thread.Sleep(100);
DigBlock(2, new Location(sapling.X, sapling.Y + 4, sapling.Z), 1);
break; break;
case Material.Air: case Material.Air:
// No tree, plant something // No tree, plant something