// SPDX-License-Identifier: MIT // Copyright (c) 2026 Incoprea // Find a component by Description tag // Not compiled or tested in-world // Setup: Put in a rezzed linkset of 2-64 prims and touch as owner. Seated avatars are excluded. Set MARKER, for example role:lamp. // Stop / restore: Remove or disable. This inspector changes no build properties. // Notes: Literal substring search is case-sensitive and may match a longer value. It does not interpret Description as structured data or change it. // License: see LICENSE in this distribution. // Original Incoprea example. MIT. string MARKER="role:lamp"; default { touch_start(integer count) { if(llDetectedKey(0)!=llGetOwner()) return; if(llGetAttached()) { llOwnerSay("Use a rezzed linkset."); return; } integer total=llGetObjectPrimCount(llGetKey()); if(total<2 || total>64) { llOwnerSay("Use a linkset of 2-64 prims."); return; } if(MARKER=="") { llOwnerSay("Set a nonempty marker."); return; } integer i; integer matches; for(i=1;i<=total;++i) { string description=llList2String(llGetLinkPrimitiveParams(i,[PRIM_DESC]),0); if(llSubStringIndex(description,MARKER)!=-1) { ++matches; llOwnerSay("Match at "+(string)i+": "+llGetLinkName(i)); } } llOwnerSay("Matches: "+(string)matches); } changed(integer flags) { if(flags & CHANGED_OWNER) llResetScript(); } }