lazza79 Posted March 17, 2017 Share Posted March 17, 2017 Hi Guys, I would like to ask your help for some code. i have some primitives (constraints) disposed like an umbrella (one on top and many on the bottom, disposed round-is (like an umbrella). Imagine now a sphere going along the scene, when the sphere touches any of the extreme points, il would like to transfer a parameter from the sphere to ALL the connected points. I think I figured out how to do it but I don't know the code: I would like to know how to, having one of the 2 points of the segment, to know what is the number of the opposite point. Thank you! Cheers! Lazza Quote Link to comment Share on other sites More sharing options...
galagast Posted March 17, 2017 Share Posted March 17, 2017 (edited) 4 hours ago, lazza79 said: I would like to know how to, having one of the 2 points of the segment, to know what is the number of the opposite point. Could you possibly be referring to the neighbour and/or neighbours functions? Edited March 17, 2017 by galagast Quote Link to comment Share on other sites More sharing options...
lazza79 Posted March 17, 2017 Author Share Posted March 17, 2017 hmmm, no. I have several "umbrellas" sometime near to each other. I'm afraid that using neighbor function may get a point form another umbrella... Thank you! Lazza79 Quote Link to comment Share on other sites More sharing options...
galagast Posted March 17, 2017 Share Posted March 17, 2017 I thought that you were kinda going for something like this: H15.5.717 Indie - vex_neighbour.zip Any chance you could post a simple hip file? Quote Link to comment Share on other sites More sharing options...
lazza79 Posted March 17, 2017 Author Share Posted March 17, 2017 Yes, that is similar. Almost what I want. The difference is that I would like also the 2 stars that are touched bu the polygon, fully become red. I see in your video that when they are touched just one or 2 legs become red. I would like that if one leg becomes red, all the other legs connected do. Thank you very much!!! Cheers! Lazza79 Quote Link to comment Share on other sites More sharing options...
galagast Posted March 17, 2017 Share Posted March 17, 2017 Something like this? H15.5.717 Indie - vex_neighbour_v2.zip I updated the file and colored the changes and additions yellow. The method I used might work or might not work on your scene as the code depends on what kind of "umbrella" geometry you're using. Quote Link to comment Share on other sites More sharing options...
lazza79 Posted March 17, 2017 Author Share Posted March 17, 2017 Great! Thank you! I'll check it ASAP! Cheers! Lazza79 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.