If detect is TRUE, VolumeDetect is enabled, physical object and avatars can pass through the object.

Syntax

void llVolumeDetect( integer detect );

Forced delay: 0.0 seconds. Energy: 10.0.

Parameters

integer detect (boolean)
TRUE enables, FALSE (default) disables

This works much like Phantom, but unlike Phantom, VolumeDetect objects trigger collision_start and collision_end events when interpenetrating. Collision events will trigger in any script in the object.

Specification

Events queued depending on type

VolumeDetectPhantom
Events
Supported
collision_start

collision_end
land_collision_start
land_collision
land_collision_end

Differences

There are a couple differences in how Phantom and VolumeDetect handle collisions; specifically which events are supported and how they handle the ground.

VolumeDetect

Phantom

Caveats

Attachments

Note: Attachments are not included in the avatar's bounding box. Collision events received by attachments are collisions the avatar is having with the world, not collisions the attachment is having. Nothing actually can collide with an attachment[1].

Examples

default
{
    state_entry()
    {
        llVolumeDetect(TRUE); // Starts llVolumeDetect
    }
    collision_start(integer total_number)
    {
        llSay(0, "Detected!"); // Tells you when something penetrates the prim
    }
}

See also

Events

Functions

Deep notes

Issues

Footnotes

  1. Even if attachments were included in an avatars bounding box, you would not like the outcome, the avatars bounding box is not deformed by animations.