Nigger actually meant "dirty or filthy". Then slave-owners got a hold of it, and used it with basically the same meaning. And now it's morphed into a derogatory word.