They must have died during his judgeship. When a loved one dies we go through depression, anger, and often a change of values. Also, after 20 years of leadership Samson was experiencing a middle age crisis. He felt the strong urge towards sin but he had no self control. We all have a propensity toward sin.
Temptations are very attractive.
But when you are tempted, he will also provide a way out, so that you can stand up under it. Samson failed because he played around with sin. He strangled a lion but could not strangle his lust. He burned crops of others, but lost the harvest of a fruitful life when he burned with the flame of lust. Some time back there was a story of several whales that were marooned on a beach and dying.