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

Freeze issue when demo is over #1

Open
gameblabla opened this issue Feb 3, 2019 · 0 comments
Open

Freeze issue when demo is over #1

gameblabla opened this issue Feb 3, 2019 · 0 comments

Comments

@gameblabla
Copy link

Oi,
thanks for porting Cannonball to C !
I did notice an issue with it though. When you start the game and let the demo play for a while, it should normally display the highscore leaderboards. Instead, it freezes.
What happens is that it becomes stuck in a loop.
https://github.com/lantus/Cannonball-C/blob/master/src/main/engine/audio/osound.c#L473

The problem is that chan_ram is 0x800 in size and uint8_t is not big enough for the for loop to clear its memory so it promptly becomes stuck. Original source code was using uint16_t here, not sure why you decided to use an uint8_t here.
Switch it to uint16_t and the leaderboard appears like normal.
Not sure if this happens on a real Amiga but it definitely happens on a PC.

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

1 participant