This small command modification allows you to make working sinks and bathtubs!


 ▶ [Set on 'repeat' and 'always active'] The first command (the one at the bottom) is a /testforblock. '/testforblock' commands will emit redstone signal when they find a specified block in a specified area.

Instead of the coordinates that I wrote, you'll have to insert the coordinates where your block (in this case the button) will be. The number after 'wooden_button' represents the data value of the block. If we don't write that number, the command will emit redstone signal if it finds a button: no matter if it is pushed or not. Because we want all the other commands to work only when the button is pushed, we need to specify that the command needs to be pushed in order for the command to be executed. Data values can also change depending on the direction of the button.

For the tub I used a lever instead the button: this makes no difference! Instead of writing 'wooden_button' in the command block, we have to write 'lever' followed by the data value.


 ▶ [Set on 'chain', 'conditional' and 'always active'] The second command receives redstone signal only when the previous command block has successfully executed a command because it is set to conditional. When it receives redstone signal, it creates some water particles. If you pay attention, the reproduced particle is called 'blockdust': this kind of particles doesn't appear in chat when you press TAB. They work like normal particles but have the texture of blocks.

The number that follows the underscore (_) in the name of the particle indicates the type of block texture that has to be reproduced. '8' is the old block ID for water. You can find a full list of block IDs here.


 ▶ [Set on 'chain', 'conditional' and 'always active'] The third command also reproduces water particles that, this time, simulates water drops bouncing on the sink.


 ▶ [Set on 'chain', 'conditional' and 'always active'] The last command block (the one at the top) has a /playsound command written in it. It plays the 'flowing water' sound every time that you use the sink or tub.

For more info about the /playsound command and a full list of all existing 1.9 commands click here.

/playsound block.water.ambient block @a -676 135.9 816 .1 2

/particle blockdust ~ ~ ~ 0 0 0 0 2 force @a 8

/particle blockdust ~ ~ ~ 0 .1 0 .1 2 force @a 8

Explanation

How to make working sinks & tubs

/testforblock -675 135 816 wooden_button 11