EVENT_SCAN

ENABLE_SCAN

Detected by a c_scan instruction.

Modifies:

you - Pointer to scanning entity, if any.
result - Distance to the center of the scan cone.

Example:

function scan_event() 
{
  if (event_type == EVENT_SCAN) 
  {
     ent_playsound(my,whamm,50);
     ent_remove(me); // disappear when hit
  }
}

action exploding_barrel_scan() 
{
  my.emask |= ENABLE_SCAN; // sensible for scans
  my.ENABLE_SCAN = ON; 
  my.event = scan_event;
}

See also:

event, c_scan, EVENT_DETECT