💙
Fusion Development Documentation
Join our Discord
  • Welcome
  • Products
    • Reportsystem
      • ⬇️Installation
      • ⚙️Configuration
      • ‼️Error Solutions
    • Taximeter
      • ⬇️Installation
      • ⚙️Configuration
      • ‼️Error Solutions
    • Restaurants
      • ⬇️Installation
      • ⚙️Configuration
      • ‼️Error Solutions
    • Next-Series Banking
      • ⬇️Installation
      • ⚙️Configuration
      • ‼️Error Solutions
    • Hoodbell - Fraktionsklingel
      • ⬇️Installation
      • ⚙️Configuration
      • ‼️Error Solutions
    • Vehicleshop
      • ⬇️Installation
      • ⚙️Configuration
      • ‼️Error Solutions
    • Next-Series Shop
      • ⬇️Installation
      • ⚙️Configuration
      • ‼️Error Solutions
    • Next-Series Gangwar
      • ⬇️Installation
      • ⚙️Configuration
      • ‼️Error Solutions
    • Lootdrop
      • ⬇️Installation
      • ⚙️Configuration
      • ‼️Error Solutions
    • Pausemenu
      • ⬇️Installation
      • ⚙️Configuration
      • ‼️Error Solutions
Powered by GitBook
On this page
  • SQL
  • Explanations (How does the script work)
  • Exports
  • Serverside
  • Clientside
  1. Products
  2. Next-Series Gangwar

Configuration

Config = {}

Config.useExport = true
Config.es_extendedName = 'es_extended'

Config.ServerNotify = function(src, title, message)
    TriggerClientEvent('esx:showNotification', src, message)
end

Config.Announce = function(src, title, message)
    TriggerClientEvent('esx:showNotification', src, message)
end

Config.ClientNotify = function(title, message)
    TriggerEvent('esx:showNotification', message)
end

Config.HelpNotify = function(msg)
    ESX.ShowHelpNotification(msg)
end

Config.Settings = {
    enableVehicles = true,
    reviveTrigger = 'esx_ambulancejob:revive',
    minMembersToJoin = 0,
    blacklistedJobs = {
        'police',
    },
    minGradeForRegistering = 1,
    joinMarkerBubbleSize = 8.0,
    gangwarTime = 1, -- minutes
    gangwarTimes = {
        [1] = "19:18",
        [2] = "21:25",
        [3] = "21:30",
        [4] = "21:34",
    },
    adminGroups = {
        'superadmin',
        'admin',
    },
    Marker = {
        type = 7,
        r = 255,
        g = 0,
        b = 0,
    },
    weapons = {
        'weapon_pistol',
        "weapon_pistol_mk2",
        "weapon_pistol50"
    }
}

Config.Gangs = {
    ['glace'] = {
        label = 'Glace',
        registerPoint = vector3(862.9179, -900.3372, 25.6030),
        vehicles = {
            [1] = {
                spawnName = 'vstr',
                label = 'vstr',
                spawnPoint = vector4(812.4531, -919.3364, 25.2713, 87.627),
            },
            [2] = {
                spawnName = 'vstr',
                label = 'vstr',
                spawnPoint = vector4(812.3520, -916.5293, 25.0387, 89.1299),
            },
            [3] = {
                spawnName = 'vstr',
                label = 'vstr',
                spawnPoint = vector4(818.5108, -919.5190, 25.2912, 87.9894),
            },
            [4] = {
                spawnName = 'vstr',
                label = 'vstr',
                spawnPoint = vector4(818.3881, -916.5264, 25.0386, 89.4397),
            },
        }
    },
    ['lcn'] = {
        label = 'LCN',
        registerPoint = vector3(-1526.3662, 91.0988, 56.5481),
        vehicles = {
            [1] = {
                spawnName = 'vstr',
                label = 'vstr',
                spawnPoint = vector4(-1510.0825, 83.6345, 55.1330, 276.2617),
            },
            [2] = {
                spawnName = 'vstr',
                label = 'vstr',
                spawnPoint = vector4(-1510.0382, 87.1264, 55.1028, 269.2946),
            },
            [3] = {
                spawnName = 'vstr',
                label = 'vstr',
                spawnPoint = vector4(-1503.9648, 84.3002, 54.7996, 275.0154),
            },
            [4] = {
                spawnName = 'vstr',
                label = 'vstr',
                spawnPoint = vector4(-1504.0154, 87.1358, 54.8102, 272.1854),
            },
        }
    },
    ['mg13'] = {
        label = 'MG13',
        registerPoint = vector3(1284.4548, -1597.7415, 54.2252),
        vehicles = {
            [1] = {
                spawnName = 'vstr',
                label = 'vstr',
                spawnPoint = vector4(1287.7224, -1575.6641, 50.9962, 301.0830),
            },
            [2] = {
                spawnName = 'vstr',
                label = 'vstr',
                spawnPoint = vector4(1289.9528, -1579.9907, 51.3948, 303.3617),
            },
            [3] = {
                spawnName = 'vstr',
                label = 'vstr',
                spawnPoint = vector4(1280.8898, -1580.8129, 51.8033, 302.2808),
            },
            [4] = {
                spawnName = 'vstr',
                label = 'vstr',
                spawnPoint = vector4(1283.2799, -1584.5063, 51.7386, 301.1986),
            },
        }
    },
    ['vagos'] = {
        label = 'Vagos',
        registerPoint = vector3(-1123.5662, -1607.6993, 4.3984),
        vehicles = {
            [1] = {
                spawnName = 'vstr',
                label = 'vstr',
                spawnPoint = vector4(-1134.8267, -1574.1094, 4.3568, 296.4026),
            },
            [2] = {
                spawnName = 'vstr',
                label = 'vstr',
                spawnPoint = vector4(-1131.2435, -1577.4817, 4.3897, 306.5764),
            },
            [3] = {
                spawnName = 'vstr',
                label = 'vstr',
                spawnPoint = vector4(-1140.3121, -1578.8495, 4.3883, 303.8128),
            },
            [4] = {
                spawnName = 'vstr',
                label = 'vstr',
                spawnPoint = vector4(-1138.0314, -1582.4027, 4.3909, 314.2849),
            },
        }
    },
    ['ballas'] = {
        label = 'Ballas',
        registerPoint = vector3(112.3152, -1946.6672, 20.7046),
        vehicles = {
            [1] = {
                spawnName = 'vstr',
                label = 'vstr',
                spawnPoint = vector4(104.4770, -1943.2861, 20.8037, 51.4955),
            },
            [2] = {
                spawnName = 'vstr',
                label = 'vstr',
                spawnPoint = vector4(107.2260, -1939.3883, 20.8037, 49.1331),
            },
            [3] = {
                spawnName = 'vstr',
                label = 'vstr',
                spawnPoint = vector4(98.9134, -1937.5535, 20.8037, 48.9812),
            },
            [4] = {
                spawnName = 'vstr',
                label = 'vstr',
                spawnPoint = vector4(100.2195, -1932.9260, 20.8037, 37.8517),
            },
        }
    },
}

Config.Locales = {
    notAllowedToRegisterGang = 'Du bist nicht berechtigt, deine Gang für den Gangwar anzumelden.',
    gangAlreadyRegistered = 'Deine Gang ist bereits für den Gangwar angemeldet.',
    gangSuccessfullyRegistered = 'Deine Gang wurde erfolgreich für den Gangwar angemeldet.',
    gangwarStarted = 'Der Gangwar hat begonnen! Ihr fightet gegen %s',
    gangwarEndWin = 'Der Gangwar ist vorbei! Ihr habt gewonnen gegen %s',
    gangwarEndLose = 'Der Gangwar ist vorbei! Ihr habt verloren gegen %s',
    pressEToRegister = 'Drücke ~INPUT_CONTEXT~ um deine Gang für den Gangwar anzumelden.',
}

Config.BanTrigger = function(src, reason)
    -- Do something when a player try to ring many times with a cheat (executor)
    TriggerEvent("EasyAdmin:BanPlayer", src, reason)
end

SQL

CREATE TABLE `gangwarstats` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `job` varchar(255) DEFAULT NULL,
  `wins` int(11) DEFAULT NULL,
  `losses` int(11) DEFAULT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8;

-- EXAMPLE CODE: YOU NEED TO DO THIS FOR ALL YOUR GANGS!
INSERT INTO `gangwarstats` (`id`, `job`, `wins`, `losses`) VALUES (1, 'police', 0, 0);

Explanations (How does the script work)

A job-member can register his gang/job for a gangwar. Not every players needs to do this, it's synced so one player is enough. After registering, around the marker is a bigger circle, where all job-members need to stay at the Config.Settings.gangwarTimes . Only these players get teleported in the Gangwar-Dimension and are official registered as a Gangwar player. Now your gangs can enter the spawned vehicles and drive together to the fight. There is no gangwar sphere, it's a streetfight gangwar. We suggest you to make rules on your server where the gangs should fight to have the best games and fights. If a player dies, he get's revived at the registerpoint. This system is like last-man-standing so the gang who kills first all of the enemies wins.

Exports

Serverside

exports['fd_next_gangwar']:isPlayerInGW(source, job)
-> the source parameter needs to be a number (the players id)
-> the job parameter needs to be a string (get the players job first)
-> returns boolean value
exports['fd_next_gangwar']:isJobInGW("police")
-> the job parameter needs to be a string
-> returns boolean value

Clientside

exports['fd_next_gangwar']:isInGangwar()
-> returns boolean value
PreviousInstallationNextError Solutions

Last updated 2 months ago

If you have any configuration questions or errors, feel free to open a ticket on our !

⚙️
Discord