multiplayer. how does IsNetRelevantFor function work??

I would start Network Tips and Tricks - Unreal Engine
It will explain conditional replication for you in detail.

You could do conditions for all values or do some clever check in


GetLifetimeReplicatedProps( TArray< FLifetimeProperty > & OutLifetimeProps ) const

And only replicate when apropriate.

Hope it helps
.