InvalidCastException: Specified cast is not valid.

Options
When I have more than one characters in game this error occurs.

I tried all sync combinations disabled, discrete and continuous. It changed nothing.

NullReferenceException: Object reference not set to an instance of an object
Photon.Pun.PhotonAnimatorView.DeserializeDataContinuously () (at Assets/Photon/PhotonUnityNetworking/Code/Views/PhotonAnimatorView.cs:370)
Photon.Pun.PhotonAnimatorView.Update () (at Assets/Photon/PhotonUnityNetworking/Code/Views/PhotonAnimatorView.cs:150)

Comments

  • JohnTube
    JohnTube ✭✭✭✭✭
    Options
    Hi @kureysalp,

    Thank you for choosing Photon and for your report.

    How can we reproduce?
    What is the PUN version used?
    What is the Unity version used?
    What are the minimal repro steps?
  • kureysalp
    kureysalp
    edited July 2019
    Options
    How can you reproduce;

    1- Create a lobby scene with join room button.
    2- One player creates a room with join room button and the other player joins with same button.
    3- When player count in room is equal to max players (2) load level from master and sync from others. (Other player is unity build on same pc)
    4 -PhotonInstantiate players when level loaded.
    5- Players have photon view, transform view and animator view.
    Then error occurs.

    Unity version: 2019.1.8f1

    Pun version: Pun 2 (2.13) latest version I think.
  • kureysalp
    Options
    Nothing?
  • jeanfabre
    Options
    Replied in our private conversation.

    Bye,

    Jean
  • marswong
    Options
    Anything to share with the class...?
  • JohnTube
    JohnTube ✭✭✭✭✭
    Options
    Yes, @jeanfabre, @kureysalp care to share more info on this?

    Otherwise, @kureysalp, the title of this discussion has InvalidCastException although the quoted error in the original post has NullReferenceException so which is it?