Depends on the person. For me, there are 3 categories of people, and I treat each accordingly.
1) The purely useless people
These are the kind of people I have assessed to be ultimately useless and that they'll not be useful in the future either. I hold them in contempt and feel no need to protect their feelings / show any positive regard towards them. I make fun of them, belittle them and their accomplishments, ignore their needs, preferences, ideas, and wants, and communicate with them only when I need some sort of verbal punching bag.
2) The useful and self-respecting
These people are useful in some form but narcissistic, or just have some self-respect and self-esteem. With this category, I make sure to ingratiate myself with empathic support, compliments, entertainment, and affection (as long as they don't demand too much and aren't getting annoying). But I have no real emotions for them. I fake it to fulfill their emotional needs / gain more control over them.
3) The useful but broken
These are the emotionally broken, low self-esteem, low self-entitlement people, most having a past of severe abuse and mistreatment. Now, ingratiating myself with them and being flattering, complimenting would backfire because it would invalidate their beliefs of being worthless, good for nothing, being unworthy of positive treatment etc. So I treat them as if they were useless, keeping their desire of fixing me or making me love them alive, to keep the wheel rolling. Ironically these people tend to be the most emotionally satisfying, compliant, and useful (sometimes more than the useful and high self-esteem) but them not realizing this is what gives me power over them, so I don't try to change it.