i fully understand why David prayed for God to create in him a clean heart and renew a right spirit within him. sometimes, the greatest battle is not with the people around us but with what is happening inside us. you can have a good heart and still need God to work on your attitude, your thoughts, your reactions and the things you struggle to control.
My view of homeless people changed forever when I learned that more than half of them were foster kids who aged out of the system and were left with no family or resources
The Bible is full of stories where God restores what people thought was lost, rebuilds what was broken, and gives purpose to what seems wasted. Never let a painful chapter convince you the story is over. God can still turn your situation around. He is not done writing your story.