[Release] Advanced nitro system

Advanced nitro system for FiveM

After many people already found the resource on my GitLab repository, it’s finally time I release the resource on the forums. This is an advanced nitro system for FiveM, inspired by the Need for Speed: Underground series. Works out of the box, no configuration is required.

Features

  • Torque-based speed modifier
  • Exhaust particles
  • NOS purge
  • Light trails
  • Screen effects
  • Fully synced
  • Controller support

In a future update, the resource will export an API to customize the controls, power modifier, purge color/positions and more. Nitro fuel will also be enabled.

Controls

  • Keyboard: Hold INPUT_CHARACTER_WHEEL (Default: left ALT)
  • Gamepad: Hold INPUT_VEH_DUCK (Default: A on Xbox, X on DualShock)

Download

Demo




Special thanks to @Xinerki for light trails code & showcase video!

39 Likes

Holy hot damn I think I just died inside. This looks amazing, adding it into my test server later today. Good job brother!

1 Like

um WOW!

1 Like

Wow. Im really want a version of this as a drop in upgrade system for cars with an item like NOS tank or something like that. That will be very cool on RP servers

This is awesome! Been waiting for something like this for a while! Nice work

Hmm, looks dope.
i have a q, how it works, like u need to put in db item , and then buy them, and install them, or it works somethink different?

can some one explain me…? :thinking:

its looks like all the vehicles have nitro already activated on spawn, it would be better if it was an item and call a function check on db to check if an owned car have installed a nitro modification

1 Like

following

Suku nitro did this kind of. You had to install it on the engine before it was installed on the car.

I’m assuming this one gives all cars with turbo nitro.

hey, this did not work for me and i dont have any errors what can it be then?

Thx im look after it.

Correct! I’m actually working on an exported API that lets you add/remove nitro as an upgrade on your car, as well as different customization options (e.g., enable/disable light trails, purge colors and position). So keep an eye out for that, as it’ll provide what you need :slight_smile:

3 Likes

@Deltanic
Thanks for the great script.

Question:
I am not sure if the script is Legacy Fuel Compatible but it’s great otherwise. If it’s possible to integrate it to legacy please give some tips.

Also:
I did a little something that i think might help others.

Added All The Classes as individual cars that should be excluded under Utils.lua since i do not think some classes have NOS. Anyone who likes it can use it with your permission of course.

Excluded Classes:
SERVICE, VANS, SEDANS, SUVS, OFFROAD, INDUSTRIAL, COMPACTS, COMMERCIAL

local ELECTRIC_VEHICLES = {
  --ELECTRIC
  [GetHashKey('AIRTUG')] = true,
  [GetHashKey('CYCLONE')] = true,
  [GetHashKey('CADDY')] = true,
  [GetHashKey('CADDY2')] = true,
  [GetHashKey('CADDY3')] = true,
  [GetHashKey('DILETTANTE')] = true,
  [GetHashKey('IMORGON')] = true,
  [GetHashKey('KHAMEL')] = true,
  [GetHashKey('NEON')] = true,
  [GetHashKey('RAIDEN')] = true,
  [GetHashKey('SURGE')] = true,
  [GetHashKey('VOLTIC')] = true,
  [GetHashKey('TEZERACT')] = true,
  --SERVICE
  [GetHashKey('AIRBUS')] = true,
  [GetHashKey('BRICKADE')] = true,
  [GetHashKey('BUS')] = true,
  [GetHashKey('COACH')] = true,
  [GetHashKey('PBUS2')] = true,
  [GetHashKey('RALLYTRUCK')] = true,
  [GetHashKey('RENTALBUS')] = true,
  [GetHashKey('TAXI')] = true,
  [GetHashKey('TOURBUS')] = true,
  [GetHashKey('TRASH')] = true,
  [GetHashKey('TRASH2')] = true,
  [GetHashKey('WASTELANDER')] = true,
  --VANS
  [GetHashKey('BISON')] = true,
  [GetHashKey('BISON2')] = true,
  [GetHashKey('BISON3')] = true,
  [GetHashKey('BOBCATXL')] = true,
  [GetHashKey('BOXVILLE')] = true,
  [GetHashKey('BOXVILLE2')] = true,
  [GetHashKey('BOXVILLE3')] = true,
  [GetHashKey('BOXVILLE4')] = true,
  [GetHashKey('BOXVILLE5')] = true,
  [GetHashKey('BURRITO')] = true,
  [GetHashKey('BURRITO2')] = true,
  [GetHashKey('BURRITO3')] = true,
  [GetHashKey('BURRITO4')] = true,
  [GetHashKey('BURRITO5')] = true,
  [GetHashKey('CAMPER')] = true,
  [GetHashKey('GBURRITO')] = true,
  [GetHashKey('GBURRITO2')] = true,
  [GetHashKey('JOURNEY')] = true,
  [GetHashKey('MINIVAN')] = true,
  [GetHashKey('MINIVAN2')] = true,
  [GetHashKey('PARADISE')] = true,
  [GetHashKey('PONY')] = true,
  [GetHashKey('PONY2')] = true,
  [GetHashKey('RUMPO')] = true,
  [GetHashKey('RUMPO2')] = true,
  [GetHashKey('RUMPO3')] = true,
  [GetHashKey('SPEEDO')] = true,
  [GetHashKey('SPEEDO2')] = true,
  [GetHashKey('SPEEDO4')] = true,
  [GetHashKey('SURFER')] = true,
  [GetHashKey('SURFER2')] = true,
  [GetHashKey('TACO')] = true,
  [GetHashKey('YOUGA')] = true,
  [GetHashKey('YOUGA2')] = true,
  [GetHashKey('YOUGA2')] = true,
  [GetHashKey('AIRTUG')] = true,
  [GetHashKey('CADDY')] = true,
  [GetHashKey('CADDY2')] = true,
  [GetHashKey('CADDY3')] = true,
  [GetHashKey('DOCKTUG')] = true,
  [GetHashKey('FORKLIFT')] = true,
  [GetHashKey('MOWER')] = true,
  [GetHashKey('RIPLEY')] = true,
  [GetHashKey('SADLER')] = true,
  [GetHashKey('SADLER2')] = true,
  [GetHashKey('SCRAP')] = true,
  [GetHashKey('TOWTRUCK')] = true,
  [GetHashKey('TOWTRUCK2')] = true,
  [GetHashKey('TRACTOR')] = true,
  [GetHashKey('TRACTOR2')] = true,
  [GetHashKey('TRACTOR3')] = true,
  [GetHashKey('UTILLITRUCK')] = true,
  [GetHashKey('UTILLITRUCK2')] = true,
  [GetHashKey('UTILLITRUCK3')] = true,
  --SEDANS
  [GetHashKey('ASEA')] = true,
  [GetHashKey('ASEA2')] = true,
  [GetHashKey('ASTEROPE')] = true,
  [GetHashKey('COG55')] = true,
  [GetHashKey('COG552')] = true,
  [GetHashKey('COGNOSCENTI')] = true,
  [GetHashKey('COGNOSCENTI2')] = true,
  [GetHashKey('EMPEROR')] = true,
  [GetHashKey('EMPEROR2')] = true,
  [GetHashKey('EMPEROR3')] = true,
  [GetHashKey('FUGITIVE')] = true,
  [GetHashKey('GLENDALE')] = true,
  [GetHashKey('INGOT')] = true,
  [GetHashKey('INTRUDER')] = true,
  [GetHashKey('LIMO2')] = true,
  [GetHashKey('PREMIER')] = true,
  [GetHashKey('PRIMO')] = true,
  [GetHashKey('PRIMO2')] = true,
  [GetHashKey('REGINA')] = true,
  [GetHashKey('ROMERO')] = true,
  [GetHashKey('STAFFORD')] = true,
  [GetHashKey('STANIER')] = true,
  [GetHashKey('STRATUM')] = true,
  [GetHashKey('STRETCH')] = true,
  [GetHashKey('SUPERD')] = true,
  [GetHashKey('SURGE')] = true,
  [GetHashKey('TAILGATER')] = true,
  [GetHashKey('WARRENER')] = true,
  [GetHashKey('WASHINGTON')] = true,
  --SUVS
  [GetHashKey('BALLER')] = true,
  [GetHashKey('BALLER2')] = true,
  [GetHashKey('BALLER3')] = true,
  [GetHashKey('BALLER4')] = true,
  [GetHashKey('BALLER5')] = true,
  [GetHashKey('BALLER6')] = true,
  [GetHashKey('BJXL')] = true,
  [GetHashKey('CAVALCADE')] = true,
  [GetHashKey('CAVALCADE2')] = true,
  [GetHashKey('CONTENDER')] = true,
  [GetHashKey('DUBSTA')] = true,
  [GetHashKey('DUBSTA2')] = true,
  [GetHashKey('FQ2')] = true,
  [GetHashKey('GRANGER')] = true,
  [GetHashKey('GRESLEY')] = true,
  [GetHashKey('HABANERO')] = true,
  [GetHashKey('HUNTLEY')] = true,
  [GetHashKey('LANDSTALKER')] = true,
  [GetHashKey('MESA')] = true,
  [GetHashKey('MESA2')] = true,
  [GetHashKey('NOVAK')] = true,
  [GetHashKey('PATRIOT')] = true,
  [GetHashKey('PATRIOT2')] = true,
  [GetHashKey('RADI')] = true,
  [GetHashKey('REBLA')] = true,
  [GetHashKey('ROCOTO')] = true,
  [GetHashKey('SEMINOLE')] = true,
  [GetHashKey('SERRANO')] = true,
  [GetHashKey('TOROS')] = true,
  [GetHashKey('XLS')] = true,
  [GetHashKey('XLS2')] = true,
  --OFFROAD
  [GetHashKey('BFINJECTION')] = true,
  [GetHashKey('BIFTA')] = true,
  [GetHashKey('BLAZER')] = true,
  [GetHashKey('BLAZER2')] = true,
  [GetHashKey('BLAZER3')] = true,
  [GetHashKey('BLAZER4')] = true,
  [GetHashKey('BLAZER5')] = true,
  [GetHashKey('BODHI2')] = true,
  [GetHashKey('BRAWLER')] = true,
  [GetHashKey('BRUISER')] = true,
  [GetHashKey('BRUISER2')] = true,
  [GetHashKey('BRUISER3')] = true,
  [GetHashKey('BRUTUS')] = true,
  [GetHashKey('BRUTUS2')] = true,
  [GetHashKey('BRUTUS3')] = true,
  [GetHashKey('CARACARA')] = true,
  [GetHashKey('CARACARA2')] = true,
  [GetHashKey('DLOADER')] = true,
  [GetHashKey('DUBSTA3')] = true,
  [GetHashKey('DUNE')] = true,
  [GetHashKey('DUNE2')] = true,
  [GetHashKey('DUNE3')] = true,
  [GetHashKey('DUNE4')] = true,
  [GetHashKey('DUNE5')] = true,
  [GetHashKey('EVERON')] = true,
  [GetHashKey('FREECRAWLER')] = true,
  [GetHashKey('HELLION')] = true,
  [GetHashKey('INSURGENT')] = true,
  [GetHashKey('INSURGENT2')] = true,
  [GetHashKey('INSURGENT3')] = true,
  [GetHashKey('KALAHARI')] = true,
  [GetHashKey('KAMACHO')] = true,
  [GetHashKey('MARSHALL')] = true,
  [GetHashKey('MESA3')] = true,
  [GetHashKey('MONSTER')] = true,
  [GetHashKey('MONSTER3')] = true,
  [GetHashKey('MONSTER4')] = true,
  [GetHashKey('MONSTER5')] = true,
  [GetHashKey('MENACER')] = true,
  [GetHashKey('OUTLAW')] = true,
  [GetHashKey('NIGHTSHARK')] = true,
  [GetHashKey('RANCHERXL')] = true,
  [GetHashKey('RANCHERXL2')] = true,
  [GetHashKey('REBEL')] = true,
  [GetHashKey('REBEL2')] = true,
  [GetHashKey('RCBANDITO')] = true,
  [GetHashKey('RIATA')] = true,
  [GetHashKey('SANDKING')] = true,
  [GetHashKey('SANDKING2')] = true,
  [GetHashKey('TECHNICAL')] = true,
  [GetHashKey('TECHNICAL2')] = true,
  [GetHashKey('TECHNICAL3')] = true,
  [GetHashKey('TROPHYTRUCK')] = true,
  [GetHashKey('TROPHYTRUCK2')] = true,
  [GetHashKey('VAGRANT')] = true,
  [GetHashKey('ZHABA')] = true,
  --INDUSTRIAL
  [GetHashKey('BULLDOZER')] = true,
  [GetHashKey('CUTTER')] = true,
  [GetHashKey('DUMP')] = true,
  [GetHashKey('FLATBED')] = true,
  [GetHashKey('GUARDIAN')] = true,
  [GetHashKey('HANDLER')] = true,
  [GetHashKey('MIXER')] = true,
  [GetHashKey('MIXER2')] = true,
  [GetHashKey('RUBBLE')] = true,
  [GetHashKey('TIPTRUCK')] = true,
  [GetHashKey('TIPTRUCK2')] = true,
  --COMPACTS
  [GetHashKey('ASBO')] = true,
  [GetHashKey('BLISTA')] = true,
  [GetHashKey('BRIOSO')] = true,
  [GetHashKey('DILETTANTE')] = true,
  [GetHashKey('DILETTANTE2')] = true,
  [GetHashKey('KANJO')] = true,
  [GetHashKey('ISSI2')] = true,
  [GetHashKey('ISSI3')] = true,
  [GetHashKey('ISSI4')] = true,
  [GetHashKey('ISSI5')] = true,
  [GetHashKey('ISSI6')] = true,
  [GetHashKey('PANTO')] = true,
  [GetHashKey('PRAIRIE')] = true,
  [GetHashKey('RHAPSODY')] = true,
  --COMMERCIALS
  [GetHashKey('BENSON')] = true,
  [GetHashKey('BIFF')] = true,
  [GetHashKey('CERBERUS')] = true,
  [GetHashKey('CERBERUS2')] = true,
  [GetHashKey('CERBERUS3')] = true,
  [GetHashKey('HAULER')] = true,
  [GetHashKey('HAULER2')] = true,
  [GetHashKey('MULE')] = true,
  [GetHashKey('MULE2')] = true,
  [GetHashKey('MULE3')] = true,
  [GetHashKey('MULE4')] = true,
  [GetHashKey('PACKER')] = true,
  [GetHashKey('PHANTOM')] = true,
  [GetHashKey('PHANTOM2')] = true,
  [GetHashKey('PHANTOM3')] = true,
  [GetHashKey('POUNDER')] = true,
  [GetHashKey('POUNDER2')] = true,
  [GetHashKey('STOCKADE')] = true,
  [GetHashKey('STOCKADE3')] = true,
  [GetHashKey('TERBYTE')] = true
}


-- TODO: Replace with `FLAG_IS_ELECTRIC` from vehicles.meta:
-- https://gtamods.com/wiki/Vehicles.meta
function IsVehicleElectric(vehicle)
  local model = GetEntityModel(vehicle)
  return ELECTRIC_VEHICLES[model] or false
end

4 Likes

@Deltanic it will be a part of the ls_customs job or can it be added as a purchasable item eventually?

This is gonna be great when the fuel system for nitro starts working but until then its wayyyy too OP as people can just nitro forever

1 Like

Oh so it’s not depleting the Nitro now and it will

Seems like it…

1 Like

I go over the code could not see any indication of native fuel so that might be right…
@Deltanic can clarify

Excited for this, would love to see it as a item that can be used and it install a NOS tank into the car with limited fuel / usage. Love the purge the most :stuck_out_tongue:

This will be scriptable in the next release :slight_smile: Electric vehicles physically can’t have nitro, which is why they are in the current exclusion list. In the next release, there will be an API to add/remove nitro from any given car, so you can add your own exclusion list.

This will be possible with the next release! It will be compatible with any other resource, including ls_customs.

I agree. Fuel code is is in the resource, but currently disabled as it wasn’t quite production-ready. Will be enabled in the next release again.

1 Like