In this last step of the Time Trial: Pizza Pursuit tutorial, you'll find the complete code for the game and ideas to explore on your own for this game.
Complete Code
There are multiple Verse files in this project:
countdown_timer.verse: See Custom Countdown Timer for the file’s complete code.
game_coordinator_device.verse: See below for the file’s complete code.
objective_marker.verse: See the Moving Objective Marker tutorial for the file’s complete code.
pickup_delivery_zone.verse: See below for the file’s complete code.
score_manager.verse: See below for the file’s complete code.
game_coordinate_device.verse
using { /Verse.org/Simulation }
using { /Fortnite.com/Devices }
using { /Fortnite.com/Vehicles }
using { /Fortnite.com/Characters }
using { /Fortnite.com/Playspaces }
using { /Verse.org/Native }
using { /Verse.org/Random }
using { /UnrealEngine.com/Temporary/Diagnostics }
using { /UnrealEngine.com/Temporary/SpatialMath }
using { /UnrealEngine.com/Temporary/Curves }
pickup_delivery_zone.verse
using { /Verse.org/Simulation }
using { /Verse.org/Random }
using { /Verse.org/Concurrency }
using { /Verse.org/Simulation/Tags }
using { /UnrealEngine.com/Temporary/SpatialMath }
using { /Fortnite.com/Devices }
<# A zone is an area of the map (represented by a device) that can be Activated/Deactivated and that provides events
to signal when the zone has been "Completed" (can't be completed anymore until next activation).
Zone "Completed" depends on the device type (ActivatorDevice) for the zone.
score_manager.verse
using { /UnrealEngine.com/Temporary/UI }
using { /Fortnite.com/UI }
using { /Fortnite.com/Devices }
using { /Verse.org/Simulation }
MakeScoreManager<constructor><public>(InPlayer : player, InScoreManagerDevice : score_manager_device) := score_manager:
MaybePlayer := option{InPlayer}
MaybePlayerUI := option{GetPlayerUI[InPlayer]}
score_manager := class:
On Your Own
By completing this guide, you’ve learned how to use Verse to create the full time trial game Pizza Pursuit.
Using what you’ve learned, try the following:
Add more pickup zone levels.
Add different types of delivery zones. Extend the
base_zoneclass so the player has to activate some other device, like a button, to complete the zone.Make the player exit the kart and complete a short obstacle course on foot to deliver the pizza.
Activate multiple zones at the same time.
Modulate the zone selection criteria based on distance from the player.