|
Tsukasa Sakai
Registered User
Join date: 13 Oct 2006
Posts: 16
|
04-29-2007 04:35
Hi everyone,
I have two objects (not linked) - one object replaces the texture on another. I'm using llGiveInventory to hand over the next texture, and the changed() event to apply it to sides of the prim.
However when a new texture comes in, I need it to delete old ones, and apply the new one. But I can't see how the script would know which texture came in (to apply it, and delete all the others).
Can anyone offer some advice please?
Tsukasa
|
|
Newgate Ludd
Out of Chesse Error
Join date: 8 Apr 2005
Posts: 2,103
|
04-29-2007 06:33
From: Tsukasa Sakai Hi everyone,
I have two objects (not linked) - one object replaces the texture on another. I'm using llGiveInventory to hand over the next texture, and the changed() event to apply it to sides of the prim.
However when a new texture comes in, I need it to delete old ones, and apply the new one. But I can't see how the script would know which texture came in (to apply it, and delete all the others).
Can anyone offer some advice please?
Tsukasa The receiver script just needs to remember the name of the texture it has applied and then delete it after applying the new one.
|
|
Tsukasa Sakai
Registered User
Join date: 13 Oct 2006
Posts: 16
|
04-29-2007 07:08
Thanks Newgate  How would I write a loop that creates a list of all textures in the object? I've had a quick look, I can't find a script that does it. Help very much appreciated!
|
|
Tsukasa Sakai
Registered User
Join date: 13 Oct 2006
Posts: 16
|
04-29-2007 07:25
Aha, I have it solved. Thanks everyone ^^
|
|
Senuka Harbinger
A-Life, one bit at a time
Join date: 24 Oct 2005
Posts: 491
|
04-29-2007 12:10
Alternatively, you could use llSay/shout to broadcast the key of the texture you want applied, and have the object apply the texture from that data; no need to mess with inventory exchanges/alterations which should be a slightly lower load on the sim/server
_____________________
My SLExchange shopTypos are forgiven; desecrating the english language with reckless abandon and necrophilic acts is not. The function is working perfectly fine. It's just not working the way you wanted it to work.
|
|
Newgate Ludd
Out of Chesse Error
Join date: 8 Apr 2005
Posts: 2,103
|
04-30-2007 06:41
From: Senuka Harbinger Alternatively, you could use llSay/shout to broadcast the key of the texture you want applied, and have the object apply the texture from that data; no need to mess with inventory exchanges/alterations which should be a slightly lower load on the sim/server The caveat to that is that it will only work for full mod/copy/trans textures. Any other combination will return NULL_KEY.
|