[0.18.4] Odd interaction with surface.brightness_visual_weights, lights, and map mode

This subforum contains all the issues which we already resolved.
Yehn
Fast Inserter
Fast Inserter
Posts: 111
Joined: Tue Jul 12, 2016 3:45 am
Contact:

[0.18.4] Odd interaction with surface.brightness_visual_weights, lights, and map mode

Post by Yehn »

Using:

Code: Select all

game.surfaces[1].brightness_visual_weights = { 1 / 0.85, 1 / 0.85, 1 / 0.85 } 
When:

Code: Select all

game.surfaces[1].daytime == 0.5
results in some odd rendering on the map. In particular, light sources appear. For example, the engineer's flashlight:
Image
Image

Note that when scrolling the map, the light sources remain static relative to the viewport. i.e., the engineer's light stays centered even as that map scrolls.
Image
Image

Using:

Code: Select all

game.surfaces[1].brightness_visual_weights = { 0, 0, 0 } 
will restore the game to normalcy; the lights will no longer appear on the map.

Special thanks to @IronCartographer for bringing this to my attention and providing screenshots (And just to confirm, I was able to reproduce this on my own.)

Aside from using the commands above, the following steps can reproduce the problem:
1. Install and enable the Clockwork mod. Settings can remain on default.
2. Start a new game.
3. In game, run command:

Code: Select all

/c game.surfaces[1].daytime = 0.5
4. Open the map with the 'm' key. Note that it is completely normal.
5. Open the escape menu -> settings -> mod settings -> "map" tab -> set "Pitch Black Nights" to enabled.
6. Close out of the escape menu.
7. Once back to the game, press 'm' again to open the map. Note the light source is now on the map. Scroll around, and note the light source remains fixed relative to the viewport.
8. Open the escape menu again, navigating to the same settings as before. Set "Pitch Black Nights" to disabled.
9. Close out of the escape menu.
10. Once back to the game, press 'm' again to open the map. Note the light source(s) are gone in map view.

--

A final note: This would be really cool if it could be made into an officially supported feature. That is, if unlit sections of the map could be darkened at night - so lights would be needed to maintain intel outside of daylight hours.

posila
Factorio Staff
Factorio Staff
Posts: 5313
Joined: Thu Jun 11, 2015 1:35 pm
Contact:

Re: [0.18.4] Odd interaction with surface.brightness_visual_weights, lights, and map mode

Post by posila »

Thanks for the detailed report.
Fixed for 0.18.5

Yehn
Fast Inserter
Fast Inserter
Posts: 111
Joined: Tue Jul 12, 2016 3:45 am
Contact:

Re: [0.18.4] Odd interaction with surface.brightness_visual_weights, lights, and map mode

Post by Yehn »

That was very fast. Thanks!

Post Reply

Return to “Resolved Problems and Bugs”