Skip to content

Custom Leaderboard & Profile System #2258

Description

@infiniteparkour2406-art

Description

Complete system for rankings, player profiles, XP, levels, badges, statistics, friends, seasons, and visual customization for GDevelop games. Supports local rankings and integration with online APIs.

How to use the extension

Custom Leaderboard & Profile System

Extension for GDevelop that adds a complete system of rankings, player profiles, XP, levels, badges, and statistics.

How to use

  1. Install the extension

In GDevelop:

  1. Open your project.

  2. Go to Project Manager → Extensions.

  3. Select Add extension.

  4. Import the "CustomLeaderboardProfileSystem" extension.

  5. After installation, the actions, conditions, and expressions will appear in the event editor.

  6. Initialize the system

At the beginning of the game, initialize the system:

Event:

"At the beginning of the scene"

Action:

"Custom Leaderboard & Profile System → Initialize"

Player data will be loaded automatically.

  1. Profile Setup

You can set player information:

  • Name
  • Avatar
  • Banner
  • Country
  • Title
  • Bio
  • Level
  • XP
  • Coins
  • Statistics

Example:

"Set Profile String"

Field:

"name"

Value:

"My Player"

  1. XP System

To add XP:

"Add XP"

Example:

"Add XP → 50"

The system automatically calculates level progression.

To check:

"Profile::XP()"

"Profile::Level()"

"Profile::XPToNextLevel()"

  1. Statistics

Create custom statistics.

Example:

"Set Statistic"

Key:

"wins"

Value:

"10"

Then check:

"Profile::Statistic("wins")"

Any statistic can later be used as a ranking criterion.

  1. Badges

Unlock a badge:

"Unlock Badge"

ID:

"champion"

To verify:

"Profile::HasBadge("champion")"

It is also possible to create conditions to automatically unlock badges.

  1. Leaderboard

Submit player score:

"Submit Score"

Ranking:

"global"

Score:

"Variable(Score)"

Example:

"Submit Score("global", Variable(Score))"

To view the ranking:

"Leaderboard::NameAt("global", 1)"

"Leaderboard::ScoreAt("global", 1)"

"Leaderboard::Count("global")"

To view the player's position:

"Leaderboard::Rank("global")"

  1. Display ranking as text

Create a Text object in GDevelop.

Then use an expression:

"Leaderboard::NameAt("global", 1)"

This will display the name of the player in first place.

To display the score:

"Leaderboard::ScoreAt("global", 1)"

  1. Player Profile

Use expressions such as:

"Profile::PlayerID()"

"Profile::PlayerName()"

"Profile::Level()"

"Profile::XP()"

"Profile::Score()"

"Profile::Statistic("wins")"

These expressions can be used in text objects, variables, and events.

  1. Saving

Local data is saved automatically.

This allows you to maintain:

  • Profile
  • XP
  • Level
  • Badges
  • Statistics
  • Rankings

Even after the player closes the game.

It is also possible to use JSON export and import functions to back up the data.

Online Ranking

The extension is designed to allow integration with any backend via an HTTP API.

You can use your own server to:

  • Send scores.

  • Validate scores.

  • Search rankings.

  • Search profiles.

  • Update statistics.

  • Manage seasons.

  • Implement authentication.

Important: In online competitive rankings, scores must be validated on the server. The GDevelop client should not be considered a reliable source.

Complete Example

A basic system might work like this:

At the start of the scene
→ Initialize

Upon completing a stage
→ Add XP: 100

→ Submit Score:

Ranking: "global"
Score: Variable(Score)

If the player unlocks an achievement
→ Unlock Badge: "champion"

Level text

→ Profile::Level()

Position text

→ Leaderboard::Rank("global")

Top 1 text

→ Leaderboard::NameAt("global", 1)

Top 1 score text

→ Leaderboard::ScoreAt("global", 1)

Features

  • Leaderboards
  • Player profile
  • XP
  • Levels
  • Badges
  • Custom statistics
  • Local ranking
  • Persistent storage
  • Seasons
  • Public profile
  • Friends system
  • Search Players
  • Configurable online API
  • Customizable leaderboard interface

Compatibility

Designed for GDevelop games on:

  • Web
  • Android
  • PC
  • Other platforms compatible with GDevelop

License

Set the project license according to your desired distribution method.

Checklist

  • I've followed all of the best practices.
  • I confirm that this extension can be integrated to this GitHub repository, distributed and MIT licensed.
  • I am aware that the extension may be updated by anyone, and do not need my explicit consent to do so.

AI usage

  • I used an AI to generate some part of the code.
  • I don't understand the generated code or I don't feel able to modify it.

Example file

[Custom_Leaderboard_Profile_System_GDevelop-1.zip]

Extension file

[extension.json]

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions