A Godot4 plugin that helps with creating a Sprite3D with normal maps and animations
Prepare a full-action sprite sheet (.png format recommended) containing all frames for all animations, ensuring each action occupies a single horizontal row.
Generate a corresponding normal map for this sprite sheet, typically using a tool like Laigter.
Due to copyright restrictions, no sample sprite sheet or normal map is provided here.
Ensure both the sprite sheet and normal map are placed in your Godot 4 project folder.
In Project → Project Settings → Plugins, enable the Normal Maps for Sprite3D plugin.
Add a NormalMapsForSprite3D node and an AnimationPlayer node to your scene.
In the Inspector panel, configure the NormalMapsForSprite3D node properties:
Normal: Select the normal map texture.AnimationPlayer: Select theAnimationPlayernode for animation creation.Texture: Select the sprite sheet texture.Hframes: Set the number of horizontal frames in the sprite sheet.Vframes: Set the number of vertical frames in the sprite sheet.
You can create animations for the NormalMapsForSprite3D node using two methods:
Check the
Delete Existing Animations Before Creatingcheckbox to remove existing animations before creating new ones. This is useful when you want to retry with different settings.
-
Create a Single Animation Use the properties in the Inspector and click the
Create Animationbutton:Animation Name: Set the animation name.Animation Col: Select the starting column index (beginning at 1) of the animation's first frame.Animation Row: Select the starting row index (beginning at 1) of the animation's first frame.Frame Number: Set the total number of frames in the animation.Frame Duration: Set the duration of each frame.Loop Mode: Set whether the animation should loop.
-
Create Multiple Animations Use the
JSON Pathproperty in the Inspector and click theCreate Animation From JSONbutton:JSON Path: Set the path to a JSON file containing animation data, using the same configuration structure as method 1.
The JSON file must be placed in your Godot 4 project folder. Refer to
example_animations.jsonfor a template.