It is unfortunate that an apparently expert enough coder in his prime productive age of 30s has pissed away his talent because of drugs and the effect that has had on his ability to integrate with society.
I would attribute all of his failure to the use of drugs. This probably causes his social paranoia and poor choices.