Open MitchWoodin opened 1 year ago
This should be possible with stashed NLA strips according to: https://docs.blender.org/manual/en/latest/addons/import_export/scene_gltf2.html#export
But maybe the strip size and properties aren't correctly taken into account. Also doesn't seem like animation mode is getting changed in the .blend importer code right now (regression?).
Also keep in mind that the NL:A system in Blender 4.x is being removed in favor of a new system. Any changes made to importing blend files into Godot needs to take into consideration many of the upcoming Blender 4.0 and 4.x breaking changes.
Describe the project you are working on
A top-down survival game
Describe the problem or limitation you are having in your project
Using the automatic blender import functionality. Loops aren't set correctly because they contain an extra frame that's unneeded.
Describe the feature / enhancement and how it helps to overcome the problem or limitation
Use the NLA layers as the animations in the
AnimationPlayer
. This should take into account the length of the NLA strips so that extra/unwanted frames can be easily removed.Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams
Only animations that are present in the NLA strip will be transferred across.
If this enhancement will not be used often, can it be worked around with a few lines of script?
I think the only workaround is to manually add/remove keyframes.
Is there a reason why this should be core and not an add-on in the asset library?
This will give users more control over what animations are present in the Godot file. It also make it clearer to the user exactly what's being transferred.