mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-01-01 20:42:08 +00:00
## About The Pull Request Ok so I found out that half our lighting sources are just lava pools This is becuase each turf has its own 5x5 square of light This is stupid. Wastes init time. Instead of this, lets do the space starlight style solution So for each turf, draw a light overlay on top of it, in the shape of the lava itself. (While we're here, let's make lava emissive so it can't get darkened by its own light) Then, we'll draw a dark lighting mask on top of the lava turf's lighting underlay. This way we can avoid light stacking This does mean we risk "missing" lighting that we should otherwise get, like if some very strong turf light was applied to the lava. I think I'm generally ok with that tho, since the case is rare and 0.6 seconds of init + quartering our light source count is pretty good. That 0.6 comes from saving 0.9 off lighting init, and losing about 0.3 to overlay shenanigins EDIT: It's likely more like 0.5 now since I took these numbers before I applied the light mask overlay Before  After  ## Why It's Good For The Game Init/cpu and memory savings