Skip to content

A Discord leveling bot (XP and leaderboard), built from blocks

Bot Creator has no ready-made leveling block. What it gives you is the parts: events, per-member variables, a calculator and a block that lists a variable's values sorted, which is all an XP system and a leaderboard need.

How to build it

  1. Create a command with an Event trigger on Message Create. Start with Stop Unless Condition (continue only if ((author.isBot)) is false) so bots earn nothing.
  2. Read the member’s XP with Get variable (scope: each member, per server; store it as xp), then add to it with Calculate (for example ((xp))+5) and save it with Set variable.
  3. Add the level rule you want (for example with an IF / ELSE Block comparing the value) and congratulate the member with Send Message.
  4. For the leaderboard, create a Slash command /top with List a variable’s values (scope: each member, sorted descending, up to 25 per call) and show the result with Respond with Message.

Blocks you will use

Block names are the ones of the app; each links to its entry in the dictionary.

What to know

  • You design the formula and the level thresholds yourself; nothing is preset.
  • Every message runs the flow, so keep it short. The Cooldown block exists but is described for commands; check that it fits your event before relying on it.
  • A leaderboard call returns at most 25 entries.

Go further

Other things you can build