Difference between revisions of "Talk:PRIM LINK TARGET"

From Second Life Wiki
Jump to navigation Jump to search
(noted bounds error message when PRIM_LINK_TARGET is used in a child prim)
 
(Add bug information)
 
(3 intermediate revisions by 2 users not shown)
Line 1: Line 1:
=== Caveat/bug ===
=== Caveat/bug (UPDATE: Fixed soon after it was reported) ===
Note for whoever writes this page; PRIM_LINK_TARGET only works if the script is in the root prim.  Otherwise it gives you an error.
Note for whoever writes this page; PRIM_LINK_TARGET only works if the script is in the root prim.  Otherwise it gives you an error.
<lsl>
ETA: Maestro Linden thinks it's a bug: https://jira.secondlife.com/browse/SCR-162
<source lang="lsl2">


default
default
Line 14: Line 15:


}
}
</lsl>
</source>
behaves as expected in the root, but gives the error
behaves as expected in the root, but gives the error
  llSetPrimitiveParams error running rule #2 (PRIM_LINK_TARGET): bounds error; 2 is not in (-4, 0).
  llSetPrimitiveParams error running rule #2 (PRIM_LINK_TARGET): bounds error; 2 is not in (-4, 0).
  llSetPrimitiveParams error running rule #4 (PRIM_LINK_TARGET): bounds error; 3 is not in (-4, 0).
  llSetPrimitiveParams error running rule #4 (PRIM_LINK_TARGET): bounds error; 3 is not in (-4, 0).
when called from a child prim. [[User:Innula Zenovka|Innula Zenovka]] 04:52, 16 August 2011 (PDT)
when called from a child prim. [[User:Innula Zenovka|Innula Zenovka]] 04:52, 16 August 2011 (PDT)
=== Bug in llGetLinkPrimitiveParams with PRIM_LINK_TARGET, LINK_THIS (Won't be fixed) ===
When used with llGetLinkPrimitiveParams, PRIM_LINK_TARGET, LINK_THIS won't target the current prim. It will target the prim specified in the first parameter of llGetLinkPrimitiveParams. See [https://jira.secondlife.com/browse/BUG-9866] for details. Workaround is to use llGetLinkNumber() if possible instead of LINK_THIS. LL said they are not fixing it for backwards compatibility concerns. --[[User:Sei Lisa|Sei Lisa]] ([[User talk:Sei Lisa|talk]]) 17:31, 10 August 2015 (PDT)

Latest revision as of 16:31, 10 August 2015

Caveat/bug (UPDATE: Fixed soon after it was reported)

Note for whoever writes this page; PRIM_LINK_TARGET only works if the script is in the root prim. Otherwise it gives you an error. ETA: Maestro Linden thinks it's a bug: https://jira.secondlife.com/browse/SCR-162

default
{
    state_entry()
    {
       llSetLinkPrimitiveParamsFast(
       1,[PRIM_COLOR,ALL_SIDES,<1.0,0.0,0.0>,1.0,
       PRIM_LINK_TARGET,2,PRIM_COLOR,ALL_SIDES,<0.0,1.0,0.0>,1.0,
       PRIM_LINK_TARGET,3,PRIM_COLOR,ALL_SIDES,<0.0,0.0,1.0>,1.0]);
    }

}

behaves as expected in the root, but gives the error

llSetPrimitiveParams error running rule #2 (PRIM_LINK_TARGET): bounds error; 2 is not in (-4, 0).
llSetPrimitiveParams error running rule #4 (PRIM_LINK_TARGET): bounds error; 3 is not in (-4, 0).

when called from a child prim. Innula Zenovka 04:52, 16 August 2011 (PDT)

Bug in llGetLinkPrimitiveParams with PRIM_LINK_TARGET, LINK_THIS (Won't be fixed)

When used with llGetLinkPrimitiveParams, PRIM_LINK_TARGET, LINK_THIS won't target the current prim. It will target the prim specified in the first parameter of llGetLinkPrimitiveParams. See [1] for details. Workaround is to use llGetLinkNumber() if possible instead of LINK_THIS. LL said they are not fixing it for backwards compatibility concerns. --Sei Lisa (talk) 17:31, 10 August 2015 (PDT)