Skip to content

tcmug/godot_vaportrail

Repository files navigation

Vaportrail

vaportrail

Godot 4.x vapor trails and ribbon effects.

vaportrail

About

This is a new and improved version of godot_trailmesh.

VaporTrail allows you to add 3D trails via an emitter, have the shape defined by a curve and colored with a gradient. You can set the alignment of the trail mesh to camera or any if the axis of the mitter (x, y, z).

Settings

vaportrail

Config

Property Description
Alignment Defines mesh orientation: Camera, X, Y, or Z axis
Geometry Nodepath Node path for mesh placement when camera unavailable
Num(ber of) Points Mesh detail/length (higher = more detailed)
Update Interval Frequency of new point generation (lower = smoother)
Randomness Adds randomness to point sizes
Alignment

Defines how to align/orient the mesh:

  • Camera: Facing camera
  • X: Along the X axis
  • Y: Along the Y axis
  • Z: Along the Z axis
Geometry Nodepath

In some situations where the active camera cannot be fetched, e.g. when using viewports, this will force the mesh instance to be placed under the given node instead of directly under the VaporTrail node.

Also, if you wish to prevent the trail from disappearing when the VaporTrail node is removed, setting this allows the trail to fade out instead of abruptly disappear. This is not perfect but works for some situations.

Num(ber of) Points

How many points, or how detailed the mesh can be - essentially defines how long it is along with Update Interval.

Update Interval

When the VaporTrail mesh is moving, how often we push a new point to the mesh (or how often it is allowed to grow). The smaller this is the smoother the trail will be, but for now this is also tied to frame rate.

Randomness

Adds a bit of randomness to the point size.

Visual

Property Description
Material Material applied to the mesh (avoid billboarding)
Size Width of the trail ribbon in units
Minimum Onscreen Size Ensures visibility at distance (camera alignment only)
Size Curve Adjusts point sizes along the trail
Color Gradient Applies color variation to the trail
UV Shift Animates texture by shifting UV coordinates
UV Alignment UV calculation mode: Fixed (linear) or Rolling (distance-based)
Material

The material applied to the mesh. NOTE: as the mesh itself is already "billboarded" billboarding via material will break things.

Size

Size of the points, 1 gives a ribbon of 1 unit width.

Minimum Onscreen Size

Correctly applies to only trails with Camera alignment. This ensures the mesh will not be smaller than the given amount of pixels when rendered. Useful for making very distant trails visible.

Size Curve

Gives a little bit of shape for the trail, adjusting the point size. This will affect Minimum Onscreen Size.

Color Gradient

Gives color to your trail.

UV Shift

Applies simple animation by shifting the positioning of the texture in the uv x axis.

UV Alignment

Controls how UV coordinates are calculated along the trail:

  • Fixed: Linear UV progression (head is at u-coordinate 0 and tail is 1)
  • Rolling: Distance-based UV progression (texture rolls along trail)

About

This will be the new version of godot_trailmesh

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors