Morality's about how we treat each other, sim or not. Suffering hurts either way.
Consciousness is the only metric that matters. If an avatar's code is complex enough to feel pain, then griefing them is just as messed up as hurting someone in base reality.