Releases: colyseus/colyseus-unity-sdk
Releases · colyseus/colyseus-unity-sdk
0.15.12
- Fix cloning of ArraySchema and MapSchema (thank you @gregharding #231)
0.15.11
0.15.10
- Implemented parsing of ROOM_DATA_BYTES (Thanks to @BG-FraserConnolly #228)
0.15.9
0.15.8
- Add missing
client.Auth.GetUserData()
method. - First
OnChange()
call triggersGetUserData()
ifToken
is present.
0.15.7
New Auth API (https://github.com/colyseus/colyseus/releases/tag/0.15.15)
Define callback for Auth state change:
client.Auth.OnChange((Colyseus.AuthData<User> authData) =>
{
if (authData.user != null)
{
// Logged in!
}
else
{
// Logged out!
}
});
Methods:
client.Auth.RegisterWithEmailAndPassword()
client.Auth.SignInWithEmailAndPassword()
client.Auth.SignInAnonymously()
client.Auth.SendResetPasswordEmail()
client.Auth.SignOut()
- (❌ OAuth not yet implemented)
client.Auth.SignInWithProvider()
Example
class User
{
public int id;
public string email;
public string name;
}
// ...
try
{
var response = await client.Auth.SignInWithEmailAndPassword<User>("[email protected]", "123456");
Debug.Log(response.user.id);
Debug.Log(response.user.email);
Debug.Log(response.user.name);
}
catch (Colyseus.HttpException e)
{
// e.Message
// e.StatusCode
}
0.15.5
bump 0.15.5
0.15.4
0.15.3
0.15.2
fix issue with .Reconnect()