[Help]How to get vehicles informations?



Hello guys, i’m new in fiveM developping, i’m still learning LUA and i would like to do some tests…

I modified the “esx_vehicle_inventory” script to put the same inventory space in all vehicles (50 items), but now, i try to modify this script to put vehicle inventory space by vehicle categories, like :

-motorcycles -> 25 spaces in inventory
-compacts -> 40 spaces in inventory
-offroad -> 60 spaces in inventory

(i hope you understand because english is not my native language)

i had to add some columns in my sql base :
-“max_inventory” in vehicle_categories
-“vehicle_category” & “vehicle_name” in owned_vehicles

I try to modify the “esx_vehicleshop” now, i’d like to get the informations about the vehicles (name, category) to put them in my sql base when the car seller is selling a car… But i can’t find the function to get those informations (i already searched here : https://runtime.fivem.net/doc/reference.html#_n_VEHICLE)… Thank you very much.