Exception: cannot serialize(): UnityEngine.RaycastHit

Hello, how i can serialize RaycastHit?

Comments

  • JohnTube
    JohnTube ✭✭✭✭✭
    Hi @skokon,

    Thank you for choosing Photon!

    Why would you need to send UnityEngine.RaycastHit over the network? what is the use case? maybe you can send different data instead.

    In any case, to be able to exchange a type unknown to Photon, you need to register the type in Photon. Read all about this here.
  • JohnTube said:

    Hi @skokon,

    Thank you for choosing Photon!

    Why would you need to send UnityEngine.RaycastHit over the network? what is the use case? maybe you can send different data instead.

    In any case, to be able to exchange a type unknown to Photon, you need to register the type in Photon. Read all about this here.

    I looked at the code after and i laughed, i was using the raycast hit position and the transform, instead of passing the whole raycast hit i passed the position param and the transform param