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

added A 'return' to growZone method #27

Merged
merged 2 commits into from
Feb 25, 2018
Merged

Conversation

emalron
Copy link
Contributor

@emalron emalron commented Jan 31, 2018

I found a bug which a residential zone was getting bigger without any effort. R-Zones need high population density to be promoted from 'FREEZ' tile.

At line 126 in Residential.js, the conditional statement checks if the residential zone meet the requirement to grow population. and the program should be escaped growZone method when one is failed the population density check.

previous version keep going to the next conditional statement, so the R-Zones can keep growing its population with low density.

At line 126 in Residential.js, the conditional statement checks if the residential zone meet the requirement to grow population.  the growZone method should be quit if one is failed the check.
resolution issue fixed
@graememcc
Copy link
Owner

Thank you so much for this pull request, and spotting these logic errors! I'll bet the temp map clearing helps with issue #21.

After I merge this, I'm going to push a follow-up commit, as there was some commented out console logging left in there (I do that all the time!). The else branch in BlockMapUtils.js looks unnecessary now after your fix, so I might get rid of that too.

I'll try to have the version with your changes up on my URL within the next half-hour from time of writing.

Sorry I took so long to get to this, and thanks, once again!

@graememcc graememcc merged commit ffa0634 into graememcc:master Feb 25, 2018
@graememcc
Copy link
Owner

Should now be live at http://graememcc.github.io/micropolisJS

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