Step 4: Continue in the same way, digging a diagonal tunnel. Step 2: Remove the blocks indicated by diorite. Step 1: Remove the blocks indicated by granite. ![]() Can you create code that will get the agent to dig this type of tunnel? Digging a diagonal tunnel involves removing layers of blocks as shown. One effective type of tunnel goes down at a diagonal angle. And, as in all the staircases, you will probably need to follow the agent to place torches and clean up falling granite. Think about where you might have to turn. You remove the block directly in front of the Agent (block 2 in picture) and the blocks directly above and below that (blocks 1 and 3 in the pictures).Ī spiral staircase involves much of the same code that you would use to create a straight one-block-wide staircase. Start by digging one block, then two blocks, and then three blocks deep.Īfter that, at each turn, remove a column of three blocks. See if you can program the agent to dig this type of staircase for you. Remember to use ||loops:LOOPS|| to reduce repetition of code!Īfter you have the agent building a straight set of stairs, consider how you might modify your code to create a staircase three blocks wide and with enough headroom to allow you to ride a horse down the stairs! Option 2 - Spiral StaircaseĪnother type of staircase is a spiral staircase. Set it to true when you want to place stairs but false when you are just moving the agent and don’t need to place anything. You may need to toggle ||agent:agent place on move|| from true to false at certain points. If you try using the ||agent:agent place on move|| block, the agent will place a block every time it moves when this is set to true. This works well if you are building a staircase up, but if you are building a staircase down, think about how you could modify your code to make sure the stairs come out right. Perhaps you can work around these issues.īy default, the agent places stairs facing backwards.
0 Comments
Leave a Reply. |