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 an active item cache bug that occurred upon map shift #36026

Merged
merged 1 commit into from
Dec 11, 2019

Conversation

Davi-DeGanne
Copy link
Contributor

@Davi-DeGanne Davi-DeGanne commented Dec 11, 2019

Summary

SUMMARY: Bugfixes "Fix an active item cache bug that occurred upon map shift"

Purpose of change

The cache of submaps with active items was being cleared too liberally in map::shift. Two "edges" were always being cleared (e.g. both north and east edges), even if the shift was occurring only in one direction (e.g. south, but not west or east). This means that sometimes, loaded submaps on the edge of the reality bubble with active items were being dropped from the cache, making the game "forget" about their items.

Partially fixes #32936
Partially fixes #33187

There are/were other things causing the same bug, but this was certainly a major contributing factor.

Describe the solution

Simply check that we are shifting away from an edge before dropping that edge's submaps from the cache.

Describe alternatives you've considered

Testing

@kevingranade confirmed that he had a reproduction case that this change successfully fixed.

Additional context

I fixed a blocker, wooo!
Actually this was mostly kevin's and ralree's work, I just swooped in at the last minute and stole all the credit 😁

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.

Smoking rack doesn't work until game reload Fertilizer Bomb doesn't ever go off.
2 participants