I would very much like to detect the presence of water in a block, but I can't seem to find a reliable method.
I found a couple of ideas but neither is "good enough":
- Use a boat over a wooden pressure plate. Sadly, the water isn't lifting the boat, so the signal is always on. I even tried moving the boat upstream and closer to the source block, but no luck. So I am guessing this worked in the past but no longer.
- Use a complicated circuit with a dailight sensor. Again, this won't work for me as I might need to use it in a closed room with no daylight.
Is there any other method?
(Note: In case it is relevant, I am on Java edition, skyblock, and I think the version of Java for this skyblock server is probably 1.12 or at most 1.13)
An observer would only detect when the state changed, and not which way, but if you have room downstream you could use a piston to open/close a chanel leading to the observer, if the observer then generates a pulse then there is presumably water (or lava) being turned on/off if there is no water the observer wouldn't register a change.
(If you did need to detect the difference between water and lava you could use the delay to determine that.)
Or if you can't use an observer you could use a similar technique with the boat and pressure plate, letting the water push the boat all the way off the pressure plate and using a piston to push it back.
--
I did have the occasional problem with the boat getting pushed into the side of the chanal, I wonder if that could be fixed with a wider chanel (and 2 pressure plates if needed) or pistons on the sides to center the boat?
I ended up bypassing the issue and using a T-FlipFlop to track the state. The T-FlipFlop is being activated by the same pulse that triggers the dispenser that releases the water.
But I have to say that detecting the presence of water is a feature that is missing from Minecraft and I hope that it will be added to the game someday.
I would very much like to detect the presence of water in a block, but I can't seem to find a reliable method.
I found a couple of ideas but neither is "good enough":
- Use a boat over a wooden pressure plate. Sadly, the water isn't lifting the boat, so the signal is always on. I even tried moving the boat upstream and closer to the source block, but no luck. So I am guessing this worked in the past but no longer.
- Use a complicated circuit with a dailight sensor. Again, this won't work for me as I might need to use it in a closed room with no daylight.
Is there any other method?
(Note: In case it is relevant, I am on Java edition, skyblock, and I think the version of Java for this skyblock server is probably 1.12 or at most 1.13)
If it's on a server, and daylight sensors are an option, then I assume quartz is too. So if the server could be in 1.12, you could try Observers.
Watch out for the crabocalypse. Some say the day will never come. But it will.
Feel free to drop by for a chat whenever.
If you'd like to talk with me about other games, here are a few I play.
Team Fortress 2
Borderlands series (Borderlands 2 is my favorite game, ever. TPS combat is a lot of fun and makes up for the lower-quality story, in my opinion)
Elder Scrolls series
Warframe (IGN is something like That_One_Flesh_Atronach)
Pokémon series (HGSS forever)
Rocket League
Fallout series
Left 4 Dead 2 (Boomer files always corrupt though)
SUPERHOT (SUPERHOT is the most innovative shooter I've played in years!)
Dead Rising series (Dead Rising 2 is one of my favorite games, and the 3rd was a lot of fun. 1st has poor survivor AI and the 4th is bad)
Just Cause series
Come to think of it, I mainly play fighting-based games.
An observer would only detect when the state changed, and not which way, but if you have room downstream you could use a piston to open/close a chanel leading to the observer, if the observer then generates a pulse then there is presumably water (or lava) being turned on/off if there is no water the observer wouldn't register a change.
(If you did need to detect the difference between water and lava you could use the delay to determine that.)
Just testing.
Or if you can't use an observer you could use a similar technique with the boat and pressure plate, letting the water push the boat all the way off the pressure plate and using a piston to push it back.
--
I did have the occasional problem with the boat getting pushed into the side of the chanal, I wonder if that could be fixed with a wider chanel (and 2 pressure plates if needed) or pistons on the sides to center the boat?
Just testing.
I ended up bypassing the issue and using a T-FlipFlop to track the state. The T-FlipFlop is being activated by the same pulse that triggers the dispenser that releases the water.
But I have to say that detecting the presence of water is a feature that is missing from Minecraft and I hope that it will be added to the game someday.