S
spritesynthDOCS

Godot Export

Export sprites and sprite sheets for Godot with SpriteFrames and .tres resource files.

Overview

Export your pixel art from spritesynth in a format optimized for Godot. The export includes sprite sheets and .tres resource files for direct use with AnimatedSprite2D nodes.

Export Process

Via Editor

  1. Open your character, object, or tileset in the editor
  2. Click Export → Godot
  3. Configure options (scale, layout, background)
  4. Download the ZIP containing sprite sheet and resource files

Via API

curl -X GET https://api.spritesynth.dev/api/exports/characters/{id} \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "engine": "godot",
    "scale": 2,
    "background": "transparent"
  }'

Export Contents

The export ZIP contains:

character_godot_export/
├── sprite_sheet.png        # Combined sprite sheet
├── sprite_frames.tres      # SpriteFrames resource
└── README.md               # Import instructions

Importing into Godot

Using SpriteFrames

  1. Copy the exported files into your Godot project folder
  2. The .tres file is a Godot SpriteFrames resource
  3. Add an AnimatedSprite2D node to your scene
  4. In the inspector, set the Sprite Frames property to the imported .tres file
  5. Animation names from spritesynth map directly to Godot animation names

Manual Import

  1. Import the sprite sheet PNG into Godot
  2. Set Import As to Texture2D
  3. Create a new SpriteFrames resource in the AnimatedSprite2D node
  4. Add animations and assign texture regions from the sprite sheet

SpriteFrames Resource Format

The .tres file defines animations with frame textures and durations:

[gd_resource type="SpriteFrames" format=3]

[ext_resource type="Texture2D" path="res://sprite_sheet.png" id="1"]

[sub_resource type="AtlasTexture" id="AtlasTexture_idle0"]
atlas = ExtResource("1")
region = Rect2(0, 0, 32, 32)

[sub_resource type="AtlasTexture" id="AtlasTexture_idle1"]
atlas = ExtResource("1")
region = Rect2(32, 0, 32, 32)

[resource]
animations = [{
  "frames": [{"texture": SubResource("AtlasTexture_idle0")}, {"texture": SubResource("AtlasTexture_idle1")}],
  "loop": true,
  "name": &"idle",
  "speed": 8.0
}]
SettingValue
Sprite size16–64px per sprite
DimensionsPower-of-two (16, 32, 64)
Scale2x for hiDPI displays
BackgroundTransparent

Tips

  • Match animation names between spritesynth and Godot for seamless workflow
  • Use AnimatedSprite2D for animated characters, Sprite2D for static objects
  • Set the texture filter to Nearest for pixel-perfect rendering
  • Organize sprite sheets by character or object for cleaner imports

Need help?

Join our Discord community for support and tips.
Was this page helpful?

On this page