Quantcast
Channel: Photon Unity Networking (PUN) — Photon Engine
Viewing all articles
Browse latest Browse all 8947

Photon conflicts with Json.Net for Unity

$
0
0
In my current project I have imported the Photon Unity Networking package and the Json.Net for Unity package from parentElement.

This causes the error: Assets/3rdPartyTools/Photon Unity Networking/Editor/PhotonNetwork/AccountService.cs(181,45): error CS0433: The imported type `Newtonsoft.Json.JsonConvert' is defined multiple times.

Removing the Newtonsoft.Json.dll from the Photon Unity Networking\Editor\PhotonNetwork folder fixes the build errors, but now I am getting:

A script behaviour has a different serialization layout when loading (Read 24 bytes but expected 64 bytes)
and
PhotonNetwork threw an exception. Type: System.TypeInitializationException

Json.Net for Unity doesn't use the Newtonsoft.Json.dll, so I can't just remove it to clear the conflict.

Has anyone else ever experienced this problem? How did you resolve it?

Viewing all articles
Browse latest Browse all 8947

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>