[PAID] [ESX] Team System

Team System

About:

Team System and Team Management System - players can see each other’s blip on the map after joined the same team. Also, players on the same team can’t shoot each other and the name and health bar can be seen above the teammate’s head. In the config, you can choose whether only members of the same team can ride in the same vehicle. Team members can also teleport to teammates. On the other hand, powerful team management system (Admin Only), the admin can manage all teams efficiently.

Features:

  1. Team System

    • Any player can create their own team (custom team name) - /createteam [teamname]
    • Leader can invite two four players to join the team - /invite [id]
    • Players can see each other’s blip on the map after joined the same team
    • Leader can transfer leader to team members - /pass [id]
    • Leader can kick the player out of the team (blips with team will disappear when the player leaves the team) - /drop [id]
    • Leader can disband the team - /disband
    • Players can leave the team on their own (blips with team will disappear when the player leaves the team) - /q
    • Players on the same team can’t shoot each other
    • Team members can teleport to teammates
    • Player can request to join the team, after the leader of that team accept your request, you will join into the team
    • When players are on the same team, the name and health bar can be seen above the teammate’s head

  2. Team System - Admin Panel (Admin Only, can set in Config)

    • Force players to join the team - /forcejoin [id] [team]
    • Force kick the player out of the team - /forcedrop [id]
    • Force transfer the leader role to team member - /forcepass [id]
    • Force disband the team - /forcedisband [team]
    • Force disband all teams - /forcedisbandall
    • Powerful team management system (Admin Only)

  3. Common features

    • Editable Config
    • Simple but user-friendly UI (you can edit the UI yourself if you want), players can also use the commands
    • Keybinds can be configured either by config.lua or in game by pressing Esc > Settings > Key Bindings > FiveM
    • 2 translation locales (en/zh), allow self-translation to the language you want (need to be added in fxmanifest.lua or overwrite the original text)
    • All teams will be stored in the database and will be updated automatically
  4. The Merge Team function

    • Team leader allows to merge with other two teams. After the merger, the team will not change, it is still only the leader of that team can invite players to join or kick the team members out of the team.
    • All members of the team that have merged with your own team can see each other’s blips on the map (The color of blips: own teammate are green, merge team member are purple) and can’t shoot each other.
    • All members of the team that have merged with your own team can also be teleport to each other
    • The color of the team that merged with your own team on the team list will change to purple, and “Show My Team only” will also show the team that merged with your team.
    • A total of 3 teams can merge with each other, that is up to 15 players (5 players x 3 teams) can merge into the same team.
    • Team leader can cancel the merger with other teams, just press the name of your team on the team list and press “Cancel merge team” button to cancel the merger with all teams.

Available Commands:

Commands for everyone
Commands Description
/createteam [teamname] Create a team (custom team name)
/invite [id] Invite a team member (Only leader can invite)
/pass [id] Transfer the leader role to team member (Only leader can transfer)
/drop [id] Kick the teammate out of the team (Only leader can kick)
/disband Disband the team (Only leader can disband)
/y Accept the invitation to join the team
/n Reject the invitation to join the team
/q Quit the team
Commands for Admin Only
Commands Description
/forcejoin [id] [team] Force the player to join a specified team
/forcedrop [id] Force kick the player out of the team
/forcepass [id] Force transfer the leader role to team member
/forcedisband [team] Force disband a specified team
/forcedisbandall Force disband all teams

Config:

config.lua
Config = {}

-- Available Locales: 'en', 'zh'
Config.Locale = 'en'

-- Versions supported (1.1 / 1.2 / legacy)
Config.ESXversion = 'legacy' -- **Mainly different in the command part**

Config.Mysql = "mysql-async" -- (mysql-async / oxmysql)  -- If using oxmysql, remember to comment "@mysql-async/lib/MySQL.lua" and uncomment '@oxmysql/lib/MySQL.lua' in fxmanifest.lua
-----------------------------------------------------------------------------

Config.EnableMergeTeamFunction = true -- If false, Players cannot use the merge team function

-----------------------------------------------------------------------------

-- Command for opening the TeamSystemMuen UI
Config.OpenTeamSystemMuenCommand = 'teammenu'

-- Key for opening the TeamSystemMuen UI
Config.OpenTeamSystemMuenKeybind = 'F4'

-----------------------------------------------------------------------------
-- Groups that can use Keybind to open TeamSystemMuen_AdminPanel
Config.admin_groups_AdminPanelKeybind = {"admin", "superadmin"}

-- Command for opening the TeamSystemMuen_AdminPanel UI
Config.OpenTeamSystemMuen_AdminPanelCommand = 'teammenu_admin'  -- Only in Config.admin_groups_AdminPanelKeybind can use this command to open the TeamSystemMuen_AdminPanel UI

-- Key for opening the TeamSystemMuen_AdminPanel UI
Config.OpenTeamSystemMuen_AdminPanelKeybind = 'F5'  -- Only in Config.admin_groups_AdminPanelKeybind can use this Keybind to open the TeamSystemMuen_AdminPanel UI

-----------------------------------------------------------------------------

Config.UseSteamName = true -- If false, it will use the first name + last name to display the player name on the UI

------------------------------------------------------------------------------

Config.ShowTeamInfoBar_Name = true  -- If false, it will not show health bar above the teammate's head after player joined the same team and players cannot set in the UI setting

Config.ShowTeamInfoBar_healthBar = true  -- If false, it will not show health bar above the teammate's head after player joined the same team and players cannot set in the UI setting

--------------------------------------------------------------------------------

Config.ShowNotification = true  -- If false, it will only have chat room message

-- Scripts supported (mythic_notify / pnotify / 413x-notify / default)
Config.NotificationScript = "default"  -- default = ESX.ShowNotification()

---------------------------------------------------------------------------------

Config.EnableTeamKill = false  -- If set to true: team members can attack each other even if joined the same team ; If set to false: team members cannot attack each other (but not including vehicle damage)

-----------------------------------------------------------------------------

Config.admin_groups = "admin" -- Groups that can use admin commands

Config.enableCmd = true    -- Enable/Disable all player use command (/createteam [teamname], /invite [id], /pass [id], /drop [id], /disband, /y, /n, /q)

Config.enableAdminCmd = true  -- Enable/Disable Admin use Admin command (/forcejoin [id] [team], /forcedrop [id], /forcepass [id], /forcedisband [id], /forcedisbanall)

-----------------------------------------------------------------------------

-- Key for Accept/Reject the Team Invitation
-- **If change to other key, remember to change the text of _U("accept_or_reject_invite") & _U("accept_or_reject_invite2") for the correct description
-- **Players can also use the command /y or /n to accept or reject the team invitation
Config.AcceptTeamInvitationKeybind = 188  -- ARROW UP
Config.RejectTeamInvitationKeybind = 187  -- ARROW DOWN

-- Key for Accept/Reject the Player requests to join the team's application
-- **If change to other key, remember to change the text of _U("accept_or_reject_request") & _U("accept_or_reject_request2") for the correct description
Config.AcceptRequestToJoinTeamKeybind = 188  -- ARROW UP
Config.RejectRequestToJoinTeamInvitationKeybind = 187  -- ARROW DOWN

-- Key for Accept/Reject the Player requests to Merger the team's application
-- **If change to other key, remember to change the text of _U("accept_or_reject_merge") & _U("accept_or_reject_merge2") for the correct description
Config.AcceptRequestToMergeTeamKeybind = 188  -- ARROW UP
Config.RejectRequestToMergeTeamKeybind = 187  -- ARROW DOWN

-----------------------------------------------------------------------------

-- Only Team Member Can Ride In Same Vehicle
Config.OnlyTeamMemberCanRideInSameVehicle = false -- If set to true: Only team members can ride together in the same vehicle. **That means player from other teams or without a team cannot ride in the same vehicle with player who are not on the same team or without a team.


Config.TeamTP = true  -- Enable/Disable the teammate use the TP function

Config.TpWaitingtime = 5  -- Seconds as unit, the waiting time to teleport to teammate

config.js
var Config = new Object();
    
// Available Locales: "en", "zh"
Config.Locale = "en";

Requirements:

  1. ESX (1.1 / 1.2 / legacy)
  2. mysql-async / oxmysql

Optional Requirements:

  1. mythic_notify - GitHub - JayMontana36/mythic_notify: A simple FiveM notification resource
  2. pnotify - GitHub - Nick78111/pNotify: In-game notifications for the FiveM GTA V mod
  3. 413x-notify - GitHub - sharplybond4/NotificationSystem: A simple and easy to use notification system built for FiveM Roleplay

Installation:

  • Before starting the resource, please remember to import team_sql.sql to your Database

Exports:

1. exports["teamsystem"]:OpenTeamSystemUI()  -- Open the TeamSystemMuen UI
2. exports["teamsystem"]:OpenTeamSystemAdminPanelUI()  -- Open the TeamSystemMuen_AdminPanel UI

Warning:

  1. Please make sure in any other resources to stop using SetCanAttackFriendly(PlayerPedId(), true, true) and NetworkSetFriendlyFireOption(true), otherwise the “team members cannot attack each other” function in the team will not work.

    Example: es_extended > config.lua > Config.EnablePVP 
    Set it to "false"  -- Config.EnablePVP = false
    
  2. This script is using the Asset Escrow system

Resmon:

Resmon_teamsystem

Showcase: (outdated version)

[ESX] Team System - https://www.youtube.com/watch?v=GkVFqEoCJ6Y

Purchase:

Tebex: https://captainavenger.tebex.io/package/5225900

Code is accessible No, but have customization files (config.lua, config.js, locales, all html file)
Subscription-based No
Lines (approximately) 6000
Requirements 1. ESX (1.1 / 1.2 / legacy) 2. mysql-async / oxmysql
Support Yes
3 Likes

Change-log:

version ‘1.0.1’

1. Added mysql-async, which can be set at config.lua

Using mysql-async
using mysql-async

Using oxmysql
using oxmysql

Change-log:

version ‘1.1.0’

  1. Adds two additional players to join the same team
    • Leader can invite four players to join the team

would love a config option to turn off the teleporting and to turn on friendly fire i do want them to be able to shoot eachother . also a config option to turn off the names above the head.

About the teleporting to teammates, in config.lua, it can set whether to allow players to use this feature.

No problem, I can meet your needs. Once I completed, I am look forward to you to buy it, thank you.

Change-log:

version ‘1.1.1’

  1. Added allow players can attack each other even if joined the same team

    Config.EnableTeamKill = false -- If set to true: team members can attack each other even if joined the same team ; If set to false: team members cannot attack each other (but not including vehicle damage)

  2. Added enable/disable to show the player name above the teammate’s head after player joined the same team

    -- Only work if Config.ShowTeamInfoBar set to true
    Config.ShowTeamInfoBar_Name = true  -- If false, it will not show player name above the teammate's 
    head after player joined the same team
    
  3. Added enable/disable to show the health bar above the teammate’s head after player joined the same team

    Config.ShowTeamInfoBar_healthBar = true  -- If false, it will not show health bar above the 
    teammate's head after player joined the same team
    

Recently, we strive to develop new function to provide more team members in the same team. This function does not add more players in the same team, but is the team merge with other team.

However, this function still takes time to test, but the good news for customers is that once we completed the test of this function, customers who have purchased Team System within August, 2022 will be able to get this resource for free.

This resource will be used as a token to allow the use of this function in Team System, so you need to start this resource as well. And the price will be 10 euros + Tax. Therefore, if the customer wants to use this feature, you must first purchase the Team System, and then purchase the “Merge Team” resource to allow the use of this function in Team System.

Please note: This function is not launched, but it has been completed (the current stage is under the test), and this resource needs to be charged separately.

Features:

  • Team leader allows to merge with other two teams. After the merger, the team will not change, it is still only the leader of that team can invite players to join or kick the team members out of the team.

  • All members of the team that have merged with your own team can see each other’s blips on the map (The color of blips: own teammate are green, merge team member are purple) and can’t shoot each other.

  • All members of the team that have merged with your own team can also be teleport to each other

  • The color of the team that merged with your own team on the team list will change to purple, and “Show My Team only” will also show the team that merged with your team.

  • A total of 3 teams can merge with each other, that is up to 15 players (5 players x 3 teams) can merge into the same team.

  • Team leader can cancel the merger with other teams, just press the name of your team on the team list and press “Cancel merge team” button to cancel the merger with all teams.

1 Like

Change-log:

version ‘1.2.0’

  1. bug fixes and improvements

  2. Merge team function (need to buy another resource [teamsystem_mergeteam] to enable this feature in Team System)

    Features:

    • Team leader allows to merge with other two teams. After the merger, the team will not change, it is still only the leader of that team can invite players to join or kick the team members out of the team.

    • All members of the team that have merged with your own team can see each other’s blips on the map (The color of blips: own teammate are green, merge team member are purple) and can’t shoot each other.

    • All members of the team that have merged with your own team can also be teleport to each other

    • The color of the team that merged with your own team on the team list will change to purple, and “Show My Team only” will also show the team that merged with your team.

    • A total of 3 teams can merge with each other, that is up to 15 players (5 players x 3 teams) can merge into the same team.

    • Team leader can cancel the merger with other teams, just press the name of your team on the team list and press “Cancel merge team” button to cancel the merger with all teams.

From now until August 31, 2022, customers purchase our “Team System” will be able to get the new features (Merge team function) for free.

About the “Merge team function”, the maximum 15 players are allowed to merge into one team, and the original team can only have 5 players, so this feature can break through the restrictions and merge with the other two teams. A total of 3 teams can merge with each other, that is up to 15 players (5 players x 3 teams) can merge into the same team. After the merger, the players can enjoy the original functions, such as TP to the teammates, seeing each other’s blips on the map, and can’t shoot each other.

If you have any inquiries, please contact us here or find our Discord in the purchase link and join it to watch more information, thank you.

We now provide a one-week free trial version (Team System + Merge Team Function), and only 5 people can get it. If you are interested, please find our Discord in the purchase link above and join it to understand how to get it.

The deadline is 23:59 on August 31, 2022 (UTC +8 2022-08-31 23:59), after that, we will randomly select 5 participants based on the information provided by the participants and give them a one-week free trial version (Team System + Merge Team Function)

Change-log:

version ‘1.2.2’

  1. Allow the merge team function without the need to buy extra script - about the merge team function, you can watch here: https://captainavenger.tebex.io/package/5259709

In addition, we still provide a free trial experience.

can I set the team only 2 or 3 player if I want ? and cant Merge team

In my latest version, each team can have a maximum of 5 players, but if you only want 3 players, I can provide you with my original version (only 3 players per team). As for the merger team, if you don’t want to use it, I can add it to the config whether it is allowed to use Merge Team.

Change-log:

version ‘1.2.3’

  1. Added enable/disable the players use merge team function

    Config.EnableMergeTeamFunction = true -- If false, Players cannot use the merge team function

Change-log:

version ‘1.3.0’

  1. bug fixes and improvements

  2. Added Team HUD (the default position is on the left middle side of the screen*). After joining the same team, the team members can see each other’s name, health and armour information on the Team HUD.

  3. Added UI interface (TeamSystem & TeamSystem - Admin Panel & Team HUD) can be dragged.

  4. Added UI setting [1. Allow UI draggable 2. Allow Show Team HUD 3. Allow Show TeamInfoBar (Name) 4. Allow Show TeamInfoBar (HealthBar)]

    *If you allow UI draggable (Default is enable, can set in UI setting), you can drag the Team HUD freely after opening the UI (TeamSystem or TeamSystem - Admin Panel)

Change-log:

version ‘1.3.1’

  1. Solve about using characters other than English or numbers as a team name which causes the “No Team Kill” Function will not work

Update content: If the team name is not English or numbers, the system will automatically generate another team name, but it will not affect the display team name. Therefore, the team name can be any characters, such as emoji.

1 Like