Best Practices
Limitations and Best practices
- Each
Schema
structure can hold up to64
serialized fields. If you need more fields, use nestedSchema
structures. NaN
andInfinity
are encoded as0
(integer encoding only)null
strings are encoded as""
(both “string” and “cstring” encoding)- Multi-dimensional arrays are not supported. See how to use 1D arrays as multi-dimensional
@colyseus/schema
encoding order is based on field definition order.- Both encoder (server) and decoder (client) must have same schema definition.
- The order of the fields must be the same.
Last updated on