I have a wire and I need to go through 4 outputs - 4 states. I have found different switches like this, but there is not enough states... Do you have any idea of how to do one?
Far far in the past I remember something like this:
I did a quick redstone work. I think that you will compact it. I will explain it anyway.
there are 4 output states. (not considering 0th state)
1st state -> block in front of white wool
2nd state -> block in front of megenta wool
3rd state -> block in front of yellow wool
4th state -> block in front of blue wool
an dropper is facing in hopper. also hopper is facing in the dropper. so when the hopper is unlocked, swords will flow into the dropper.
the input button is not visible in this image. it is on the sandstone block directly next to the dropper.
when you press input button once , sword gets dropped in the hopper, the signal strength of comparator increases and you get output as stage 1. on second press you get output state 2, and so on...
when you are in 4th state and press the button again, hopper gets filled with anoter sword, thus signal strength of comparator increases and with the pulse extender piston retracts thus flushing all swords from hopper back to dropper.