MakeCode Games!

A fan-made community library of MakeCode Arcade games. Visit MakeCode Arcade to make a game!

← Back to extensions

Lantern

Create dark levels with dynamic lighting effects like circular lanterns, glowing torches, and directional flashlights.

set light band width

Problem it solves

Your player collected a torch upgrade and you want their lantern circle to cast light much further across the screen.

What this block does

Sets the thickness of the concentric light rings for the single lantern effect, making the illuminated area larger or smaller.

The block

true block

Parameters

NameTypeDefaultMeaning
widthnumber13The width in pixels of each light ring (larger numbers make a bigger overall light circle).

Example

lantern.setLightBandWidth(20)

Add the extension

Add github:felixtsu/pxt-lantern to your project, or open: Import pxt-lantern.