📚
Deadly Dungeons
  • Initial page
  • Traps
    • Introduction
    • Trap Triggers
    • Raycast Triggers
    • Disabling Traps with Triggers
    • Trap
    • Trap Mechanism
      • Animator
      • Launcher
      • Particle (Trap Mechanism)
      • Physics
    • Effect Handlers
      • Audio Handler
      • Particle (Effect Handler)
      • Ray Handler
      • Custom Effect Handler
    • Damage System
      • Damage Source
      • IDamageable
      • Damage Result
    • Damageable Example
    • Utility
      • AutoConnect Joint
      • Texture Mover
Powered by GitBook
On this page

Was this helpful?

  1. Traps
  2. Effect Handlers

Ray Handler

PreviousParticle (Effect Handler)NextCustom Effect Handler

Last updated 4 years ago

Was this helpful?

This component controls a to work as a laser. It uses a to determine if the laser hits something. Resizes the line renderer to match the raycast result.

Note: Rays can be only controlled by a Ray Handler.

  • Play On Awake: activates the effect on awake.

  • Delay: how long (in seconds) before the laser becomes visible after activation.

  • Line Renderer: Line renderer that represents the laser.

  • Spark Particle: A particle that appears at the end of the laser where it hits something.

  • Max Distance: How far can the laser extends.

  • Obstacle Layer Mask: You can ignore certain layers that do not interrupt the laser beam.

Line renderer
Physics Raycaster
This laser beam is controlled by a Ray handler script