The BeamEffect component creates a visual beam effect in the scene, simulating a continuous line or laser-like effect.
Unlike LineRenderer these beams can change over time, spawn multiple instances, and have various properties like color, texture, and lifetime.
This is a useful component for creating things like laser beams, energy effects and tracers.
| Additive |
If true, the beam is rendered additively, making it appear to glow. |
| Alpha |
Alpha multiplier for the beam's color. Controls transparency over the beam's lifetime. |
| BeamColor |
Color gradient of the beam over its lifetime. Defines how the color changes from birth to death. |
| BeamLifetime |
Lifetime of each beam in seconds. Determines how long a beam remains before being removed or respawned. |
| BeamsPerSecond |
Number of beams spawned per second. Controls the spawn rate for continuous effects. |
| Brightness |
Brightness multiplier for the beam's color. Adjusts intensity over the beam's lifetime. |
| DepthFeather |
Amount of feathering applied to the beam's depth, softening its intersection with geometry. |
| FollowPoints |
If true, the beam endpoints follow their source and target positions each frame, updating dynamically. |
| InitialBurst |
Number of beams spawned immediately when the effect is enabled. |
| Lighting |
If true, the beam is affected by scene lighting. |
| Looped |
If true, beams respawn automatically when they expire, creating a looping effect. |
| Material |
Material applied to the beam. Defines the visual appearance along the beam's length.
The material should be based on the `line.shader`. |
| MaxBeams |
Maximum number of beams that can exist at once. Limits the total active beams. |
| Opaque |
If true, the beam is rendered as opaque rather than transparent. |
| Scale |
Thickness of the beam in world units. Controls how wide the beam appears. |
| Shadows |
If true, the beam casts shadows in the scene. |
| TargetGameObject |
GameObject to target with the beam. If assigned, overrides TargetPosition and uses the object's world position as the endpoint. |
| TargetPosition |
World position the beam targets if no target object is set. Used as the endpoint for the beam. |
| TargetRandom |
Random offset applied to the target position for visual variation. Adds randomness to the endpoint. |
| Textureobsolete |
Texture applied to the beam. Defines the visual appearance along the beam's length. |
| TextureOffset |
Offset of the texture along the beam. Shifts the texture start position. |
| TextureScale |
Scale of the texture along the beam. Controls how many world units each texture tile covers. |
| TextureScroll |
This is pretty much the same as TextureOffset - but it's seperate so you can use offset for offset, and scroll to scroll. |
| TextureScrollSpeed |
Speed at which the texture scrolls along the beam. Positive values scroll in one direction, negative in the other. |
| TravelBetweenPoints |
If true, the beam visually travels from start to end, useful for tracer effects. |
| TravelLerp |
Controls the interpolation of the beam's travel effect over its lifetime. |