Talk:LlSetLinkPrimitiveParams

From Second Life Wiki
Jump to navigation Jump to search

I've been having problems when working with faces of linked prims. The first set appears to apply itself, and any other face used in the sets when you only specify 1 face, and another set is after it. (ie, the following code will color face 0 and 2 red)

   llSetLinkPrimitiveParams(link, [
       PRIM_COLOR, 0, <1,0,0>, 1,
       PRIM_TEXTURE, 2, "Tech.jpg", <1,1,0>, <0,0,0>, 0
       ]);

--Dedric Mauriac 18:32, 25 December 2007 (PST)

This is a known bug (well, in llSetPrimitiveParams(), but it's not surprising that it's here also). See http://jira.secondlife.com/browse/SVC-38 -- Dale Innis 05:50, 14 February 2008 (PST)

would like to add this to caveats but the edit is too complex.

PRIM_POSITION, llSetLinkPrimitiveParams expects a local position, relative to the location of the root prim.

see SVC-3216

Syn Short 13:42, 11 October 2008 (PDT)

I've made the change you wanted, please see: llSetLinkPrimitiveParams#Caveats-PRIM_POSITION, the actual text for the caveat resides in the code of PRIM_POSITION. -- Strife (talk|contribs) 15:16, 11 October 2008 (PDT)

PRIM_TYPE_CYLINDER > vector slice?

Any idea if and when this with happen? -- Eddy (talk|contribs) 05:21, 6 July 2009 (UTC)

This reminds me of an old joke about hell being exothermic or endothermic. We probably won't get it until all hell freezes over... -- Strife (talk|contribs) 11:55, 6 July 2009 (UTC)

That's far sighted of LL. NOT. Meaning that if one uses the function to adjust a prim with slice set it resets the slice to zero (I have learned this the hard way). Should that be mentioned in the caveats? Not looking forward the the cold snap. Still waiting for Zoom control for camera in lsl too. Can't help but want to set the Link number to number(S) as well here. Eg. (4 | 5 | 6,[]). Ah yes also I was going to add a note about the float for hole size being between 0.0 and 1.0 not 0.0 and 100.0 but didn't know quite where to put it. -- Eddy (talk|contribs) 12:06, 6 July 2009 (UTC)

I'm not seeing any problems with the hole_size. Try purging the page and seeing if that helps. -- Strife (talk|contribs) 16:55, 6 July 2009 (UTC)

Ah yes. I see the hollow (hole size) limits are in the floating text. I didn't notice it there before. Is there a way to pick a particular set of link numbers with this function? Other than the likes of LINK_ROOT and LINK_ALL_CHILDREN etc. -- Eddy (talk|contribs) 02:35, 7 July 2009 (UTC)

Nope -- Strife (talk|contribs) 20:21, 20 February 2010 (UTC)

How does one edit a page like this?

I was going to add a couple of things including the above mentioned slice caveat but cannot figure out how to edit the page. Where is all the writing? Incidentally there is a jira requesting support of slice in lsl MISC-2847 (Although I know you know this Strife, others reading this may not have known). -- Eddy (talk|contribs) 12:27, 6 July 2009 (UTC)

The page gets all of it's content from the PRIM_* articles and related templates (transclusion ad nauseum). If you want to do that, create Template:Issues/MISC-2847 and include it near the top of PRIM_TYPE_BOX (be sure it gets in the include section or it won't get carried over to the others articles). Just be very careful; because of the extensive use of transclusion the PrimitiveParams articles are quite heavy when it comes to CPU time. -- Strife (talk|contribs) 15:42, 6 July 2009 (UTC)

Thanks Strife. I really don't know how to "be careful" in this respect. CPU time is not something I understand. However it is good to know a little more about how the wiki is built. I'm guessing CPU time is something to do with the page being created out of information from all different pages at the same time. That's complex. I keep forgetting that what you see on the screen isn't actually there. 1's and 0's -- Eddy (talk|contribs) 02:39, 7 July 2009 (UTC)

Basically try not to make a lot of little edits and preview them before you save them. If you screw up the formatting you will see some indication of it during preview. -- Strife (talk|contribs) 16:29, 7 July 2009 (UTC)

Gotya. Preview is my friend. Little edits are my enemy. Forgetting to sign is my weakness. Enthusiasm is a mixed blessing. -- Eddy (talk|contribs) 16:33, 7 July 2009 (UTC)

mooving linked prims independently finally !!

I had to test out this for myself. I post this because i didn't found any working script, just complaints.

--root prim--

<lsl>default {

   touch_start(integer c)
   {
       llMessageLinked(LINK_ALL_CHILDREN, 0, llDetectedName(0), llDetectedKey(0));
   }

}</lsl>

--child prim--

<lsl>default {

   link_message(integer source, integer num, string str, key id)
   {
       llWhisper(0, str + " (" + (string)id + ") touched me!"); 
       //  1 line between the following ones is not necessary
       llSetLinkPrimitiveParams(LINK_THIS,[PRIM_POSITION, llGetRootPosition() + <0,0,1>]); 
       llSetLinkPrimitiveParams(LINK_THIS,[PRIM_POSITION, llGetLocalPos() + <0,0,1>]);     
   }

}</lsl>

tested by felphar Clarity (the last 2 lines is my work breakthrough)

There is a caveat - there is a distance limit between root and child prim around 3 meters, so keep prims close and use short distances. —The preceding unsigned comment was added on 19:36, 22 February 2010 by Felphar Clarity

PRIM_ROTATION ignores zero rotation?

In a recent project I noticed that PRIM_ROTATION was being ignored if I tried to apply the zero rotation <0,0,0,1> to a child object. Has anyone else noticed this? The workaround I used was to replace ZERO_ROTATION with its negative: <0,0,0,-1>. --Samm Florian 11:37, 19 March 2011 (PDT)

Workaround for non-working small position-updates on attachments (e.g. moving an attachment by 0.001m)

<lsl>

   default
   {
       touch_end(integer num)
       { //Workaround for non-working small position-updates on attachments (e.g. moving an attachment by 0.001m)
           llSetColor(<0,0,0>, ALL_SIDES);
           llSetPrimitiveParams([PRIM_POSITION, <0,0,0.2>]);
           llSleep(2);
           llSetPrimitiveParams([PRIM_POSITION, <0,0,0.2>+<0,0,0.001>]);
           llSetColor(<1,0,0>, ALL_SIDES); //the llSetColor-call forces an object-update
       }
   }

</lsl> --MartinRJ Fayray 22:58, 4 April 2013 (PDT)