-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Consider replacing List blocks with value types #20
Comments
For instance these are the number of lists contained (as embedded parts) in
|
I've made a quick and dirty test at https://github.com/carmineos/gta-toolkit/tree/test/lists replacing just Before
After
|
The list blocks should be replaced with value types, they are part of the structure data of the blocks which contain them, they are never referenced by another block, the actual references are the arrays the point at.
This will improve invoking GetParts which won't have to iterate on such "parts" and will drastically reduce number of allocations specially in resources like Particles.
They are all 16 bytes structs (pointer to array, count, capacity, padding).
The involved blocks are:
The text was updated successfully, but these errors were encountered: