Asset Streaming (Cars, Maps)
FiveM allows you to stream custom assets (models, textures, data files) from the server to the client automatically. This feature is what allows servers to have custom cars, clothes, weapons, and maps.
Resource Structure
To stream assets, you need a standard resource structure with a stream folder.
my-car-pack/
├── fxmanifest.lua # Resource manifest
├── stream/ # ALL assets go here (yft, ytd, ydr, ymap)
│ ├── adder.yft
│ ├── adder.ytd
│ └── ...
├── data/ # Optional: data files (handling.meta, vehicles.meta)
│ ├── handling.meta
│ └── vehicles.meta
└── client.lua # Optional: scriptsThe stream Folder
Any file placed inside the stream/ folder is automatically scanned by FiveM.
- No definition needed: You do NOT need to list files inside
stream/in yourfxmanifest.lua. - Automatic loading: FiveM detects the file type (texture, model, map) based on the extension (
.ytd,.yft,.ymap) and loads it.
FiveM for GTA V Enhanced: when a resource contains a stream_enhanced/
folder, Enhanced loads it instead of stream/. Without it, stream/ still
works on Enhanced but is deprecated. Keep Gen8 assets in stream/ and
Gen9-converted assets in stream_enhanced/ to ship one resource for both
platforms. See Legacy vs Enhanced and
Enhanced migration.
Streaming Vehicles
To add a custom vehicle, you typically need the model files and the data configuration files.
- Models: Put
.yft(model) and.ytd(texture) files in thestream/folder. - Data: Put
handling.meta,vehicles.meta, andcarcols.metain adata/folder (organization preference). - Manifest: You MUST tell FiveM about the data files in
fxmanifest.lua.
fxmanifest.lua for Vehicles
fx_version 'cerulean'
game 'gta5'
-- List the data files
files {
'data/vehicles.meta',
'data/carcols.meta',
'data/handling.meta',
}
-- Tell the game to load them as specific data types
data_file 'HANDLING_FILE' 'data/handling.meta'
data_file 'VEHICLE_METADATA_FILE' 'data/vehicles.meta'
data_file 'CARCOLS_FILE' 'data/carcols.meta'Streaming Maps (MLO/YMAP)
Streaming maps is even easier.
- Create a resource folder (e.g.,
custom_map). - Create a
stream/folder inside it. - Drop your
.ymap(map placement) and.ydr/.ytyp(models/definitions) files intostream/. - Create a basic
fxmanifest.lua.
fxmanifest.lua for Maps
fx_version 'cerulean'
game 'gta5'
this_is_a_map 'yes'this_is_a_map 'yes' marks the resource as a GTA map so the map storage is
reloaded when the resource loads. Use it for resources that ship .ymap
placements.
Streaming Clothing (EUP)
Add-on clothing needs more than streamed drawables. The drawables (.ydd) and
textures (.ytd) go in stream/, together with the collection’s .ymt, and
the shop metadata that registers the collection must be mounted as a data file:
files { 'mp_m_freemode_01_mycollection.meta' }
data_file 'SHOP_PED_APPAREL_META_FILE' 'mp_m_freemode_01_mycollection.meta'The file and collection names must match what your clothing tool generated. Select add-on drawables at runtime with the collection-based natives rather than hard-coded global drawable indices, which shift when other packs load.
Optimization Tips
1. Read FXServer’s oversized-asset warnings
When a resource starts, FXServer checks every streamed resource file’s physical and virtual memory size (not its size on disk) and prints:
Asset my-car-pack/adder.yft uses 22.4 MiB of physical memory.Warnings start above 16 MiB and escalate above 32 MiB and 64 MiB. Above 48 MiB the message adds “Oversized assets can and WILL lead to streaming issues (such as models not loading/rendering)”. Treat any warning as the signal to reduce texture resolution, compress textures or split the asset; there is no fixed size at which a client is guaranteed to crash.
2. Textures and geometry
- Compress textures and drop alpha channels you do not use. High-resolution
textures are the most common cause of oversized
.ytdfiles. - Provide LOD models so the full-detail mesh only renders up close. See collision and LOD diagnosis.
- Measure on a low-VRAM client instead of trusting a polygon budget; see asset performance.
3. Resource Splitting
- Group assets logically (
police-fleet,civ-cars-pack1,custom-map-legion) so you can update, restart or remove one set without touching the others.
Common Data File Types
| File | Directive in fxmanifest | Purpose |
|---|---|---|
handling.meta | HANDLING_FILE | Vehicle physics, speed, turning. |
vehicles.meta | VEHICLE_METADATA_FILE | Vehicle models, audio, textures. |
carcols.meta | CARCOLS_FILE | Siren lights, mod kit IDs. |
carvariations.meta | VEHICLE_VARIATION_FILE | Vehicle paint jobs, spawning rules. |
weapons.meta | WEAPONINFO_FILE | Weapon definitions. |
weaponarchetypes.meta | WEAPON_METADATA_FILE | Weapon model archetypes. |
mp_m_freemode_01_*.meta | SHOP_PED_APPAREL_META_FILE | Add-on clothing collections. |
The complete list of mount types is in the data file reference.