MovingBlocks / DestinationSol

Official continuation of Destination Sol, the great fun little arcade space shooter from http://sourceforge.net/projects/destinationsol/ Modules live at https://github.com/DestinationSol/
Apache License 2.0
326 stars 123 forks source link

fix(map): fix incorrect object culling when panning map #677

Closed BenjaminAmos closed 1 year ago

BenjaminAmos commented 1 year ago

Description

The map culling logic was never adapted to cope with a panned map. It only appeared to work because another bug accidentally offset the in-game camera position by the pan offset, rather than calculating the map camera position.

This pull request fixes the bug that caused the panned map position to become the in-game camera position. It then adapts MapDrawer to correctly use the panned map position instead.

Testing

Notes

This fixes #564.