Skip to content

Releases: colyseus/colyseus-unity-sdk

0.10.4

01 May 00:54
06998fe
Compare
Choose a tag to compare

(#69, thanks @etherny for reporting)

  • Uses Dictionary<int, T> internally instead of List for ArraySchema
  • Implement ForEach method on ArraySchema and MapSchema

0.10.3

23 Apr 00:10
Compare
Choose a tag to compare

Schema Serializer

Supports polymorphism on references, arrays, and maps. Example:

class State extends Schema {
    @type([ Entity ]) entities = new ArraySchema<Entity>();
}

class Entity extends Schema {
    @type("number") x: number;
    @type("number") y: number;
}

class Enemy extends Entity {
    @type("string") name: string;
}

// ... room handler
this.state.entities.push(new Enemy());

Breaking change

You need to re-run npx schema-codegen with the latest version of @colyseus/schema to have a working schema definition in the client-side.

0.10.2

31 Mar 22:46
Compare
Choose a tag to compare

Compatible with room proxying available on [email protected]

0.10.1

27 Mar 03:30
Compare
Choose a tag to compare

The schema serializer is now available for C#/Unity3D! 🎉

0.10.0

24 Mar 02:28
Compare
Choose a tag to compare

Compatibility with Colyseus 0.10.

(New serializer not available for this platform yet)

0.9.9

04 Mar 22:39
Compare
Choose a tag to compare
  • room.Leave() now has a consented argument, which is true by default.
  • room.Leave(true) - results in a consented=true leave in the server-side.
  • room.Leave(false) - results in a consented=false leave in the server-side.

You can use the consented value in the server-side for allowReconnection().

0.9.8

09 Feb 17:58
Compare
Choose a tag to compare

Add immediate option as third argument on Listen() method, as the other clients already have.

room.Listen("something", this.YourCallback, true)

This feature is useful for getting the initial state from the server. By using the third parameter as true, the callback specified will be called for the initial state as well as incoming changes.

0.9.7

07 Feb 02:01
Compare
Choose a tag to compare
  • fixes null values for onAuth() (thanks @Wenish for reporting 🙌 )
  • fixed "'DynamicMethod' could not be found" error on Unity2018.3.x (#54)

0.9.6

17 Jul 01:23
Compare
Choose a tag to compare
  • room.Leave() now plays nicely with onLeave(client, consented) in the server-side.

0.9.5

07 Jul 06:17
38e7b9f
Compare
Choose a tag to compare
  • GetAvailableRooms() is finally available (#44, thanks a lot @bhavik66 ❤️ )