When they hit, make sure to clap your hands, and say, Good job!
and when they miss, clean up the other and put it in the potty,
and explain that this is where it goes. Set them down on the toilet or potty chair, even it they don't have to go. So they can practice.
Your child will do great.