# Help With Lighting!

**URL:** <https://forum.makecode.com/t/help-with-lighting/36529>\
**Category:** Help\
**Created:** [May 9, 2025, 6:05pm UTC](https://forum.makecode.com/t/help-with-lighting/36529 "2025-05-09T18:05:45Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![Fixitude](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/fixitude/32/28576_2.png) [@Fixitude](https://forum.makecode.com/u/Fixitude)\
**Post date:** [May 9, 2025, 6:05pm UTC](https://forum.makecode.com/t/help-with-lighting/36529/1 "2025-05-09T18:05:45Z")

</div>

Is there any way, to make as my depth goes deeper the lighting to get darker? I am making a deep sea diving game and I need help to see if this could work. If it works in a few days I will provide a demo.

---

<div class="post-metadata">

**Author:** ![jwunderl](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/jwunderl/32/5308_2.png) [@jwunderl](https://forum.makecode.com/u/jwunderl)\
**Post date:** [May 9, 2025, 6:07pm UTC](https://forum.makecode.com/t/help-with-lighting/36529/2 "2025-05-09T18:07:29Z")

</div>

this extension can do it

 ![image](https://us1.discourse-cdn.com/flex020/uploads/makecode/original/3X/2/8/284f70490048aa7bbe2929b12f2baa9bb7627073.png)

here’s a very simple one that just darkens a lil bit every time you press a [https://makecode.com/\_azpiE1Cb61YM](https://makecode.com/_azpiE1Cb61YM)

---

<div class="post-metadata">

**Author:** ![Skittlesaersuper](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/skittlesaersuper/32/17209_2.png) [@Skittlesaersuper](https://forum.makecode.com/u/Skittlesaersuper)\
**Post date:** [May 10, 2025, 6:01pm UTC](https://forum.makecode.com/t/help-with-lighting/36529/3 "2025-05-10T18:01:16Z")

</div>

You could use the color extension (It can be found in the default extensions) and set it so it applies the darken affect when you reach a certain point.  
But I’m not sure if you can make it darker multiple times.

---

<div class="post-metadata">

**Author:** ![Fixitude](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/fixitude/32/28576_2.png) [@Fixitude](https://forum.makecode.com/u/Fixitude)\
**Post date:** [May 10, 2025, 6:11pm UTC](https://forum.makecode.com/t/help-with-lighting/36529/4 "2025-05-10T18:11:33Z")

</div>

Thank You So Much!!! That really helped and I have implemented it in my game. Thanks a lot!

---

<div class="post-metadata">

**Author:** ![Fixitude](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/fixitude/32/28576_2.png) [@Fixitude](https://forum.makecode.com/u/Fixitude)\
**Post date:** [May 10, 2025, 6:11pm UTC](https://forum.makecode.com/t/help-with-lighting/36529/5 "2025-05-10T18:11:42Z")

</div>

Also is there any way to store tile maps like saves then load it again in the same position afterwards?

---

<div class="post-metadata">

**Author:** ![WoofWoof](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/woofwoof/32/32523_2.png) [@WoofWoof](https://forum.makecode.com/u/WoofWoof)\
**Post date:** [May 10, 2025, 9:04pm UTC](https://forum.makecode.com/t/help-with-lighting/36529/6 "2025-05-10T21:04:05Z")

</div>

The Settings extension lets you save data that isn’t lost when the simulator restarts. I know it is quite easy to grab the current tilemap data when coding in JavaScript, but with blocks I do not believe anyone has made an extension that gives you that ability.

The JavaScript code would be  
`game.currentScene().tilemap.data[‘data’]`  
That would be the actual raw Buffer containing which tile is on each square of the tilemap, and then you could create a tilemap with said data when you needed to.

---

<div class="post-metadata">

**Author:** ![Fixitude](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.makecode.com/fixitude/32/28576_2.png) [@Fixitude](https://forum.makecode.com/u/Fixitude)\
**Post date:** [May 10, 2025, 10:06pm UTC](https://forum.makecode.com/t/help-with-lighting/36529/7 "2025-05-10T22:06:02Z")

</div>

Thanks, that helps! I will find a solution to this problem! Just wanted to know if it is possible.
