Import a 3D Model and automatically assign and export animations
TypeScript
made naming more consistency for fox
Scott Petrovic8b0f000fec6d
diff --git a/src/lib/RigConfig.ts b/src/lib/RigConfig.tsindex b245770..708f807 100644--- a/src/lib/RigConfig.ts+++ b/src/lib/RigConfig.ts@@ -7,10 +7,8 @@ export interface RigConfigEntry {skeleton_type: SkeletonType// Model file path relative to the static root, e.g. 'models/model-human.glb'model_file: string- // Display name shown in the model dropdown, e.g. 'Human', 'Fox'- model_display_name: string- // Display name shown in the skeleton-type dropdown, e.g. 'Human', '4 Leg Creature'- skeleton_display_name: string+ // Display name shown in both the model and skeleton dropdowns+ rig_display_name: string// Animation filenames (no base path) loaded for this rig typeanimation_files: string[]// Sub-folder name used when referencing animation preview thumbnails@@ -35,8 +33,7 @@ export class RigConfig {key: 'human',skeleton_type: SkeletonType.Human,model_file: 'models/model-human.glb',- model_display_name: 'Human',- skeleton_display_name: 'Human',+ rig_display_name: 'Human',animation_files: ['human-base-animations.glb', 'human-addon-animations.glb'],animation_preview_folder: 'human',has_hand_options: true,@@ -47,10 +44,9 @@ export class RigConfig {key: 'quadraped',skeleton_type: SkeletonType.Quadraped,model_file: 'models/model-fox.glb',- model_display_name: 'Fox',- skeleton_display_name: '4 Leg Creature',- animation_files: ['quad-creature-animations.glb'],- animation_preview_folder: 'four-legged',+ rig_display_name: 'Fox',+ animation_files: ['fox-animations.glb'],+ animation_preview_folder: 'fox',has_hand_options: false,has_head_weight_correction: false,has_a_pose_correction: false@@ -59,8 +55,7 @@ export class RigConfig {key: 'bird',skeleton_type: SkeletonType.Bird,model_file: 'models/model-bird.glb',- model_display_name: 'Bird',- skeleton_display_name: 'Bird',+ rig_display_name: 'Bird',animation_files: ['bird-animations.glb'],animation_preview_folder: 'bird',has_hand_options: false,@@ -71,8 +66,7 @@ export class RigConfig {key: 'dragon',skeleton_type: SkeletonType.Dragon,model_file: 'models/model-dragon.glb',- model_display_name: 'Dragon',- skeleton_display_name: 'Dragon',+ rig_display_name: 'Dragon',animation_files: ['dragon-animations.glb'],animation_preview_folder: 'dragon',has_hand_options: false,@@ -83,8 +77,7 @@ export class RigConfig {key: 'kaiju',skeleton_type: SkeletonType.Kaiju,model_file: 'models/model-kaiju.glb',- model_display_name: 'Kaiju',- skeleton_display_name: 'Kaiju',+ rig_display_name: 'Kaiju',animation_files: ['kaiju-animations.glb'],animation_preview_folder: 'kaiju',has_hand_options: false,@@ -112,7 +105,7 @@ export class RigConfig {for (const rig of this.all) {const option = document.createElement('option')option.value = rig.model_file- option.textContent = rig.model_display_name+ option.textContent = rig.rig_display_nameselect.appendChild(option)}}@@ -133,7 +126,7 @@ export class RigConfig {for (const rig of this.all) {const option = document.createElement('option')option.value = rig.key- option.textContent = rig.skeleton_display_name+ option.textContent = rig.rig_display_nameselect.appendChild(option)}}diff --git a/src/preview-generator/index.html b/src/preview-generator/index.htmlindex c870f63..a8564ca 100644--- a/src/preview-generator/index.html+++ b/src/preview-generator/index.html@@ -17,7 +17,7 @@<option>Pick a 3d animation to generate previews</option><option value="../animations/human-base-animations.glb">Human Base Animations</option><option value="../animations/human-addon-animations.glb">Human Addon Animations</option>- <option value="../animations/quad-creature-animations.glb">Quad Creature Animations</option>+ <option value="../animations/fox-animations.glb">Fox Animations</option><option value="../animations/bird-animations.glb">Bird Animations</option><option value="../animations/dragon-animations.glb">Dragon Animations</option><option value="../animations/kaiju-animations.glb">Kaiju Animations</option>diff --git a/static/animations/quad-creature-animations.glb b/static/animations/fox-animations.glbsimilarity index 100%rename from static/animations/quad-creature-animations.glbrename to static/animations/fox-animations.glbdiff --git a/static/animpreviews/four-legged/dark_Bark.webm b/static/animpreviews/fox/dark_Bark.webmsimilarity index 100%rename from static/animpreviews/four-legged/dark_Bark.webmrename to static/animpreviews/fox/dark_Bark.webmdiff --git a/static/animpreviews/four-legged/dark_Bite.webm b/static/animpreviews/fox/dark_Bite.webmsimilarity index 100%rename from static/animpreviews/four-legged/dark_Bite.webmrename to static/animpreviews/fox/dark_Bite.webmdiff --git a/static/animpreviews/four-legged/dark_Death.webm b/static/animpreviews/fox/dark_Death.webmsimilarity index 100%rename from static/animpreviews/four-legged/dark_Death.webmrename to static/animpreviews/fox/dark_Death.webmdiff --git a/static/animpreviews/four-legged/dark_Fall.webm b/static/animpreviews/fox/dark_Fall.webmsimilarity index 100%rename from static/animpreviews/four-legged/dark_Fall.webmrename to static/animpreviews/fox/dark_Fall.webmdiff --git a/static/animpreviews/four-legged/dark_Fetch.webm b/static/animpreviews/fox/dark_Fetch.webmsimilarity index 100%rename from static/animpreviews/four-legged/dark_Fetch.webmrename to static/animpreviews/fox/dark_Fetch.webmdiff --git a/static/animpreviews/four-legged/dark_Howl.webm b/static/animpreviews/fox/dark_Howl.webmsimilarity index 100%rename from static/animpreviews/four-legged/dark_Howl.webmrename to static/animpreviews/fox/dark_Howl.webmdiff --git a/static/animpreviews/four-legged/dark_Idle Alert.webm b/static/animpreviews/fox/dark_Idle Alert.webmsimilarity index 100%rename from static/animpreviews/four-legged/dark_Idle Alert.webmrename to static/animpreviews/fox/dark_Idle Alert.webmdiff --git a/static/animpreviews/four-legged/dark_Idle.webm b/static/animpreviews/fox/dark_Idle.webmsimilarity index 100%rename from static/animpreviews/four-legged/dark_Idle.webmrename to static/animpreviews/fox/dark_Idle.webmdiff --git a/static/animpreviews/four-legged/dark_Jump.webm b/static/animpreviews/fox/dark_Jump.webmsimilarity index 100%rename from static/animpreviews/four-legged/dark_Jump.webmrename to static/animpreviews/fox/dark_Jump.webmdiff --git a/static/animpreviews/four-legged/dark_Run.webm b/static/animpreviews/fox/dark_Run.webmsimilarity index 100%rename from static/animpreviews/four-legged/dark_Run.webmrename to static/animpreviews/fox/dark_Run.webmdiff --git a/static/animpreviews/four-legged/dark_Sit.webm b/static/animpreviews/fox/dark_Sit.webmsimilarity index 100%rename from static/animpreviews/four-legged/dark_Sit.webmrename to static/animpreviews/fox/dark_Sit.webmdiff --git a/static/animpreviews/four-legged/dark_Sneak.webm b/static/animpreviews/fox/dark_Sneak.webmsimilarity index 100%rename from static/animpreviews/four-legged/dark_Sneak.webmrename to static/animpreviews/fox/dark_Sneak.webmdiff --git a/static/animpreviews/four-legged/dark_Walk.webm b/static/animpreviews/fox/dark_Walk.webmsimilarity index 100%rename from static/animpreviews/four-legged/dark_Walk.webmrename to static/animpreviews/fox/dark_Walk.webmdiff --git a/static/animpreviews/four-legged/light_Bark.webm b/static/animpreviews/fox/light_Bark.webmsimilarity index 100%rename from static/animpreviews/four-legged/light_Bark.webmrename to static/animpreviews/fox/light_Bark.webmdiff --git a/static/animpreviews/four-legged/light_Bite.webm b/static/animpreviews/fox/light_Bite.webmsimilarity index 100%rename from static/animpreviews/four-legged/light_Bite.webmrename to static/animpreviews/fox/light_Bite.webmdiff --git a/static/animpreviews/four-legged/light_Death.webm b/static/animpreviews/fox/light_Death.webmsimilarity index 100%rename from static/animpreviews/four-legged/light_Death.webmrename to static/animpreviews/fox/light_Death.webmdiff --git a/static/animpreviews/four-legged/light_Fall.webm b/static/animpreviews/fox/light_Fall.webmsimilarity index 100%rename from static/animpreviews/four-legged/light_Fall.webmrename to static/animpreviews/fox/light_Fall.webmdiff --git a/static/animpreviews/four-legged/light_Fetch.webm b/static/animpreviews/fox/light_Fetch.webmsimilarity index 100%rename from static/animpreviews/four-legged/light_Fetch.webmrename to static/animpreviews/fox/light_Fetch.webmdiff --git a/static/animpreviews/four-legged/light_Howl.webm b/static/animpreviews/fox/light_Howl.webmsimilarity index 100%rename from static/animpreviews/four-legged/light_Howl.webmrename to static/animpreviews/fox/light_Howl.webmdiff --git a/static/animpreviews/four-legged/light_Idle Alert.webm b/static/animpreviews/fox/light_Idle Alert.webmsimilarity index 100%rename from static/animpreviews/four-legged/light_Idle Alert.webmrename to static/animpreviews/fox/light_Idle Alert.webmdiff --git a/static/animpreviews/four-legged/light_Idle.webm b/static/animpreviews/fox/light_Idle.webmsimilarity index 100%rename from static/animpreviews/four-legged/light_Idle.webmrename to static/animpreviews/fox/light_Idle.webmdiff --git a/static/animpreviews/four-legged/light_Jump.webm b/static/animpreviews/fox/light_Jump.webmsimilarity index 100%rename from static/animpreviews/four-legged/light_Jump.webmrename to static/animpreviews/fox/light_Jump.webmdiff --git a/static/animpreviews/four-legged/light_Run.webm b/static/animpreviews/fox/light_Run.webmsimilarity index 100%rename from static/animpreviews/four-legged/light_Run.webmrename to static/animpreviews/fox/light_Run.webmdiff --git a/static/animpreviews/four-legged/light_Sit.webm b/static/animpreviews/fox/light_Sit.webmsimilarity index 100%rename from static/animpreviews/four-legged/light_Sit.webmrename to static/animpreviews/fox/light_Sit.webmdiff --git a/static/animpreviews/four-legged/light_Sneak.webm b/static/animpreviews/fox/light_Sneak.webmsimilarity index 100%rename from static/animpreviews/four-legged/light_Sneak.webmrename to static/animpreviews/fox/light_Sneak.webmdiff --git a/static/animpreviews/four-legged/light_Walk.webm b/static/animpreviews/fox/light_Walk.webmsimilarity index 100%rename from static/animpreviews/four-legged/light_Walk.webmrename to static/animpreviews/fox/light_Walk.webm