# Source URL: https://dev.epicgames.com/documentation/en-us/uefn/verse-prop-hunt-template-4-setting-up-teams-and-classes-in-unreal-editor-for-fortnite
# Local doc: epic-docs/documentation/en-us/uefn/verse-prop-hunt-template-4-setting-up-teams-and-classes-in-unreal-editor-for-fortnite.md
# Section: Creating Team Functionality With Verse
using { /Fortnite.com/Characters }
using { /Fortnite.com/Devices }
using { /Fortnite.com/UI }
using { /UnrealEngine.com/Temporary/Diagnostics }
using { /UnrealEngine.com/Temporary/SpatialMath }
using { /UnrealEngine.com/Temporary/UI }
using { /Verse.org/Colors }
using { /Verse.org/Simulation }
log_team := class(log_channel){}
# This class defines the devices needed for the different teams in the experience.
# This class is abstract so it cannot be used on its own. It has to be inherited by another class.
base_team := class<abstract>:
Logger:log = log{Channel:=log_team}
@editable # Used to set a player to the team.
ClassSelector:class_and_team_selector_device = class_and_team_selector_device{}
@editable # Used to award score to agents on the team.
ScoreManager:score_manager_device = score_manager_device{}
@editable # Used to display the team assignment title.
TeamTitle:hud_message_device = hud_message_device{}
@editable # Used to display the team assignment description.
TeamDescription:hud_message_device = hud_message_device{}
@editable # Used to subscribe to team member (prop team) or enemy (hunter team) eliminated events.
TeamManager:team_settings_and_inventory_device = team_settings_and_inventory_device{}
# This is an array of agents on the team.
var TeamAgents<private>:[]agent = array{}
# This event is signaled when the TeamAgents array becomes empty (signaling the end of the round).
TeamEmptyEvent:event() = event(){}
Verse Library
verse
01 Creating Team Functionality With Verse
Abstract base class providing shared device references, agent arrays, and logging for all game teams.
extracted-snippets/documentation/en-us/uefn/verse-prop-hunt-template-4-setting-up-teams-and-classes-in-unreal-editor-for-fortnite/01-creating-team-functionality-with-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.