Wiki
  • Homepage
  • Player's Manual
    • Controls
    • Skills
    • Objects
    • Credits
  • Contributing
    • Getting Started
      • Programs and Files
      • Cloning the GitHub Project
      • Git Structure
      • Submitting Changes
    • Level Design
      • Basic Level Setup
      • Creating Static.tscn
      • Creating Collision.tscn
      • Stage Triggers
        • Using StageTrigger.tscn
        • Camera Triggers
        • Culling Triggers
        • Death Triggers
        • Dialog Triggers
        • Jump Triggers
        • Path Triggers
        • Automation Triggers
        • Drift Triggers
        • Foothold Triggers
        • Platform Triggers
        • Sidle Triggers
      • Stage Objects
      • Placing Objects Along the Path
    • Playtesting
      • General Shortcuts
      • Debug Menu
      • Free Camera Mode
      • Using the Editor for Playtesting
    • Submitting a Bug Report
    • Documentation Style Guide
  • Asset Guidelines
    • Source Files
    • Asset Ripping Reference
      • Original Model Files
    • Asset Editing Reference
      • Editing Environment Models
      • Editing Collision Models
      • All About Curves
      • Exporting Models from Blender
    • Resources Files
      • CameraSettingsResource
    • Miscellaneous Notes
  • Godot Guidelines
    • File Guides
      • File Structure
      • Naming Files
    • Project Settings
      • Tag Reference
      • Layer Reference
    • Particle Effects
    • Audio
  • CODE GUIDELINES
    • Language Specifications
    • Formatting
    • General guidelines
    • Attributes
    • Floating Point Numbers
Powered by GitBook
On this page
  • Editing Curves
  • Importing Curves into Godot
  • Vertical Paths
  1. Asset Guidelines
  2. Asset Editing Reference

All About Curves

PreviousEditing Collision ModelsNextExporting Models from Blender

Due to SatSR's on-rails nature, curves are very important, since they not only control where Sonic can move, but also how the camera works as well. Unfortunately, the way Godot's interprets a curve's tilt is a strange mix of Blender's "tangent" and "minimum" modes, making it difficult to work with.

Editing Curves

To start, you'll need to mess with the path's tilt in order for it to be properly lined up with the ground. To edit a path's tilt:

  • Select the curve.

  • Go into edit mode [TAB].

  • Select a point.

  • Adjust tilt in "Item -> Tilt" (Tap [N] if the menu is missing).

  • You can reset a point's tilt by pressing [Alt + T].

Important Note: Unless you're working on a perfectly , make sure your path is set to "Z-Up" in "Object Data -> Twist Method," otherwise your curve tilts might become messed up when it's time to export!

Importing Curves into Godot

  1. Make sure all of Blender's curves are set to "Z-Up" in "Object Data -> Twist Method."

  2. Save your .blend file.

  3. Load the python script below into Blender's Scripting window.

  4. Press Run [Alt + P]. It will generate .tres files (one for each curve in the scene) in the same directory as where you saved your Blender project.

  5. Move the .tres files into the Godot project. They should appear in Godot's FileSystem as curves.

  6. Select each curve and turn off "Up Vector Enabled" in Godot's curve properties.

  7. Create a new "Path3D" node and select it in the Inspector.

  8. Change "Curve" to your .tres file.

  9. Move the Path3D node to the position of the curve's first point. To find this:

    1. Open the curve in Blender and enter "Edit Mode" by pressing [TAB].

    2. Select your starting point and press [N] to bring up the side panel.

    3. Go to "Item -> Transform -> Control Point" for the X, Y, and Z coordinates. Keep in mind that Blender's Y is Godot's -Z, and Blender's Z is Godot's Y.

Vertical Paths

Unfortunately, the method above doesn't work for paths that are completely vertical. For these, you'll need to manually mess around until you get something that works. One particularly effective solution is to split the vertical sections into a separate path entirely, then use the PathTrigger (ref needed) to seamlessly switch to it when needed.

vertical path
4KB
BlenderCurveToGodot.py