Video summary

Unity VFX Graph - Stylized Laser Beam Tutorial

Main summary

Key takeaways

Technology

Summary of the Unity VFX Graph Stylized Laser Beam Tutorial

The video is a tutorial on creating a stylized, animated laser/electric beam in Unity using VFX Graph, along with supporting assets made in Blender/Krita and materials/shaders made in Shader Graph. It also explains how to extend the base effect with additional beam layers (electric/dark/background) and add extra particle detail (sparks and an initial flash).


Main workflow / features

1) Set up the VFX Graph beam (core beam)

  • Start with an empty GameObject and create a VFX Graph (e.g., vfx graph – stylized beam).
  • Modify the particle behavior to:
    • Use Single burst (remove constant emission; set count to 1).
    • Use Mesh output instead of a default quad/capsule.
    • Use Set Lifetime controlled by a Blackboard float property named duration (default ~3 seconds).
    • Disable velocity (the beam stays static except for scaling/texture animation).
  • Build a custom mesh plane for the beam, exported from Blender as FBX:
    • Create a plane and adjust UV orientation (rotate so UVs run left-to-right with the mesh).
    • Ensure predictable scaling by using cursor/3D cursor workflows so the beam scales from the correct pivot.
    • In Unity:
      • Set mesh scale factor (e.g., 100).
      • Assign the mesh to the VFX Graph output particle mesh.
  • Fix camera-facing behavior:
    • Use an Orient block set to a fixed axis to keep the beam correctly oriented relative to the camera, with Z treated specially.
  • Animate beam dimensions with Set Scale over Life:
    • Use curves/keys so the beam:
      • Grows in length (Y) from ~0 near the start to full, then shrinks toward the end of lifetime.
      • Controls thickness (X) with a separate curve so it tapers over time.
    • Ensure the composition is Multiply so scaling combines correctly.

2) Create the beam texture (Krita)

  • Create a square canvas (e.g., 2048×2048).
  • Paint a stylized stripe/shape using Krita brushes:
    • Use Wrap Mode (toggle via Shift+W) for seamless texture authoring.
    • Use Erase and Smudge-style tools to refine edges and add internal distortion.
  • Export as PNG and import into Unity.
  • In Unity:
    • Enable alpha transparency.
    • Assign it as the beam material’s main texture.

3) Shader Graph laser material (scrolling + masking + dissolve + distortion)

  • Create a Shader Graph targeting Visual Effect usage:
    • Unlit
    • Alpha clipping enabled
  • Typical shader properties include:
    • Color (HDR, full opacity)
    • Mask texture (fade control)
    • Main texture (Krita beam texture)
    • Vector2 speed for texture scrolling
    • Parameters for alpha clip/dissolve, distortion amount, and distortion speed/scale
  • Key shader behavior:
    • Sample mask texture and main texture, then multiply them so start/end fade works.
    • Use Tiling and Offset + Time to scroll the texture.
    • Add mask-driven fade to soften the beginning/end of the laser.
    • Support dissolving using an alpha clip threshold (0–1 slider).
    • Add distortion:
      • Use a noise texture with tiling/offset.
      • Lerp between normal UVs (no distortion) and distorted UVs (full distortion).
      • Animate distortion using time × distortion speed (optionally negative to reverse direction).
  • In VFX Graph:
    • Assign the shader to the output particle.
    • If needed, enable non-experimental operator/blocks visibility so shader-related options appear.

4) Create a beam mask texture (Krita) for fade ends

  • Generate a 512×512 texture using the Gradient tool:
    • Opacity: 0 at start → near full in the middle (~60%) → 0 at end.
  • Export two versions:
    • One with black background (useful for alpha/additive workflows)
    • Another without black background (for alpha transparency blending workflows)
  • In Unity:
    • Assign the appropriate mask variant depending on blend mode.
  • The mask ensures the beam fades at the start and end.

Extending the look: multiple beam layers

5) Add distortion/exaggeration + electric variant

  • Duplicate the beam shader/particle setup:
    • Change color (e.g., to blue).
    • Increase alpha erosion via alpha clip.
    • Increase distortion amount (tuned to the texture created).
  • Result: a more “electric” feel.

6) Add a dark background layer

  • Duplicate again for a dark tint layer:
    • Set blend mode = Alpha.
    • Use a dark red color.
  • Fix common issues:
    • If the mask shows black edges, use the transparent mask export (no black background).
    • Adjust render order:
      • In the VFX Graph inspector, change “beam dark” ordering so it renders behind other layers (push it earlier).

7) Tuning blend modes and proportions

  • The tutorial highlights adjusting scalar values like beam width/intensity:
    • Reduce widths and balance alpha/brightness to keep good proportions.

Adding extra detail with particle systems

8) Stretched particles / sparks along the beam

  • Create a separate particle system inside the VFX Graph.
  • Configure:
    • Loop count/duration to match the beam timing.
    • Constant spawn rate (e.g., 40).
    • Use Z-axis velocity to create streaks (e.g., 20–40).
    • Short lifetime (~0.2–0.45).
    • Position arc (circle) bounds with adjusted radius.
    • Additive blend mode.
    • Size control:
      • Random X/Y scale range.
      • Orient block + Set Scale over life (often Multiply composition).
      • Curve shrinking from large to small.
    • Orange glow via Set Color with brightness multiplier.
  • Output: sparks streaming quickly along the beam.

9) Initial flash at the beam start

  • Add another short-lived additive particle layer:
    • Additive blend mode; optionally enable soft particles for better fading against geometry.
    • Random size (e.g., 2.5–5).
    • Very short lifetime (~0.1–0.2).
    • Multiply composition with a bright orange color.
  • Result: a bright flash at the laser start.

Source / speakers (end)

  • Main speaker: the channel creator (tutorial narration, e.g., “guys… let’s jump right into it”).
  • Sources/tools used (non-human):
    • Unity VFX Graph
    • Unity Shader Graph
    • Blender (FBX mesh plane)
    • Krita (textures and masks)

Rate this summary

Your feedback will help improve summaries.

Improve this summary

Reprocess with a stronger model when the summary feels incomplete or inaccurate.

Pro

Translate summary in another language

Pro

Ask questions to this video

Chat for follow-up questions, clarifications, and source-backed answers.

Coming soon

Share this summary

Original video