From fef44d8694ca81a0b11b0acdd19cf88e8d53a229 Mon Sep 17 00:00:00 2001 From: LegendaryGuard Date: Mon, 18 Apr 2022 22:14:35 +0000 Subject: [PATCH] Add material and texture guide before exporting --- Exporting-a-weapon-for-Xonotic.md | 26 ++++++++++++++++++++++++-- 1 file changed, 24 insertions(+), 2 deletions(-) diff --git a/Exporting-a-weapon-for-Xonotic.md b/Exporting-a-weapon-for-Xonotic.md index b95da1a..02fce8f 100644 --- a/Exporting-a-weapon-for-Xonotic.md +++ b/Exporting-a-weapon-for-Xonotic.md @@ -70,7 +70,29 @@ Moreover, watch out about position and rotation. `h_*.iqm` alterates the positio `g_*` and `v_*` MUST contain one bone. The animations can't be included. It isn't like `h_*`. -The required animations are `fire`, `fire2`, `idle` and `reload`. +Required animations: +- `fire` +- `fire2` +- `idle` +- `reload` + +Please note that before exporting, about textures and materials, you have to assign the same as the script like this example shader file (`crylink.shader` file): +``` +crylink_new // your material/texture name +{ + dpreflectcube cubemaps/default/sky + { + map textures/crylink_new.tga // your attached texture from Blender + rgbgen lightingDiffuse + } +} +``` +Note: `crylink_new` must appear in the material and texture. +

Material:
+crylinkblendermaterialsample +

Texture:
+crylinkblendertexturesample +
# New methodology @@ -104,7 +126,7 @@ Use dpmodel tool to generate `h_myweapon.dpm` and `h_myweapon.dpm.framegroups`, Save those compiled model files into `models/weapons/` folder where they belong. -**Conclusion**: Sometimes, renaming formats can be useful to save effort. Note: it's a kind of weird way to do stuff, the issue of model resources was found here: https://gitlab.com/xonotic/xonotic-data.pk3dir/-/issues/2629#note_686988936 +**Conclusion**: Sometimes, renaming formats can be useful to save effort. Note: it's a kind of weird way to do stuff, file formats are hardcoded in the gamecode rather than dynamically obtained. The issue of model resources was found here: https://gitlab.com/xonotic/xonotic-data.pk3dir/-/issues/2629#note_686988936 If you received spamming errors like that:
spammingerrorstagweapon
-- 2.39.2