Template folder rules, preview generation, slot YTD layout, and addon export behavior for 0r-clothing_designer
This page explains how templates are discovered and what happens when users export.
Template Discovery Rules#
Templates must be placed under:
templates/cloth_templates/
male/
female/
Supported component folders:
accsberddeclfeethairhandheadjbiblowrtaskteefuppr
Examples:
templates/cloth_templates/male/jbib/jbib_000_u.ydd
templates/cloth_templates/female/lowr/lowr_000_r.ydd
Naming Rules#
The resource derives template identity from the folder and file name.
Check these rules:
- top folder must be
maleorfemale - second folder must be a supported component key
- the file prefix should match that component key
If folder and file naming do not agree, the template can be skipped.
Optional Preview Images#
You can ship your own preview images under:
templates/template_previews/<gender>/<component>/<file>.(png|webp|jpg|jpeg)
If no preview exists, the resource can generate one during startup and mirror the generated .png into templates/template_previews.
If preview files are generated or changed while the server is already running, use:
refresh
restart 0r-clothing_designer
Optional Default Slot YTD Files#
Default slot .ytd files live under:
templates/template_slots/<template_key>/
Examples:
templates/template_slots/male_jbib_jbib_000/
templates/template_slots/female_accs_accs_000/
These files become template-specific slot options inside the editor.
Startup Sync Behavior#
On resource start the runtime can:
- create missing workspace directories
- scan all
.yddtemplates - generate missing previews
- update changed managed previews
- clean temporary preview cache files
Export Flow#
Current shipped behavior:
- the UI export flow is addon-first
- replace export is not shown in the shipped UI
- successful addon exports create both zip output and mirrored addon resource output
Output locations:
0r-clothing_designer/exports/0r-clothing_exports/0r-clothing_designer/data/workspace/
After a successful addon export, restart:
restart 0r-clothing_exports
so FiveM reloads the new addon files.