Bad reputation is very powerful to use for your practice, and it should be used that way. As a Kadampa geshe once said, "If someone criticizes you, this destroys your mistakes; it blows away immediately one’s own mistakes. If you are praised, it causes pride/the ego to inflate and causes great pride."
These are some quotations for transforming bad conditions into happiness by looking at them as positive, favorable conditions:
"If one has wealth, there is suffering in collecting and protecting it. If one is poor, this is the objectivity of Dharma."
"Suffering is the broom clearing away negative karmas."
"Suffering is the manifestation of emptiness (this means to look at the nature of suffering as empty, by meditating on its emptiness). Then, the suffering doesn't bother you. Seeing it as inherently existing, real suffering disturbs the mind, the mind becomes easily overwhelmed by a problem, whereas the other way – seeing its emptiness – the mind is able to overwhelm the problem like a flood."
"Suffering is the blessing or kindness of the guru." Here, the blessing is the purification of negative karma, suffering being the result of negative karma (which is now ending).
Geshe Kharag Gomchung said, "Bad or adverse conditions are the virtuous friend, these obstacles are the inspiration persuading you to practice virtue."
"Suffering is the result of my negative karma, therefore don't dislike it or look at it as an obstacle."
Transforming bad conditions into happiness by looking at them as positive, favorable conditions is the way to make problems, bad conditions, beneficial, by using them as the path to enlightenment. How? Meditating on loving kindness and bodhicitta destroys the ego. We use them as a weapon to destroy the self-cherishing thought, which brings all obstacles. So, meditate on bodhicitta and wisdom.
In your case, use all the criticism and bad reputation, whether it is a result of your mistake or not, to destroy your ego and self-cherishing thought, which blocks one from achieving enlightenment. As long as self-cherishing abides in one’s heart, it stops one achieving enlightenment and benefiting all sentient beings. You can think of the kindness of the other person that helps you to destroy your ego. Usually, you are always supporting your ego, even developing it. Now, this person (the enemy) is helping to destroy your self-cherishing thought, so what is regarded as your enemy is really your most kind friend!
What we do is use undesirable situations, loss, etc., as experiences to be of most benefit to all sentient beings. This is not just making one’s own life emotionally happy, for some temporary peace.
There are other thought transformation teachings – so many ways you can make your life experience most beneficial for yourself and others. The essence is – if you are happy, make it beneficial for sentient beings; if you are suffering, use it as the cause to bring happiness to others. This way, whatever kind of life experience you have, use it on the path. There is no interruption to Dharma practice, and one’s life is most beneficial.
Go Tsampa said, "Others’ mistakes are one’s own mistakes. Clarify the appearance of the mistake into the deity." This means, however one is treated is the result of one’s own negative karma. Even if others create a bad reputation for you, and there is no apparent cause from your side to experience the result, still, you have to have created the cause. You can see what this yogi is saying. The second part of this technique is looking at that person as the guru, even visualizing that person in the form of a deity. This stops anger and negative emotional thoughts arising and the suffering results of those.
Geshe Kharag Gomchung said, "Experiencing this small suffering now finishes past negative karma, and there will be happiness in future lives. Because it finishes past negative karma, be happy for the suffering."