I was spanked as a child. It seemed a semi-logical example of results of poor behavior. Most of all it was a lesson in obedience.
I also spanked my children. Once I was challenged with the task of teaching my children to control the words they used. It took the creation of a black paddle named Sting to remedy their use of foul language. Causing your children pain, but pain teaches us all. I do not know a superior method, but my days of parenting are over. I a proud of my four sons.
I'm glad that your sons have made you proud.