Skip to content
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

incorrect generation of bitfields #11

Open
nyrpqsqq35 opened this issue Aug 12, 2024 · 2 comments
Open

incorrect generation of bitfields #11

nyrpqsqq35 opened this issue Aug 12, 2024 · 2 comments

Comments

@nyrpqsqq35
Copy link

i reported this to u on discord in march but you never replied and it doesnt look like it ever got fixed

the boolproperty bitfields in some classes dont generate correctly because the bps dont take 32 bits
this is easily solved by generating bitfields like this (union with the bitfields inside of a struct)
image

you might find it beneficial to generate a verifier source file that has static_assert statements verifying the offsetof properties/sizeof objects is what you expect it to be to discover some of these issues yourself

additionally there's probably still heaps of struct packing/alignment issues since you rely on the developer's compiler to align members and your logic for adding padding manually is flawed

@nyrpqsqq35
Copy link
Author

it also looks like some of the bitfields dont start at 1<<0 (shown in my picture) idk if thats fixed in your gen (probably not)

@ItsBranK
Copy link
Member

This is a game specific issue not global, Rocket League has two different bool types and doesn't calculate offsets or report the size of padding correctly in some cases.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants