[SOLVED]Send a variable to an object type variable by using Stream

Debug.Log(“animation playing”);
stream.SendNext(“test”);//what should I send to target, target is an object variable

I’m working on Photon Unity Networking I want to send a variable to an object type variable by using stream and what should I send exactly I dont know I’m confused.

Here is the methods for sending and receiving data:

 public void SendNext(object obj)
        if (!this.write)
            Debug.LogError("Error: you cannot write/send to this stream that you are reading!");


public object ReceiveNext()
        if (this.write)
            Debug.LogError("Error: you cannot read this stream that you are writing!");
            return null;

        object obj = this.data[this.currentItem];
		Debug.Log(obj);//I'm watching the values
        return obj;

And here is some stream samples:


In this case it looks like you might want to send parts of the AnimationState, like time, to interested parties. But, really, the animation controller should be clever enough to decide what to do based on the velocity and other states. There are a ton of good sources out there for photon unity networking.

Also, maybe you could clarify exactly what you are trying to accomplish here?