Substance abuse
In many cases, when a person is using drugs, their thinking and behaviors change. Sometimes, they commit crimes while using drugs. They may do things that are not safe, like drive a car while drunk.  When people abuse drugs over a longer time, their personalities often change as well. The people who abuse drugs are often addicted. Since many of these drugs are illegal, very often drug users have problems with the law.