Skip to content
lsl.devlsl.devLSL Dev

llDetectedName

function
Function syntax
string llDetectedName(
  1. integer item// Index of the detection information.
);
Returns
string
Energy
10

Returns

NULL_KEY

if item is not valid.

If the item detected is an avatar then the legacy name is returned.

Returns a string that is the name of the detected item.

How to use
string result = llDetectedName(0);
Example 1
default
{
touch_start(integer num_detected)
{
string name = llDetectedName(0);
llOwnerSay("Touched by " + name);
// name is the legacy name, as in "John Doe", or "John Resident" if the avatar has the default last name.
}
}
Original wiki source

Some wiki templates and tables need their original context. View this article on the Second Life Wiki. Technical wording and examples are retained from the source; historical guidance may differ from current behavior.