Save Across Levels

3549
3550
19
20

This example demonstrates using Global blocks to persist values when switching levels or restarting the game.

The Coins are stored in a Global block, so they are kept between levels. They are reset back to 0 when the game restarts.

Health is also stored in a Global block, and reset to its max value when the game starts.

Editor