Repository navigation
Interacting - flick a lever. #1744
Answered
by
ORelio
j-romchain
asked this question in
Q&A
|
I want to have it start a farm, to do so it just needs to flick the lever. Are there commands to 1. Find the lever, and 2.flick the lever? |
Answered by
ORelio
Aug 26, 2021
Replies: 1 comment 7 replies
|
You might be able to do so using the |
7 replies
Answer selected by
j-romchain
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
You would need to write a C# script, but I'm not sure if there is a way to retrieve the state of the lever currently.OK I misread your question, you want to flip the lever, not watch for it and run an action in MCC, see answer below.Example of script: sample-script-with-world-access.cs (lamp state can be retrieved in 1.12 and lower at the moment)
You might be able to do so using the
/useblockcommand, however I'm not sure you can look for a certain block type at the moment, you would need to open the game first and take not of the exact coordinates.