EdArt Posted November 9, 2017 Share Posted November 9, 2017 (edited) I'm new to this place, so apologies if I'm being dumb about anything. The project is to fire a beam at a piece of geometry, and have it fracture at the point of impact, like a simple sci fi gunshot. I have a rough idea of how to do the destruction, but which nodes should I use to cast the ray, and then find the intersection? Also how do you even define a direction or a vector to start off with? Currently I'm using a very long single-span curve, but I'd like to find a way to cast the ray infinitely. Any help is much appreciated. Thanks very much. Edited November 9, 2017 by EdArt Quote Link to comment Share on other sites More sharing options...
animatrix Posted November 9, 2017 Share Posted November 9, 2017 You can do all this inside a single AttribWrangle using the intersect() function. 1 Quote Link to comment Share on other sites More sharing options...
Jesper Rahlff Posted November 9, 2017 Share Posted November 9, 2017 you could take your position of origin (where you want to cast your ray from), and subtract that from your target position in an attributevop and then use a bind export node to export your newly crafted vector as an attribute. (lets for the sake of this example call that attribute myattrib). you then have quite a few options on how to get your origin point to the position of the intersection position. the most straight forward to understand I believe is using the Ray node. The Ray node takes points to ray and some collision geo to ray onto. you can then specify how is should find a direction to cast the ray, and because we created a vector named myattrib (which holds the distance and direction to your collision geo) I would suggest that you use that. if you wanna go the attribute wrangle way this would be a good place to start: because we have crafted a vector which we exported you can in an attribute wrangle do the following: v@P += @myattrib; hope this helps. 1 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.