People with melancholic temperaments often fall into great distress when they commit mortal sin because they imagine God to be some bearded man in the sky just waiting for them to fall into sin so that He can zap them with a lightning bolt.
Remember that your life is in God's hands alone. You will die when God wants you to die.
Avoid sin, but if you fall into sin, don't cower in a corner and not dare to go outside for fear that God will punish you with a sudden gust of ill wind, a car accident, etc. Sin prevents you from loving God, it doesn't prevent God from loving you and seeing that you have good intention in your heart. God knows our frailty even more than we know it ourselves. Like we pray in the De Profundis, if God were to deal with us justly according to our sins - who would be saved?