When Tilted ()
when tilted ( v):: boost
Category LEGO BOOST
Type Hat
Introduced in 3.0

The when tilted () block is a hat block and a LEGO BOOST block. Its options are "up", "down", "left", "right", and "any". It activates when the LEGO BOOST unit is tilted in the specified direction.

Example uses

Moving a sprite based on the LEGO BOOST's tilt:

when tilted (up v):: boost
change y by (10)
when tilted (down v):: boost
change y by (-10)
when tilted (left v):: boost
change x by (-10)
when tilted (right v):: boost
change x by (10)


Cookies help us deliver our services. By using our services, you agree to our use of cookies.