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

Fix: encoding tiles on PowerPC caused sprites to be incorrect #32

Merged
merged 1 commit into from
May 3, 2024

Conversation

rubidium42
Copy link
Contributor

When building on PowerPC to figure out a CMake issue, I noticed that the GRF files were changed and became significantly smaller.

Decoding the GRFs that were made on PowerPC essentially yields:
image

Where the following would be expected.
image

I suspected there are some alignment issues with PowerPC, so I replaced the pointer cast + BSWAP to just simple byte reading/writing, which is already the way it's done a few lines below anyhow.

@rubidium42 rubidium42 merged commit 61c256f into OpenTTD:master May 3, 2024
6 checks passed
@rubidium42 rubidium42 deleted the fix-powerpc branch May 3, 2024 10:34
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

Successfully merging this pull request may close these issues.

2 participants