V-Sekai / unidot_importer

Import .unitypackage and other assets designed for Unity Engine as a GDScript addon for vanilla Godot 4.x
MIT License
671 stars 28 forks source link

Unpacked prefabs referencing imported meshes with "force humanoid" should use a GeneralSkeleton #39

Open lyuma opened 8 months ago

lyuma commented 8 months ago

Currently when force humanoid is used, the model usually successfully imports as humanoid, but the prefabs referencing the model do not have an Avatar set, or in some cases do not have an Animator at all, so we should add additional logic to handle this case.

The logic should be if force humanoid is on, and there is a skinned mesh referencing a model imported as humanoid (even if forced), the entire skeleton that skinned mesh is in should switch to being a GeneralSkeleton.

This is really useful for importing outfits such that they can be copied and pasted directly from the unpacked prefab (with materials assigned), into the model the outfit is for.