Skip to content

Coffeelot/cw-performance

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

35 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

cw-performance 🏎

⭐ Check out our Tebex store for some cheap scripts ⭐

Recommended companion script: cw-mechtool

Simple little script to add ratings to cars depending on performance scores. The scoring checks acceleration, speed, handling, braking. Takes drivetrain into account.

The script itself is small and only contains the functionality to score vehicles and not any fancy way to display it. Motorcycles have NOT been tested with. Mainly used for cars.

Note: As of May 5th 2024 CW performance is core agnostic and does not need QBcore anymore.

Preview 📽

YOUTUBE VIDEO

Links

⭐ Check out our Tebex store for some cheap scripts ⭐

Support, updates and script previews:

If you want to support what we do, you can buy us a coffee here:

Buy Us a Coffee

Config 🔧

Debug: Activate debug output (this will print all scores in console). Default istrue
UseCommand: Allow the /checkscore command. Default is true
Balance: These values are the balance in the final scoring. If you feel like something matters to much or to little you can play with these.\

Implementations

Basic use

If you want to use the script you can add this line to get the scores, class brand and rating from anywhere: local info, class, perfRating = exports['cw-performance']:getVehicleInfo(GetVehiclePedIsIn(PlayerPedId())) You can then use the info.x to get any specific score (info.accel for acceleration for example), class for the letter-class (A-F), brand for the brand of the car,

You can find example uses in cw-racingapp and cw-mechtool

Add to QB-racing 🚗

Basic (just showing class): In qb-racing/client/main.lua find the NetEvent called "qb-racing:Client:OpenMainMenu" and add this to the top local info, class, perfRating = exports['cw-performance']:getVehicleInfo(GetPlayersLastVehicle()) then add this to the header options (before isHeadermenu = tue) txt = 'You are currently in an ' .. class .. perfRating.. " class car",

Should look something like this:

Image

If you want a more advanced version, join the discord and check there is a download link for our version of qb-racing which includes class-based racing and restrictions.

Add app 📱

If you want to add the phone app, check the PHONE.md in the implementations folder.