Re: Punishment
It’s not clear what you’re asking. Your question is a bit too vague by what you mean about mental torture.
Then those two quoted posts of yours make it look like you’re asking about if people who have been mentally tortured are accountable for their acts. Unless you give more specific examples, I don’t know what type of answer you’re hoping to get.
Or are you asking if Islam will take their mental/emotional state into consideration when handing out a verdict?