colyseus / colyseus-unity-sdk

⚔ Colyseus Multiplayer SDK for Unity
https://docs.colyseus.io/getting-started/unity-sdk/
MIT License
371 stars 102 forks source link

Deprecated warning on request error checking (Since Unity 2020.2) #142

Closed Nicolas-Constanty closed 3 years ago

Nicolas-Constanty commented 3 years ago

Hello, thank you for your hard work on Colyseus. I updated my Unity version and got some deprecated warnings from Auth.cs and Client.cs. Here is a pull request which should suppress the warnings for Unity 2020.2 and above.

PS : It should be compatible with older version since I used the define

if UNITY_2020_2_OR_NEWER

Vidski commented 3 years ago

Hi @Nicolas-Constanty, UnityWebRequest.Result got added with 2020.1, so the Pre-command should be #if UNITY_2020_1_OR_NEWER. 😉

Vidski commented 3 years ago

Can be closed 😊 Edit:

See: https://github.com/colyseus/colyseus-unity3d/pull/170