Repository navigation
v0.9.2
Additions
- Export BitReader and BitWriter for use in custom datatypes
- Fully adopt the pack-config system. Previous settings using the shared table no longer work. See docs for details
- Optional lengthType argument for Pack.Map
- Adds the
DisableReadProtectionproperty to Packets that stops Pack from raising an error if the entire packet wasn't read - Frac datatype that stores a number between [0–1] with fixed precision
- Datatype for NumberSequence and ColorSequence
- Adds Pack.Nil as an Alias for Pack.Null
Changes
- To get an exported internal library, you now must call the corresponding method, instead of using the dot operator. E.g., Pack:GetWriter()
- Rewrites Writer and BitWriter to use dynamic resizing, instead of using a Builder architecture. This will result in faster writer performance
- Enforces consistent behavior for BufferFixed and StringFixed. They will now raise an error on length mismatch even while not in debug mode
- [BREAKING]: Simplifies the vector datatypes. Pack.Vector3 and Pack.Vector2 have dynamic constructors, meaning Pack.Vector3 is equivalent to Pack.Vector3float32, and the other vector types can be obtained by calling Pack.Vector3 as a function: Pack.Vector3(Pack.Float16). If you were using the Vector3 and Vector2 alias, you do not need to change anything, Otherwise if you were using Pack.Vector3floatxx you will need to update that. This dynamic constructor allows creating a Vector3 from any numeric datatypes
- [BREAKING]: Makes Vector3int16 and Vector2int16 use the actual Roblox datatypes for this. To get the old behavior, use Pack.Vector3(Pack.Int16) / Pack.Vector2(Pack.Int16)
Fixes
- Adds a type for Pack.Literal so using it does not raise a type error
Full Changelog: v0.8.0...v0.9.0