I’m using OnSerializeNetworkView to sync all public fields of a ‘State’ script on distributed gameObjects.
It works fine when my fields are ints, floats or vectors.
Is there any way to use OnSerializeNetworkView to synchronize string fields too?
Keep your state as an enumeration and serialize it as an int. String are actually really heavy compared to other values, you shouldn’t use them over the network except where absolutely necessary.