Perhaps not motivated by it but undeniably a factor. Imagine growing up gay in a Muslim family, knowing you would be outcast if your family knew your true feelings. Believing you are some sort of crime against God, for which many countries still apply capital punishment. No wonder this guy was a weirdo and an outcast.