I am assigning the PhotonView at runtime and trying to assign it's observed component, when I do I keep getting a null reference on the photonView .ObservedComponent[0] = this. Is there something I am doing wrong or is this a bug, works sometimes then wont work other times I can't reproduce it? I just tried to build the game and it worked and then I tried to build it again and now it tosses the error.
photon = this.gameObject.AddComponent<PhotonView>();
photon.viewID = 33;
photon.ownershipTransfer = OwnershipOption.Takeover;
photon.synchronization = ViewSynchronization.UnreliableOnChange;
photonView .ObservedComponents[0] = this;