Voxel Game Maker

Docs Cookbook

XP and leveling up

Game Settings ▸ Progress ▸ Experience and levels: set XP to reach level 2.

#Without code

  1. Game Settings ▸ Progress ▸ Experience and levels: set XP to reach level 2.
  2. Tick Show the XP bar and level (with Progress ▸ Experience and levels on).
  3. Enemies give XP when defeated; quests and Triggers use Give XP.
  4. Gate things with the condition Level at least.

#Quick code

Where it goes: Event: Player enters the world.

on("level_up", function(n)
  banner("Level " .. n .. "!")
  heal(50)
end)