Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

Setting Mirror Flag

Fiona Branagh
... or her equivalent.
Join date: 1 Feb 2007
Posts: 156
01-14-2009 09:15
Anyone able to show me an example for setting the mirror flag with llSetPrimitiveParams? As always, the LSL Wiki is woefully cryptic when it doesn't give a direct example.

Thanks in advance.
_____________________
Nexii Malthus
[Cubitar]Mothership
Join date: 24 Apr 2006
Posts: 400
01-14-2009 11:00
What? There are loads of examples, ridicolous!
https://wiki.secondlife.com/wiki/LlSetPrimitiveParams#Examples
_____________________

Geometric Library, for all your 3D maths needs.
https://wiki.secondlife.com/wiki/Geometric

Creator of the Vertical Life Client
Boss Spectre
Registered User
Join date: 5 Sep 2005
Posts: 229
01-14-2009 11:17
Here you go:

llSetPrimitiveParams([ PRIM_TYPE, PRIM_TYPE_SCULPT, (key)"d962089b-2197-993c-9ec9-4993eb0a95f2", PRIM_SCULPT_TYPE_SPHERE | PRIM_SCULPT_FLAG_MIRROR ] );

~Boss
Fiona Branagh
... or her equivalent.
Join date: 1 Feb 2007
Posts: 156
01-14-2009 11:41
Boss, thank you. Nexii, you'd look a little less [sic] "ridicolous" if you'd thoroughly read the question.
_____________________
Fiona Branagh
... or her equivalent.
Join date: 1 Feb 2007
Posts: 156
01-14-2009 12:03
Interestingly, adding the |PRIM_SCULPT_FLAG_MIRROR as shown results in "Name not defined within scope." It's the only part I've added to an otherwise functioning script. Call is shown below, with texture UUID blanked out:

llSetPrimitiveParams([PRIM_POSITION, RShoulder_High_pos, PRIM_ROTATION, RShoulder_High_rot/root_rot, PRIM_TYPE, PRIM_TYPE_SCULPT, "###", PRIM_SCULPT_TYPE_SPHERE | PRIM_SCULPT_FLAG_MIRROR, PRIM_SIZE, <1.020, 1.020, 1.020>]);
_____________________
Pale Spectre
Registered User
Join date: 2 Sep 2005
Posts: 586
01-14-2009 12:06
And for those of you who get: "Name not defined within scope"

...you might try: llSetPrimitiveParams([ PRIM_TYPE, PRIM_TYPE_SCULPT, (key)"d962089b-2197-993c-9ec9-4993eb0a95f2", PRIM_SCULPT_TYPE_SPHERE | 128]);

It would appear that PRIM_SCULPT_FLAG_MIRROR is some kind of RC thing.
Fiona Branagh
... or her equivalent.
Join date: 1 Feb 2007
Posts: 156
01-14-2009 12:09
Thank you Pale, that works :)
_____________________
Boss Spectre
Registered User
Join date: 5 Sep 2005
Posts: 229
01-14-2009 12:26
Sorry about that, I am using client version 1.21.6 (99587) Oct 14 2008 (Second Life Release), which recognizes the constant PRIM_SCULPT_FLAG_MIRROR ... you may just need to update if you are using an earlier client release.

You can check http://secondlife.com/support/downloads.php for the latest.

~Boss
Fiona Branagh
... or her equivalent.
Join date: 1 Feb 2007
Posts: 156
01-14-2009 12:36
I was using the current SL Release Candidate, which apparently has lost the ability to understand that flag. Hopefully they'll remember to include it before release.
_____________________
Boss Spectre
Registered User
Join date: 5 Sep 2005
Posts: 229
01-14-2009 12:43
From: Fiona Branagh
I was using the current SL Release Candidate, which apparently has lost the ability to understand that flag. Hopefully they'll remember to include it before release.

Sounds like a reportable RC bug to me! Good catch Fiona.

~Boss
Hewee Zetkin
Registered User
Join date: 20 Jul 2006
Posts: 2,702
01-14-2009 15:55
For viewers that don't recognize constants and such, compile the script while it is in object inventory. That's done (I THINK for LSO, but definitely for Mono) on the server side, whereas compiling from your own inventory is (I believe) still done from your client. The editor may not highlight certain new constants if they haven't reached the viewer yet, but on compilation they should work.