# Source URL: https://dev.epicgames.com/documentation/en-us/uefn/make-your-own-in-game-leaderboard-in-verse
# Local doc: epic-docs/documentation/en-us/uefn/make-your-own-in-game-leaderboard-in-verse.md
# Section: player\_leaderboards\_example.verse
using { /Fortnite.com/Devices }
using { /Verse.org/Simulation }
using { /UnrealEngine.com/Temporary/Diagnostics }
using { PlayerLeaderboard }
# See https://dev.epicgames.com/documentation/en-us/uefn/create-your-own-device-in-verse for how to create a verse device.
# A Verse-authored creative device that can be placed in a level
player_leaderboards_example := class(creative_device):
# Visual representations of each player.
@editable
PlayerReferences:[]player_reference_device = array{}
# Billboards that display each player's stats.
@editable
Leaderboards:[]billboard_device = array{}
# Tracks when players complete a race, with the players in the first spot being awarded a win.
@editable
RaceManager:race_manager_device = race_manager_device{}
# The placement of a player must be at or below to award a win.
@editable
PlacementRequiredForWin:int = 1
# The number of points a player in each place earns.
# Adjust this to award your players the desired amount of score
# based on their placement.
@editable
PointsPerPlace:[]int = array{5, 3, 1}
# The spot of the player who just finished the race.
# The first three players to finish the race will be awarded a win.
var CurrentFinishOrder:int = 0
Verse Library
verse
32 Player Leaderboards Example Verse
Defines a customizable Creative Device class for tracking race times and displaying scores.
extracted-snippets/documentation/en-us/uefn/make-your-own-in-game-leaderboard-in-verse/32-player-leaderboards-example-verse.verse
Sign in free to read the full source 🌴
This Verse Library file is members-only. Create a free account to view the complete source and download the .verse file.