oscarpilote / Ortho4XP

A scenery generator for the X-Plane flight simulator
490 stars 201 forks source link

Fix issue with zone_list saving in tile configuration #266

Closed shred86 closed 2 weeks ago

shred86 commented 3 weeks ago

This fixes #265.

After spending some time on this and ending up trying various ideas, this ended up being what I thought was the best and simplest solution. Basically, when write_tile_cfg is called, loop through the zones in self.v_["zone_list"] and compare each zone with the active tile coordinates. If any point (lat, lon) in each zone matches, then we append that to a new tile_zones list which is then saved to the tile configuration. For future reference (mostly for myself), here's some more details:

Changes:

The bottom two are obviously just clean up and personal preference, but I thought it was a simple but helpful change.

shred86 commented 2 weeks ago

Incorporated into #269