In Learn the Basics of Writing Code in Verse, you learned how to create variables and functions. Now that you have some familiarity with the basics of writing code in Verse, let’s look at using Verse to create and work with a device in Unreal Editor for Fortnite (UEFN).
Creating a New Device with Verse
Follow these steps to create a Verse-authored device in UEFN:
Open your project in UEFN, then in the Menu Bar, go to Verse > Verse Explorer.
In Verse Explorer, right-click on your project name and choose Add new Verse file to project to open the Create Verse Script window.
In the Create Verse Script window, click Verse Device to select as your template.
Name your device by changing the text in the Device Name field to the name of your device. In this example, the device is named my_first_device.
Click Create to create the Verse file.
In Verse Explorer, double-click the name of your Verse file to open it in Visual Studio Code and edit it.
Adding Your Verse Device to Your Level
Follow these steps to add your Verse device to your level and run your code:
Before you can drag your Verse device into the level, you have to compile your code. In the Menu Bar, go to Verse > Build Verse Code.
Your device will appear in the CreativeDevices folder. This example the device is named my_first_device.
Drag your device into the level to run its code when you playtest.
In the toolbar, click Launch Session to playtest your project and save when prompted. This opens your Fortnite client. Click Start Game from the Main Menu to run your code.
Next Steps
Now that you've created a device using Verse and added it to your level, follow these guides to learn how to add functionality to your device:
Tutorials
For examples of how to use a Verse-authored device to build games, explore these guides:
Animating Prop Movement
Learn how to use Verse to animate prop movement for a Fall Guys obstacle course.
Create your own NPC Medic
Use Verse Code to create a custom NPC medic.
Custom Round Logic
Learn how to save information that persists across rounds and reset the persistent data when the multi-round game ends or a player leaves the session.
Disappearing Platform on Loop
Use Verse to create a platform that appears and disappears periodically.
Disappearing Platform on Touch
Create a platform using Verse that disappears when the player touches it and reappears a random number of seconds later.
Make Your Own In-Game Leaderboard in Verse
Create an in-game leaderboard that tracks player stats across games
Moving Objective Marker
Use Verse to create a moving objective marker.
Persistent Player Statistics
Learn how to create persistent player statistics that are saved between game sessions.
Synchronized Disappearing Platforms
Use Verse to create a series of platforms that appear and disappear in sequence using one device.
Tagged Lights Puzzle
Create a puzzle where the player has to find the right combination of lights on and off to spawn an item, using a device created with Verse.
Team Multiplayer Balancing
Use Verse to balance teams at runtime and when a player joins the game.
Transitioning Player Point of View with Cameras
Learn how to change the camera when a player opens a door to create a transition between areas.
Speedway Race with Verse Persistence Template
Learn how to add a local leaderboard and round-specific logic to your racing game!
Team Elimination Game
Use Verse to create a multiplayer competitive game mode that advances teams through a series of weapons.
Time Trial: Pizza Pursuit
Create a game with Verse where players must pick up and deliver pizzas before the time runs out!
Triad Infiltration
Use Verse to create a multiplayer competitive game that balances teams of players asymmetrically.
Verse Detonation Template
Use Verse with the Explosive device to create bombs for players to disarm.
Verse Elimination Template
Use Verse and the Item Granter device to create changing loadouts.
Verse Parkour Template
Create a parkour game with Verse to customize your gameplay.
Party Game
Follow this tutorial to create a Party Game island full of mini-games!