Build a Performance-Based Row in Fortnite
Build a Performance-Based Row in Fortnite
Have you ever wondered how Fortnite picks the best islands for you to play? It uses special lists called "rows." One of the coolest is the "Performance-Based Row." This list shows islands that are running smoothly. Let's build a simple system that checks if our game is running fast. We will make a scoreboard that tells us if our island is "Smooth" or "Slow."
What You'll Learn
- What a Performance-Based Row is.
- How to use a Timer to measure speed.
- How to use Variables to store results.
- How to show a message to the player.
How It Works
Imagine your island is a video game console. Sometimes it runs fast. Sometimes it lags. The Performance-Based Row is like a report card. It looks at how well the game runs. If the game runs well, it goes on the "Good" list. If it runs poorly, it goes on the "Bad" list.
We want to build a mini-version of this. We will measure how long a task takes. This task is like a player jumping on a platform. We will start a timer. Then we do the jump. Then we stop the timer. If the time is short, the island is smooth. If the time is long, the island is slow.
We will use a Variable. A variable is like a box. You can put a number in it. You can change the number later. We will put our time measurement in this box. Then we will check the box. If the number is small, we print "Smooth." If the number is big, we print "Slow."
Let's Build It
We will use Verse to write the code. Verse is the language for Fortnite islands. We will create a simple script. It will measure time and print a message.
Here is the code. Copy it into your Verse file.
# This is our main script. It runs when the game starts.
using { /Fortnite.com/Devices }
using { /Verse.org/Simulation }
using { /Verse.org/Native }
# We define our device class.
performance_checker_device := class(creative_device):
# We define a function called MeasurePerformance.
# A function is a list of steps we can reuse.
MeasurePerformance()<suspends>: void =
# Start a stopwatch.
# This is like saying "Go!" at the start of a race.
StartTime : float = GetSimulationElapsedTime()
# Do a small task.
# Let's pretend this is a complex game calculation.
# We will just count up many times.
var Accumulator : int = 0
loop:
# This loop runs 1000 times.
# It takes a little time to finish.
set Accumulator += 1
if (Accumulator >= 1000):
break
# Stop the stopwatch.
# This is like saying "Stop!" at the end of the race.
EndTime : float = GetSimulationElapsedTime()
# Calculate the difference.
# This is how long the task took.
Duration : float = EndTime - StartTime
# Print the result to the screen.
# This is like showing the race time.
Print("Task took {Duration} seconds.")
# Check if it was fast or slow.
# If it took less than 0.1 seconds, it is smooth.
if (Duration < 0.1):
Print("Result: Smooth Performance!")
else:
# If it took longer, it is slow.
Print("Result: Slow Performance!")
# This runs when the island starts.
OnBegin<override>()<suspends>: void =
# Call our function to test performance.
MeasurePerformance()
Walkthrough
- Imports: We bring in tools from Fortnite and Verse.
- Function: We create
MeasurePerformance. This is our recipe. - Start Time: We grab the current time. This is the start of our race.
- The Task: We run a loop. This simulates game work.
- End Time: We grab the time again. This is the finish line.
- Calculation: We subtract start from end. This gives us the duration.
- Decision: We check if the duration is small. If yes, we say "Smooth." If no, we say "Slow."
Try It Yourself
Now it is your turn! Change the loop in the code. Try changing 1000 to 5000. Run the game again. What happens to the time? Does it get slower? Try changing it to 100. Does it get faster?
Hint: The number of times the loop runs changes the duration. More runs mean more time. This is how performance rows decide if an island is good or bad.
Recap
You built a simple performance checker. You learned how to measure time. You learned how to use variables to store that time. You learned how to make decisions based on that time. This is the basics of how Fortnite picks the best islands for you. Keep coding and have fun!
References
- https://dev.epicgames.com/documentation/en-us/fortnite/how-discover-works-in-fortnite
- https://dev.epicgames.com/documentation/en-us/fortnite/technical-performance-in-fortnite
- https://dev.epicgames.com/documentation/en-us/fortnite/sorting-algorithms-in-verse
- https://dev.epicgames.com/documentation/en-us/fortnite/ab-thumbnail-testing-in-fortnite-creative
- https://dev.epicgames.com/documentation/en-us/fortnite/spawning-a-grid-of-platforms-with-scene-graph-in-unreal-editor-for-fortnite
Verse source files
- 01-device.verse · device
Turn this into a guided course
Add 🔥 Performance-Based Rows to your free study plan — we'll suggest related pages and stitch the lot into one compile-checked, self-guided lesson with worked examples and quizzes.
References
Original tutorial generated by Verse Island from the Verse/UEFN knowledge base, with references to the Epic Games sources above. Code is validated against the knowledge base.