It just so happens that float valves are useful for a lot of stuff. Anytime you need a reservoir of water to stay full without your personal attention - a swimming pool, a pond, a fountain.
The only problem is, they are often expensive.
Here's how to turn a $9 toilet tank float valve into a reliable general purpose tool.
This is the one you want. They all work differently, but this one is easy to service and modify.
First thing: pull out the tube all the way and cut as shown.
Note the white plastic diffuser in there. Leave it in. Maybe push it a little further in.
You'll want some sort of adaptors. These 1/2" irrigation elbows work great and they're cheap.
The thing comes with a convenient little plastic tube. Use it to block epoxy.
There's also a red rubber washer. Use it to block epoxy.
Okay. You put on the washer, the tube, and the cut off adaptor like this. The tube is to keep expoxy out of the piper where the water's going to go.
You'll want to cut off the elbow part. I screw them in to a longer pipe so that I can saw them off without losing my fingers. You want it cut square.
I like the 5 minute epoxy for this that comes with the mixer syringe. It's not especially cheap, but it works very well.
Apply epoxy, move the fitting up and down a bit to get rid of bubbles, and then pull the center tube out. Note that you may have to clear expoxy from the pipe with a toothpick or something...
Allow it to set 5 minutes and there you go. You can mount it with zip ties, or by screwing carefully into the very top of the float shield ( remove the white part so you can see what you're doing.)