Step 5: Swinging the bat
Right-click on the bat and select Edit script.
We'll make it so that the bat moves to the left duck when we click the left arrow key, moves to the middle duck when we click the down arrow key, and moves to the right duck when we click the right arrow key.
Grab "set x position of myself" (from Transform) and drag this block into "When the player presses key left arrow".
Set the x position to 200. Then duplicate these blocks so that we have 3 groups of them.
Change the first copy to set the x position to 400 when the down arrow is pressed, and then change the second copy to set the x position to 600 when the right arrow is pressed.
Now play the game. You can test this out by pressing the left, right, and down arrow keys on your keyboard.