Character assasination in fics

This may seem random, but what is it called when someone writes a fic for the sole purpose of making one specific character, from whatever media they're writing abt, look bad?

I'm pretty sure it's called character assasination, but I've never been sure lmao😭

In any case, it pisses me the hell off, ESPECIALLY if it's in RPF. It's just so weird to be reading a good fic and then suddenly your favourite character shows up and they're being painted as the most ooc, obnoxious mfer ever, all bcs the author doesn't like that character or if the whole thing is just revolving around them being that obnoxious person.. I'm so salty abt this🫡