Object identification key
|
|
Pedlar Decosta
Registered User
Join date: 7 May 2007
Posts: 12
|
09-02-2007 23:08
I am hoping someone can answer what I expect is a very simple question, but although I have looked for a few days I cannot find the answer by myself. I need to get the key for a prim/s. The reason is to change the direction of particles in mid life by attracting them to a prim. Can someone tell me how to locate a prims key?
|
|
Chosen Few
Alpha Channel Slave
Join date: 16 Jan 2004
Posts: 7,496
|
09-03-2007 01:52
http://wiki.secondlife.com/wiki/LlGetKey(Edited to remove an alternate method that doesn't actually work.)
_____________________
.
Land now available for rent in Indigo. Low rates. Quiet, low-lag mainland sim with good neighbors. IM me in-world if you're interested.
|
|
Pedlar Decosta
Registered User
Join date: 7 May 2007
Posts: 12
|
09-03-2007 02:15
Thank you very much ! 
|
|
Rusty Satyr
Meadow Mythfit
Join date: 19 Feb 2004
Posts: 610
|
09-03-2007 02:21
I'm not sure Chosen's example works with prims/objects, because copies of objects often get assigned new keys. (rezzing something from inventory usually creates a copy, unless you're wearing it, or it's a unique item).
Have you visited the particle lab? There were a few target examples set there.
|
|
Simil Miles
Creator
Join date: 1 Mar 2007
Posts: 300
|
09-03-2007 04:53
Keys of inventory's objects are null. llGetKey must be used but you won't be able to change the direction of already emitted particles unless they are already targeting the key (that is moving).
_____________________
UnConWTech @ Flo (144, 84, 224) http://unconwtech.free.fr
SL books http://astore.amazon.com/secondlife-sl-20/
Need a beta tester for quality assurance ? Need a translator for English, French, Spanish ?
|
|
Chosen Few
Alpha Channel Slave
Join date: 16 Jan 2004
Posts: 7,496
|
09-03-2007 08:18
Rusty & Simil, thanks for the correction. You're absolutely right, of course. That's what I get for posting at 5 in the morning after having been up all night working on a project. Note to self: don't do that again.  Editing post to remove error,
_____________________
.
Land now available for rent in Indigo. Low rates. Quiet, low-lag mainland sim with good neighbors. IM me in-world if you're interested.
|
|
Johan Laurasia
Fully Rezzed
Join date: 31 Oct 2006
Posts: 1,394
|
09-03-2007 08:27
You dont have to use llGetKey(), you can use a sensor event combined with llDetectedKey(), that way the key can be changed on the fly rather than manually changing the key
|
|
Rusty Satyr
Meadow Mythfit
Join date: 19 Feb 2004
Posts: 610
|
09-03-2007 08:34
From: Simil Miles Keys of inventory's objects are null. llGetKey must be used but you won't be able to change the direction of already emitted particles unless they are already targeting the key (that is moving). Eh? When did that happen I wonder (has it always been like that?) ... I suspect they only appear as null when copy asset uuid is used. Curious. Anyway, I think the OP can still get their desired effect. I've seen pre-existing particles suddenly swerve when the llParticleSystem gets called again with a new target. Even without that, they may be able to accomplish what they're trying with a target set right at first.
|
|
Pedlar Decosta
Registered User
Join date: 7 May 2007
Posts: 12
|
09-03-2007 15:18
ok, well, now I am fairly well confused lol. This is the area of the script that asks for the object key -
// Select a target for particles to go towards // "" for no target, "owner" will follow object owner // and "self" will target this object // or put the key of an object for particles to go to key target = "";
I want the particles to head towards another object other than the one they originated from, so it seems I need the key to do this.
...... any suggestions ?
|
|
Simil Miles
Creator
Join date: 1 Mar 2007
Posts: 300
|
09-03-2007 19:59
_____________________
UnConWTech @ Flo (144, 84, 224) http://unconwtech.free.fr
SL books http://astore.amazon.com/secondlife-sl-20/
Need a beta tester for quality assurance ? Need a translator for English, French, Spanish ?
|