It can be a headache to deal with a troublesome neighbor. But if you play your cards right, you may end up having the last laugh.