Pushit1488312089 Posted October 19, 2015 Share Posted October 19, 2015 Hi, Ip urchased a full perm script to change textures on a broken mesh avatar from a HUD. integer link = LINK_SET; // Link number to apply the texture to (LINK_SET for all links)The scripts works great on all sections of the avatar (link_set) or in 1 section of the avatar (integer link = 4; for example) My quiestion is:How can I choose 2 or 3 different sections of the avatar? I tried integer link = 4;5;6;or 4,5,6; etcwith of course no success.Can anyone help me? Thanks Link to comment Share on other sites More sharing options...
Freya Mokusei Posted October 19, 2015 Share Posted October 19, 2015 Three possible options spring to mind:- You can set the unnecessary faces to colour black which would let you skip all this. Run multiple texture-change commands (probably llSetPrimitiveParams?) each with a different face value. You may want to add a FOR loop to iterate the texture-change command through multiple separate faces. There's not enough information in your post to advise how to make these changes. A variable cast as an integer cannot store multiple values (you may want to compare with the list type, which can store multiple values). Please remember that the 'code' button exists for pasting code into posts, it has a symbol like this: </> 1 Link to comment Share on other sites More sharing options...
Pushit1488312089 Posted October 19, 2015 Author Share Posted October 19, 2015 Thanks for the reply freya... here´s the complete script that goes in the HUD integer channel = -1000001; // Channel for comms (Must be same as reciever). string texture = "3190028f-1397-4b3b-bc8d-23c5bb7b250d"; // UUID of Texture to apply integer link = LINK_SET; // Link number to apply the texture to (LINK_SET for all links). integer face = ALL_SIDES; // Face number to apply the texture to (ALL_SIDES for all faces).string SR = "*"; // Seperator to use in the list, must be the same // as the seperator to be used within the reviever // script.////////////////////////////////////////////////////////////////////default{ touch_start(integer total_number) // When object is touched. { // Say each texture property with the seperator inbetween so the reciever can parse it. llRegionSay(channel,texture+SR+(string)link+SR+(string)face); }} I don´t need to select different faces... just prims (linked parts of the mesh) Link to comment Share on other sites More sharing options...
Rolig Loon Posted October 19, 2015 Share Posted October 19, 2015 Or, if you don't want to go to the trouble of doing as Freya suggests, simply run the script two or three times, changing the link number each time you do it. :smileywink: 1 Link to comment Share on other sites More sharing options...
Freya Mokusei Posted October 19, 2015 Share Posted October 19, 2015 The script you've pasted is just a broadcaster and doesn't set texture changes itself. Using just this script your options are:- You could 'fake' correct operation by broadcasting this llRegionSay multiple times per touch_start with the correct values. You could create one HUD button per link/face, each with single llRegionSay lines. This would be inefficient. Note that you should be reading the contents of the links I'm posting to improve your understanding of LSL - this forum is for help in improving your skills, I don't provide free answers. Link to comment Share on other sites More sharing options...
Pushit1488312089 Posted October 19, 2015 Author Share Posted October 19, 2015 Thanks rolig... that´s a smart solution, the problem is that this is an applier for creators to just write their UUID... I´d like them to o it only once. Freya... sorry about the code. Link to comment Share on other sites More sharing options...
Freya Mokusei Posted October 19, 2015 Share Posted October 19, 2015 No worries - I only mention because many here (me included) read a looooot of code on a daily basis and swapping back from monospace hurts my eyes and brain. Good luck in your application. Link to comment Share on other sites More sharing options...
Recommended Posts
Please take a moment to consider if this thread is worth bumping.
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now