Update Notes

Bill Niblock 2024-08-21 14:49:27 +00:00
parent d205068f4c
commit b50cabcff1

@ -19,4 +19,9 @@ Considering palette swapping again. If I have the color, then a light grey, a da
Every time a tile is drawn, check the light level, and set the corresponding palette color accordingly. This doesn't have to happen every tick, though. The map only changes during certain scenarios: when the map is first drawn, to account for initial light sources; when the ball is hit, to account for the ball lighting up the course; when the player uses their flashlight. When these events happen, the map tiles can be updated. Otherwise, everything is set in memory, and no changes need to be made, just draw what's there.
Update: This kind of works! Except, it's palette _swapping_, not palette _replacing_. What I actually want is to replace the palette colors. Notably, I fixed my map call to only draw the map being shown on the display. This, in turn, made the callback function actually performant when changing memory values.
Update: This kind of works! Except, it's palette _swapping_, not palette _replacing_. What I actually want is to replace the palette colors. Notably, I fixed my map call to only draw the map being shown on the display. This, in turn, made the callback function actually performant when changing memory values. Because I can read values, I can easily read the values from the palette that I need, and then apply them when necessary. Instead of programming everything, I can just read it and save it.
```
local light_grey = peek4(mem)
```
Repeat for everything.