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 disappearing planets in network games (they turned into BHs) #8

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

HAL20000
Copy link

@HAL20000 HAL20000 commented May 8, 2019

This fixes a bug in network games: Some plantes would (visually randomly) disappear in the client game. Inspection showed, that the client instance would create Black Holes for any planet of the host instance which has a sprite number (Planet.n) larger than MAX_PLANETS, however, this is not sensible. By replacing this with the number of sprites (8 in the current implementation), the bug is fixed. Since the numebr of sprites might change, a corresponding constant was introduced into as Settings.NUM_PLANET_SPRITES.

HAL20000 added 4 commits May 8, 2019 22:33
Comment on recent changes and try to be consistent with
prevalent code concerning the formatting of consitionals.

Fixes Problems with network mode on *nix platform (tested), might also
solve problems on different problems that have been reported
@ryanakca
Copy link
Owner

Hi!

Sorry for the delay. I did a bit of work on merging your changes and Florian Schüller's this morning, but it seems that I broke network games. I'll try to debug that later on this week. Here's the merge branch if you're curious: https://github.com/ryanakca/slingshot/tree/merge-schuellerf-HAL20000

Thanks for your contribution to Slingshot!

@HAL20000
Copy link
Author

HAL20000 commented Jun 13, 2019 via email

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