A Haxe library for fast binary serialization and network synchronization with versioning and RPC support.
HxBit is a Haxe library for binary serialization and network synchronization, designed to efficiently serialize object graphs and replicate state across networked clients and servers. It solves the need for fast, type-safe data exchange in applications like multiplayer games or distributed systems, offering features like versioning and remote procedure calls.
Haxe developers building networked applications, such as multiplayer games, real-time collaborative tools, or any system requiring efficient object state synchronization over a network.
Developers choose HxBit for its macro-generated serialization code that outperforms Haxe's standard runtime serialization, combined with built-in networking features like automatic change tracking and RPCs, reducing boilerplate and ensuring robust state management.
Haxe Binary serialization and network synchronization library
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Uses compile-time macros to generate strictly typed code, outperforming Haxe's runtime serialization for speed, as noted in the comparison with haxe.Serializer.
Provides automatic change tracking and delta updates for object states, enabling efficient multiplayer or collaborative apps without manual sync code, via enableReplication and host.sync().
Handles schema evolution by detecting added or removed fields during unserialization, ensuring backward compatibility with saved data or network states using beginSave/endSave.
Supports annotated remote procedure calls with modes like all, server, and owner, including return values and asynchronous callbacks, simplifying networked logic.
Macro-generated serialization code adds to the final binary size, which can be a drawback for projects with strict memory or download constraints, as mentioned in the comparison section.
Changes to mutable structures like arrays or maps trigger sending of the entire content over the network, not incremental updates, potentially wasting bandwidth in data-heavy apps.
Networking requires implementing a custom NetworkHost (e.g., SocketHost for Heaps) and managing object lifecycles, adding initial development overhead compared to drop-in solutions.
Unsupported types require custom implementation via customSerialize and customUnserialize methods, adding boilerplate and potential for errors.