[Release] Drift Counter



it’s motorsport, i swear!

Welcome to yet another minor release of mine, this time, the car guys under you will have something to fanboy about for a few hours, because i ““converted”” the drift counter from MTA to FiveM, and while i was doing that, improved it a bit, too.

Basic Information:

car go sideways
player get points


Advanced Information:

You can also give the player money for drifting, which will be handled in the driftcounter_s.lua

in the first few lines you can enable/disable payout, along with change if you want to use the ( native ) V Money System ( used by virtually noone yet ) or use EssentialmemeMode to give your player money, this function is disabled by default ( as people will probably get confused as to why there are 2 money displays all of a sudden ).

Anyway, it’s quite unfinished and total scores dont exist ( yet ), you can write functions to add such tho, as the variable for the player score already exists.

Happy being-Sideways!

Probleme with drift counter


(Nice job :D)


Sexy! Very useful for drift servers :stuck_out_tongue:


thanks, very good idea


Biiig Thanks ! awesome drop


Error loading script driftcounter_s.lua in resource FiveM-DriftCounter-master: driftcounter_s.lua:38: attempt to concatenate a nil value (global ‘updatePath’)
stack traceback:
driftcounter_s.lua:38: in function 'checkVersionHTTPRequest’
driftcounter_s.lua:40: in main chunk
Failed to load script driftcounter_s.lua.
Started resource FiveM-DriftCounter-master


just committed a fix for that, redownload the new driftcounter_s.lua!


Thank you
problem solved


How can i add a drift scoreboard? like top drifter and things like that?


You would have to add their drift score up each time they finish a drift and then save it somewhere.


this gave me an idea :wink:

Update 1.2

Added Drift “Stat”, you can access this stat from any script by using
_,DriftScore = StatGetInt("MP0_DRIFT_SCORE",-1)
( note this does not save, you’d have to write something yourself, i might make something later with resource kvp, which will transfer the stats between all servers )

Have Fun! I’d love to see what you guys can come up with.


guys, anyone tried to add payment to vrp?


Hey look, an update!

Along with this update the method of configuring the settings has now changed as it now uses convars. To set this up correctly, head over to your cfg and add:

set DriftC_useGlobalScore "true"
set DriftC_usePayout "false"
set DriftC_useFramework "Native"
set DriftC_SaveAtEndOfDrift "true"
set DriftC_SaveTime 60000

All of these values can be modified to your liking (all the definitions of each setting and what it does is in driftcounter_s!)

Now, onto the more significant update, global scores! This feature is an opt-out feature and can be disabled by changing DriftC_useGlobalScore to “false”, however, when true
all score you recieve on one server, will now transfer seamlessly to another server, without the need of any hassle from the user or server owner (NOTE: this will only work with
servers that have it enabled, and it will save depending on their customisation).

Anyway, have fun drifting!


/dab +1 rep sick as hell


Performance update time!

This small update should improve the speed at which your player info loads in at!

Dont forget to have fun drifting!


Update time again!

This time the global score system has been fixed , and there may be an online scoreboard coming soon too!

Site is now up!:
Drift Leaderboard

Have fun drifting!


I have this error it comes from or

Error running system event handling function for resource DriftCounter: citizen: /scripting/lua/scheduler.lua: 41: Failed to execute thread: driftcounter_s.lua: 66: attempt to index a nil value (local ‘data’)

Since I start programming I try to read the code but I have not found where it can come from.

If there would be a charitable soul to help me


How to set up drift to add money to my Mysql database


Hi i became this Error on Serverstart

DriftCounter Error: Could not reach the service. Code: 404
Make sure https://services.illusivetea.me/driftcounter-storage is accessable by your server.
To prevent errors, global database will not be available.


that should be fine, it just means that drift stats will not be saved for the players.