Open
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR swaps the world format to a serde-based approach for better compatibility with other libraries
Description
Currently we use bitcode for serialization which works fine, but has the major issue of not working with 3rd party libraries. This means we can't really store any data types that aren't from the standard library or us, so no dashmaps, bevy_math types, etc. This PR swaps it to use serde, but stil using bitcode as the actual serializer. This keeps a good chunk of the speed from bitcode while adding 3rd party lib compatibility.
It is about 3-10x slower, but thats absolutely dwarfed by the compression step so it's not a big deal unless someone invents a compression algorithm that can hit gigabytes of throughput.
The normal bitcode encoder is still used for player data mostly cos I CBA dealing with serde's lifetimes nonsense.
Main reason for all of this is to get started on storing entities.
How has this been tested?
World seems to load fine and benchmarks don't crash
Screenshots (if appropriate):
Types of changes
Checklist: