If a parent never raised, sheltered, or educated you, and engages in Haram activities and communicating with them is toxic, is it allowed to cut ties with them?
It is good to treat him/her with respect and maintain some form of communication or offer assistance if it is necessary. However, silat al-rahm (maintaining family ties) is a rather broad concept which can be done in many ways. It is not necessary to have a close or frequent relationship. You can weigh what is appropriate for your situation. In some cases, the use of technology (such as e-mail) can help in being a safe and controlled way to manage the situation.
The primary thing that the Qur'an empahsises is respect and secondarily compassion. It is also related in hadith that if a person is dealing with parents who beat them, it is best to say "May Allah forgive you". That is, it is good to try to let go of resentment and move towards forgiveness in cases where the parents were not ideal.
For some people, one of the tasks of adulthood is to come to terms with the fact that parents are flawed human beings, like everyone else. We are usually more accepting of strangers with major flaws, but it can be difficult to accept this in a parent, because a child looks to a parent as a godlike figure and provider. The shifting power dynamic in adulthood can help with this, since once someone is no longer in need of their parent for their survival, it is easier to be more objective and accept things as they are.
Generally, as we progress through adulthood, it becomes easier to recognize and sidestep unhealthy psychological behavior (for instance, being pushed to enable an addiction, relive someone else's trauma, and so forth). Of course you should not participate in haraam activities; generally, as we get older, it gets easier to draw personal boundaries and assert that there are some things we will not do.
Whether we like it or not, our biological parents are our biological parents, we share some things with them, and there will always be a link. Cutting off ties does not change that. It may suppress the situation or make it no longer a practical concern and may result in more peace of mind, but the link and impact still persists psychologically.
Also, if you have children, it is healthy for them to have some contact with their grandparents. True, some people do keep children away from their grandparents if they feel they are a bad influence (you mention haraam activities), and this also has to be weighed; but keeping them fully in the dark about their ancestors leaves a blank spot in their minds and sense of self. It also increases the likelihood that the same pattern will be enacted by them (even if you are a good parent towards them). They will subconsciously copy your actions. Similarly, if you speak respectfully of your parents (even if you may feel anger), they will learn that attitude towards parents, but if you speak angrily and critically of them, they will learn that attitude towards parents.
Anyway, life is challenging, and the world is far from ideal. Perhaps the best way to handle the situation for now is simply to pray sincerely for guidance and to see where that takes you.