louriccia / blender-swe1r

Blender add-on for importing and exporting SWE1R asset files
GNU General Public License v3.0
2 stars 2 forks source link

Blender Add-on for Star Wars Episode I: Racer

This is a Blender add-on that allows for importing and exporting from Star Wars Episode I:Racer's .bin files.

Status

🚧 Work in Progress

This project is currently under active development. While it may be functional for some use cases, please be aware that it is not yet feature-complete, and changes may be introduced frequently. Your feedback, suggestions, and contributions are welcome!

Features

Requirements

Blender 4.0

Installation

  1. Download the latest release OR make a zip file of this repo
  2. In Blender, go to Edit -> Preferences -> Add-Ons -> Install... and select the .zip file
  3. Enable the add-on by clicking the checkbox.
  4. Open the tools on the right side of the 3D view (probably hidden by a small left arrow) and click the SWE1R Import/Export tab

Importing

  1. Set the import folder by clicking the folder icon under "Import". If importing from your game files, this folder should be located at Star Wars Episode I Racer > data > lev01
    This folder should contain the following files:

    • out_modelblock.bin
    • out_splineblock.bin
    • out_spriteblock.bin
    • out_textureblock.bin
  2. Select a model from the Model dropdown. You may filter this list using the Type dropdown to filter the type of models to select from.

  3. Click "Import".

Exporting

  1. Set the export folder by clicking the folder icon under "Export". This folder should contain existing .bin files for each block.
  2. Select a collection or object within a collection. All objects within the active collection are considered for export.
  3. Select which assets to export. You may select to affect the out_modelblock.bin, out_textureblock.bin or out_splineblock.bin by toggling the Model, Texture, and Spline buttons respectively.
  4. Click "Export".

Spline Editing

When importing a track, it should come with a spline object. This spline is from out_splineblock.bin and is the entity that the game uses to define the player's lap progression, start and finish line, spawn/respawn points, map display, guide arrow behavior, Zero-G mode (ZOn), and AI pathing.

Cyclic Tracks

All tracks in the game are cyclic by default, meaning their last point connects back to their first point to create a loop.

Non-Cyclic Tracks (Rally)

The game also supports using a non-cyclic spline for a track. This allows us to easily create a point-to-point (rally) track.

Branching Paths

Some tracks feature branching paths. Blender does not support branching splines, so the first and last points of any alternate paths will be merged to the closest eligible points on any existing splines.
To create an alternate path, create a new spline within the same curve object. This is easily done by selecting a spline point (in edit mode) and pressing Shift + D to duplicate an existing point, then pressing E to extrude. When ending the path, keep in mind that the last point you place will be replaced by the closest existing point (if it isn't already joining 4 paths).

Limitations

Other Tips

Vertex Colors

Known Issues

License

This project is licensed under the GNU GENERAL PUBLIC LICENSE - see the LICENSE.md file for details.

Thanks

The following people have contributed to this project through feedback and insight. They're awesome!

Related Projects

Support development by sending me some truguts

ko-fi