Houdini Engine V2 - Procedural Rope Bridge

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
alrighty guys all right so in this video we are going to walk through the creation of this procedural bridge here for houdini engine version 2. we're going to cover things like how to create these handles right so you can offset the two sides of the bridge and place it wherever you want it's basically you know the entire placement of the bridge itself lets you you know put it on any angle or anything like that everything updates appropriately all procedural let's actually make it a little bit longer now there we go yeah and we're gonna go walk through you know all these different global parameters here we have the ability to you know change the overall look of the the hang shape here that's what i called it all right you can change you know things like the the bridge width overall um we have our lower hang intensity here all right which is separate from the upper hand intensity i usually keep that a little bit like that and you know we have control over just about every aspect of this we have you know the scale seat here changes the overall min and max scale we have our removal weight so we remove lots of playing so we can basically add them all back in yeah we have control over the rotation individual scale lots of cool stuff in here now we have the posts one of the coolest things here as i go through the technique about how to create the proper vectors for you know creating these these angles here so this is kind of like the x spread and the ropes all follow appropriately then we have the z spread so that's how far they lean back how far they go forward stuff like that and uh we have stuff for all the ropes and the tie downs here which are these guys and then finally i cover um how to procedurally lay out all your uvs inside of houdini so we get a pretty good overall you know layout for the uvs and that is not that is actually this guy now this is kind of a quick test using just the uv layout node and i really just wanted to do it to show you how to organize and how to use this to layout uvs into specific shells i'm going to do a follow-up on this and show you guys a better way to do that but it's good to understand how to use that uv layout node in a very custom way it's it's just a performance hog and so uh i have to do something with vax instead but we're going to cover all that stuff so let's get started all right so let's get things started with our rope bridge by creating a geometry container i'm just going to make this a single geometry container i'm not going to do a subnet i don't really need multiple parts inside of houdini engine for this you can if you want i'm going to call this ip rope bridge i'm going to call this video because i have another one going all right i'm just going to right click on this create digital asset you're more welcome to also use the version digital as i'm just more used to doing this all right so i'm going to put the name space on it and then put a version number at the end here like so and i usually go and capitalize these guys all right so then we want to go and save this i'm just going to save it next to my hip file my hda folder you're more than welcome to save it wherever you like then hit accept destroy all spare parameters because we don't need them and then let's go and hide all of our default parameters here because we do not want to see those guys alright so the first thing i'm going to do is create a folder i'm going to call this the handle or point handles folder because i want to set up some handles for this inside of the houdini engine so we can drag around the two endpoints of the bridge all right and so i'm just going to call this handle points for the actual label and then we need two uh float vector threes because we're controlling two points uh in an add node so i'm just gonna call this va for point a and give it a label of point a and then we're gonna do p v for point b like so and now i need to make sure that i initialize this and it's it's important to do this because if if you don't do this then your points are just going to end up at the center of your hda and that's just a little jarring for level designers when they first place the hda into a scene so i'm going to initialize it to five and negative five hit apply and then let's go set up our handles now so to do that we go to the interactive tab into the handles tab here and then we want to go and create a handle and the one that we want to use for this hda is the transformer so the last one in the list here and i'm going to give it a name of point a and then we need another one so let's create the handle for point b so say point b and then we need to connect them to our parameters right by themselves these particular handles don't do anything they actually need some sort of binding to some parameter on your hda all right so that's why we created these float threes first so select your point a x form there and then score all the way down to the bottom of the list here all right and we're looking for these t x t y and t z's these uh bindings and so we can do is click this little drop down over here and go find our point a x all right so we're going to control the x position with that and we're going to control the y position and we're going to control this z position so all components of that vector cool make sure you hit apply and then let's set up the point b over here so again you want to go to your tx and bind it to the pbx like so and t y goes to the pby do that one more time there we go and just drag this guy all the way to the bottom and then finally our t y or t z sorry goes to r p b z hit apply and accept well we don't really need to accept unless you want to get rid of the type properties window you can always leave it up i'm gonna accept because i only have one screen for the video all right so let's um drop down an add node after diving into our hda here and let's go ahead and create two points and then check them on so we actually have them so that creates two points in our scene view here now what i want to do is i want to connect them to those two float three or vectors that we created on our parameters so a quick way to do that is just right click right here on your hda go to parameters and channels and go to parameters there we go and then it makes it easy for us just to copy the parameter and go and paste it over here there we go so paste relative reference cool so now you can see those points are spaced out there one last step for this particular process to go to the polygons by group tab on the add node here and that will create a line for us so now we have a primitive or a curve awesome so with that all set up you can see now if i hit enter so if i just go up one level and then select my hda hit enter on the keyboard you can see now our two handles are driving the positions of those two points that's exactly what we want to do and these handles then get displayed inside of the houdini engine for unity and for unreal so now we actually need to do something with this so i what i want to do is create the kind of hanging shape for the bridge here and so to do that first i'm going to create a resample node here like so just wire it in i'm going to set the length to something like 0.5 you can set it to whatever you want we're going to be adjusting this later on and then for the attributes i want to turn on the tangent attributes here and rather than the tangent u i want to send that into the normal and you can see that that actually creates our flow normals for us as well all right so with that done i'm going to create a subnet now drop this down and this just helps me keep my systems contained so it's easier to manage the hda or your network i'm going to call this the bridge shape like so go all right i'm going to dive inside and let's go now and drop down a null node and i really do this is actually that important i do this just to give myself some information about what's coming in all right so i'm going to select those guys hit shift l on the keyboard just to organize them and really that's just my ocd coming through you don't have to do any of those those steps there it's just what i do whenever i start these things all right so let's create the kind of the droop shape so i'm going to get our wrangle node here and i'm going to call this the hang shape perfect all right so then let's go in here and start typing some vex so this really pretty easy i'm going to say at p dot y so the y direction of this guy we're going to droop all those points based off of some curve so i'm going to say is minus equals to our course to ach ramp and we'll call this the hang shape like so and we're going to use the f at curve u value so that value that we created from the resample node all right so then to expose that ramp so we can control it we just hit this little button over here and that now allows me then to control my bridge but i want this particular shape to be that droop shape and i want the curve to look like this so that means we need to do a one minus here like so cool so with that done then i just need to go and select all the points holding down control on my keyboard and selecting all those little handles there and set their interpolation type to b spline that will give you a really nice curve so it would also be nice to have control over the intensity of this this sag or this hang so i'm going to put some brackets around these guys and we're going to multiply it by a global value so we'll call this intensity like so and then expose that slider so now we have control over that intensity so i'm just gonna droop it down just a little bit more cool all right so now we got that all done uh you'll notice that our flow normals aren't uh set and you know when you start doing this the lengths of these particular segments are different so we should just drop down our sample node anyways and resample it again and we'll do 0.5 and we will just regenerate our normal and our curve u values so now we have those flow numbers there all right and then what i need is to create my other vectors for my curve directions so i'm going to call this dirs and i am going to then use a preset that i have so this curve there so i'll let you guys take a minute and just copy that code down basically what we're doing is we're taking the current normal we're flattening it in y right now we're doing a cross product to find the right direction and then we're doing another cross product of the normal and the right direction to get the uh the up vector and you can always view these um if you select the node and uh hit x on the keyboard to visualize your directions and then you can go to the visualizers tab here and we just want to pick the class so this is all the points and we want to get the right or we want to view the right we want to set the type to marker and then the style to a vector that allows us to view that particular direction all right so it's always good to give these guys a name so i'm just going to call this rights and write and then uh we can just duplicate it all right so now we have two visualizers in here so i'm going to go to right two and i'm going to call this up and up and this will be up and that should have shown us the up vector oh one thing you need to make sure is turn on the active sorry about that all right so um yeah and then you can colorize these if you want so we go back to the right one and make it red those are the standard colors there so yeah now we have all the vectors we need to then pump into a sweep node so let's drop down a sweep node now and in this case we'll just use the ribbon operation because that's really all we need we will turn all these primitives into planks here pretty soon so we don't need any columns here and i'm just going to set the width to a value of 1 just to keep it normalized for now into a unit all right so it's looking pretty good i don't need that visualizer anymore you can always just keep it off to the side it doesn't hurt anything all right and then let's just drop down our output node so houdini ninja knows exactly what to output beautiful so let's uh hop up and out there select our hda and then just hit enter on the keyboard to expose our handles now you can see now we are controlling that so the next thing i want to do now is take this hda let's make sure we save it and i'm going to hop into unreal all right so here i have you know the quick example i'm just going to delete this one out of there um and so now i want to just point out that i'm actually using a houdini engine version 2 here so you have this new menu over here so make sure that you get the latest version i'm also using houdini 18.5.492 i believe it was 492. so it's the latest and greatest uh it's from the daily builds as well so this isn't the production build all right so let's go now and get our hda that we've been creating so i'm going to go to hta and i'm just gonna drag and drop it into my hd folder here inside of unreal perfect now we can just drag and drop it into the scene and bring that up there and you can see our points actually did end up in the middle there which is weird those defaults should have worked again this is houdini engine version two so some things are still a little buggy though it it's actually pretty functional so yeah there we go so now we got two handles that allows us to control the bridge and where we can place it awesome so with that done let's now focus on actually building all the bridge parts let's now focus on creating the wood planks all right so what i'm going to do is i'm going to be using the center of each one of these primitives and placing a wood plank onto those points because later on we're also going to want to just instance some sort of parts onto it so i'm going to go and create a new subnetwork here and i'm going to call this build planks like so and let's just take the geometry that's coming out of the subnet where i can pump it into the first input there all right so let's go and get this set up here and this is just going to be geo in and go and organize those guys otherwise it bothers me all right then i hit shift s on the keyboard just to get the wire design there okay so first thing we want to do is create the center point that we're going to copy on to and so to do that i'm going to use a wrangle node here and so i'm going to call this create center point like so and to do this it's quite simple we just want to run over our primitives so each primitive here and i just want to go and add a new point so we say add point we want to add it to the incoming geometry or index zero so the first input here and use at p so at p in the primitive context is the center of the primitive so if i hit w on the keyboard you can see that we have a point now in the center of all those primitives so let's just get rid of the uh primitive here and we're going to say zero at premnum so the current criminal that we're working on and then one to remove all the associated points with that primitive so we're left with just these points so then we can use an add node to turn that back into a curve so we can do stuff with it so we just do the pi group and there we go so now we have all that back as a curve pretty cool really a quick way to you know get a center curve out of all your primitives all right so then with that let's uh create our flow normals again so this time i'm going to use a poly frame node and uh just for the tangent type in n so now we have our flow normals you kind of see them they're pretty small you can always change the size of these if you just go to um your guides and just set the scale number to one there we go cool and then uh let's do our directions so again i'm just going to use my preset that i have i'll call this nodes just to give myself a little more information and then we'll just drop this down and get the curveder code like so all right so now we've got all that stuff set up and uh if we were to go and copy our visualize node from our shape sub network there and copy it we can verify that we have all of our vectors that we need cool so with that um let's go and create a box we need to actually create the geometry for the plank so let's take a look at this guy go back and do my shaded view hitting w on the keyboard now for the size and x i'm going to keep this at 1 because remember our geometry coming in is a width of 1. so we'll control all this stuff here pretty soon with the our parameters so i'm going to set this to a value like .05 for y and then remember our z length is actually that resample length right so up here when we resample our z length is 0.5 each one of these segments is roughly a length of 0.5 so in our z we can just type in something like .4 just to make it a little bit smaller cool so let's turn that guy on there and uh let's give this a little bit of detail for now we'll do something with it later on so i'm going to do a poly bevel and let's go and hook this guy up here and let's just add a little bit of a bevel here it won't need much because it's such a small object and you know i want to randomize that bevel so i think what i'm going to do is uh convert the box over to polygon mesh and then in our poly bubble node you notice we're getting bevels for everything so if we go to the exclusion uh drop down here and set our ignore flat edges you can see you can have control over when it does an actual bevel based off of that edge angle there cool so then i can use a randomize attribute randomized node and we can randomize this so i'm just going to call this bevel and i'm going to set the dimensions to 1 because we only need a single float value and it's going to go between 0.5 and 1.5 or random value between that so you can see in your geometry spreadsheet here now you have these bevel values all right so then in your poly bevel node you can actually go to this little drop down for the distance and say scale by attribute and then type in that bevel attribute and you can see that our bevels are all just a little bit different and then you can go and control you know that offset there make it bigger yeah it's pretty cool all right so then we can go and copy this to our point so if we just drop down a copy to points node just feed these two nodes in to that guy there we get our geometry copy to those points pretty cool all right so with that done let's now go and i'm going to drop down an assemble node because i want these guys to have a random color and a quick way to do that is just create this name attribute so if you notice now in your primitives in your geometry spreadsheet we have this piece attribute so what i can do with that is i can drop down a color node here and randomize the color based off the primitive name so we just drop this or change this to random attribute random from attribute and we want to do the name you can see now we get a random color all right so now we've got a random color what i can do is actually change that into a grayscale value that we can use as a blending value so i'm going to do i'm going to call this my value remap and in this particular wrangle node i'm going to roll over my points which means i'm going to have to actually do a promote here so let's do an attribute promote and promote that color value from primitives to points so let's go from primitives to points color value so now you can see we don't have any color on our primitives but we have it on our points over here the point class so let's do that it'll just make it easier in this wrangle node to deal with so we're going to say at cd is equal to and i'm going to clamp it first and then we're going to make it equal to a ramp value and that name of the ramp is going to be called value remap all right because i want to remap some value and we're going to say rgb to hsv this will allow us to get the value from one of the channels so in this case i'm going to do dot b the blue channel we're going to remap that between zero and one like so and then turn on our or create our parameter here so now we have the ability to you know remap our values so you can do you know different things with this just give a little bit of variation there you can always go to the color node as well and just change your seed value so you can promote this to get different looks awesome all right so let's now go and create a color and this is going to be basically the base color of all those planks there so i'm going to put it on the point class very important to take note of and you know that default value is usually pretty good so this little swatch right here is usually pretty good wood color just for these debug type meshes at least all right so then i want to do a a blend all right and i'm not going to use the labs nodes just because it's always good to learn how this stuff is actually done so i'm going to call this blend colors as a technical artist it's important to actually know how these things are done and not become super reliable or reliant on the labs notes all right so let's do other color i'm going to go and extract or get the color from the second input here or index one so our grayscale value and that attribute name is cd and we want to get it from the pt num to pt num because the point numbers are the same for both both of these meshes all right so then let's create a white color so we're gonna say vector white is equal to just one one one like so then i'm going to do an at cd times equals so the current color coming into this first input here which is this color that you see on the in the scene view and we're going to do a lerp and i'm going to alert from my white color to the other color and we're going to create a blend float value so i'm just going to call this blend like so and with that let's make that spare parameter and now we can blend in that grayscale value to get some variations there very cool all right so let's go now and just to organize this up so i just select all these guys hold a on the keyboard and that basically organizes them for you nicely again you don't have to do that i'll just nitpicky that way just let them keep these guys organized makes it easier to read all right so now we've got our plank so let's uh just wire that into our output now and let's save our hda and let's go back to unreal and you can just select your hda that's in the content browser here right click on it and say rebuild all instances and there you go so now we have our planks and that's all working awesome so far so let's uh make sure that we save our new asset there and uh let's focus on creating some parameters now that we've got quite a few things that we can control here we're going to add a little bit more variation as well to our planks so let's go back to houdini over here and get that done all right so let's dive back in here and let's open up our type properties and start exposing some things all right so uh the first thing i want to do is go and make this guy collapsible so i hit apply you'll notice in unreal here it's a tab and i really don't want that so i just want to make that collapsible which is supported now in um or h engine v2 which is great so the next thing i want to do let's make another collapsible folder over here so i'm going to call this the planks folder for now might change do planks let's make sure we put the s on there again i'm going to make it collapsible so apply all right so what i want to do is um actually just promote this length value so i just do an alt middle mouse click and that will expose it to your type properties but not only if you have this open and the default will be 0.5 which is working pretty well and i want to set a couple other things so i'm going to call this plank's width actually or maybe it's not so much width it's actually more of a depth so we'll just call it the planks depth and zero to five might be a bit much we can do you don't definitely don't want zero so let's do point one uh to two i think we'll be fine i'll just lock those guys out so let's hit apply so now that we've done that we need to make sure that we copy this parameter and make sure we propagate that down to this other resample node here right because i want those two to be the same values for this whole thing to work so again let's test that out before we go too far so we're going to go to parameters go to our planks and now we can control that plank value one thing we do need to do is actually also let me get rid of that guy there we also need to then put that on the box as well for the z value over here and then subtract 0.1 from it basically so we could we could always paste that relative reference or you could just reference this planck's depth right so you could just do ch two quotation marks uh go up a couple levels there and we want to get this uh planck's depth value then we're gonna subtract 0.1 from it all right so let's test that out again i'm going to go and select my parameters here yeah so now the planks are accommodating that new size which is good and you know even i think we could just keep this to like one two i think it's too much let's actually just put this little one there awesome apply and accept let's get rid of this uh the other thing actually i do want to promote that width so let's go to type properties here let's make a another folder here we'll call this our global folder these are things that are global to the whole bridge so in this case the bridge width all right so let's go up one and in my resample that's where we have the width value we're actually not the resample it's in the sweep node here let's go to the sweep node this is where we're controlling the bridge with so again alt middle mouse click to send that value over here and we can call this bridge width now you don't have to go and rename these but it's a good idea to give them custom names for sure and so we definitely don't want zero point or we definitely don't want zero we want something like 0.5 for the minimum and the max maybe five and that's all in meters so just keep that in mind so maybe six feet is enough so two all right i'm just going to pull this off to the side there let's see here let's go and test that out now let's go to our parameters and we also need to make it collapsible so let's go to global collapsible apply there we go so now we have control over that width of the bridge let's make sure we go and view the final here so now we have the bridge width again the planks aren't updating because we are controlling it through this box here and so we can now just get our bridge width here copy parameter paste that in for the x size so now we have control over that and our depth of the blinks yeah cool all right a couple more things i want to do for the planks here let's get rid of that guy there i want to actually make it so you can remove a certain amount of these guys and so before we go and create the center point let's remove just do like some sort of weighted random selection and remove a couple of planks from there and to do that i'm going to drop down an attribute wrangle node and we're going to do a rand selection here and again i want this to be a weighted selection so we have control over how much is removed so i'm going to create a new variable called weight and this is going to be tied to a float parameter called weight as well there we go so let's actually promote that and let's just default that to 0.5 so basically half the prims will be removed and so i'm going to do another float called rand val and that is equal to rand at prim number so we should actually be running over primitives in this case and then we want to do a seed value as well so we're going to do a seed value there we go and then finally we're going to say if our rand val is less than our weight in this case i'm going to mark it for removal you could also just remove it here so we could just do a remove trim we could say at premium here and one to remove all the associated points and let's go and do that there and it looks like it is not wanting to do that for me so let's try a different approach here that should have actually worked but i'm going to verify this by doing an at group and then giving it a name we'll call this um remove and that's equal to one like so so now let's take a look at our primitive groups here and yep primitives and it doesn't look like yeah we're getting any selection here oh there we go yeah so now we are let's uh test that again there comment that out oh it was working that is weird it just wanted me to select it i must have the display flag somewhere else all right so now we have you know a weighted approach to removing stuff instead of it being completely random and we have a seat value so we can change it so really cool stuff yeah so now our whole system still works because we're just removing primitives right so now we have our planks in that place we should actually add a normal node here for this as well and just put this all the way down yeah much better all right so the next thing i want to do is go and promote some of those attributes now that we have so let's go and into our type properties and let's go into our planks folder and let's um promote these two guys so let's just promote that alt middle mouse click to promote the seed value i'm going to call this my remove weight and removal weight like so we'll call this the remove seed value and our removal seed something like that and for the c value zero to one will be fine it's pretty touchy and then for our removal rate zero to one is actually all we want for that set apply and make sure everything's working so let's go and display our parameters here and yeah there we go very nice cool so the next thing i want to do is focus on some random rotation currently these guys are all super straight and that is a dead giveaway that this is a procedural asset and so i'm going to go and use a wrinkle node for this i do like to do the wrinkles so we're going to do rotate for the name there and i'm going to create a new variable called max angle so this will be the maximum rotation that the plane can actually achieve so let's do max angle here and then let's do float rand val and this is going to be equal to rand at pt num because we just need some random value to randomize the rotation so that goes from zero to one and then i need a float angle and this is going to be equal to radians and we're gonna fit our rand val between our maximum a minimum or so i should say the max angle but negated to the max angle so anyways let's actually do it and so you guys can see so we'll say negative max angle to max angle like so and it needs to be in radians uh for the quaternion to work so let's do a float four or i'm sorry vector four there we go i'll call this rot and this is going to be equal to a quaternion and we'll give it that angle and at up like so and i forgot to type the whole thing i was getting ahead of myself and there need an n there we go so finally then we can just apply that rotation to our normal so i can say q rotate and we'll do the rot and at and like so so let's expose our max angle value and so now we should have control over the angle there it looks like oh there we go i just need to do a little bit more there so yeah now we have a little bit more control there it just makes it look a little bit more natural i think i'm going to put it on something like four as the default yeah much better cool so with that i think i'm pretty happy with that let's um expose that rotation value so let's get this guy here just do a middle mouse click or alt middle mouse click and we'll call this our max angle yeah max rand angle how about that do the same thing up here we might want to put planks in front of that as well because we might have another random rotation and this needs to go from yeah zero to maybe ten that's the max cool let's test it out there we go now we have a little bit better control there very nice all right so let's jump all the way out let's just make sure we save you can always if you are on your network you can always save from here as well just by right clicking this guy all right so let's save it and we'll go back to unreal here and let's do a rebuild all instances and there we go so now we're getting some cool randomized features which is awesome yeah to change the bridge width and we can change that depth there as well i actually kind of liked it a little bit skinnier that's nice and we can change our removal rate or weight there we go in our rotation so we are on our way all right so now that we've got all that done let's focus on getting some of the core like ropes and stuff like that in place so now let's uh focus on building the the post at the end of the the uh the bridge here and i want to have control over basically how far out you know how far they're leaning you know in the x direction and how far they're leaning in the z direction all right so let's go take care of that i'm going to double click this guy to dive inside i'm actually going to move this guy off to the right here or off to the left there and i'm going to call this out planks and then i'm going to create a new subnetwork here and i'm going to call this guy buildbridgevectors so in order to put these uh posts on here we actually need to build up some vectors some very custom vectors so we're going to be doing some quite a bit of x here to get this going and so and this is again just one way to do this with as with anything houdini there's tons and tons of ways you could accomplish the same thing you could probably do it all with nodes i'm just you know more comfortable with the back cell i'm going to call this null node geo in all right and um first thing i need to do is turn this into two curves based on the the borders here of this particular piece of geometry so um on that add node there i'm just going to delete the geometry but keep the points and turn on the bi group and then just set this to skip every nth point and that basically gives us the two side curves which is perfect there and then we need our flow normals back so we just use the poly frame and in this case um what we can do with this guy here is whoops i went into the wrong one there but basically what we can do is we can actually set up you know most of our directions just with the polyframe node so let me uh dive back into here for you guys so all i need to do is just um on this polyframe node turn on all the options here and then we're going to do a write and we're going to do n and then we're going to do up for this all right so we should probably take a look at see what the result of that is because it's not going to be perfect right away so if i just select my polyframe node and do a x or hit x on the keyboard let's set up our right you could always go and copy let me just do this one more time just so we beat it into your brains so i'm gonna set rights and we're gonna set that as a marker and we want that to be a vector so you can see what we're gonna need are the um these vectors so they're facing away from each other at least that's what i did i'm going to color this red and then make a duplicate of it and go to write 2 make sure it's on type in up for the name and label and then up for the attribute that we're using and uh yeah there we go so now we got it so that one's pointing down so we need to reverse that one so um there's a few things that we need to do in order to get these guys all set up so the first thing that we can do globally is drop down a wrangle node and just reverse the up vector so we're going to say reverse up now you could do with a wrangle node i'll show you another way here in just a second so i would say v at up is equal to negative v add up and uh let's wire that guy in there so now those guys are pointing um the opposite direction and so you could also use a point expression node here as well if you don't want to type of course i mean this is just typing backs as well um and so we would have to put in the custom and do up and then set it to negative add up like so and you get the same result right so just a couple different ways to do that right i find that just to be faster using the angle node again it all comes down to what you're comfortable with okay um and then with that let's uh split these into two curves so we can work on these guys uh independently the two halves independently so i'm just going to split on zero all right so that's primitive zero and uh you know that by turning on this primitive number display so let me turn off my point numbers right so there you go all right so now i've got primitive zero coming out this guy and primitive one coming out the second output there so that way we can start to work on this uh work on each one individually so let's uh just drag the visualizers so we can see what our current setup is now what we need to do is actually reverse the uh the uh right direction here so let me type or drop down a wrangle node here and i'm going to call this set adders and groups there we go so the first thing we know we need to do is just reverse the the right direction so v at right is equal to negative v at right there we go and we'll just feed that guy into there cool so now that's set up appropriately for us and then let's do a couple things uh for the end points here right so let me turn off my printer numbers and turn on my point number so we want to do something on the first point on the last point here so i can actually do that by just looking at the point number so i can say if uh pt num is equal to zero then you're the starting point so i'm going to put you in the group and say i at group start is equal to one and else actually we could say if at pt num is equal to the number of points coming in to our first input there minus one that means you're the end point so i'm going to say i at group end is equal to one all right so now we've got two point groups set up start and end right so there's our end there's our start you can see i'm highlighting here all right so now we've just done that and did it all inside of single wrangle note rather than using a group by range and trying to sift it all out or sort it all out all right so then on the first point what i want to do is i want to set the up vector actually i want to do this for both so i want to say v at up is equal to 0 1 0 so just up in the world space there there we go right because we're going to be copying posts to these points and the rest of the points are basically going to be used as like as rope all right so these guys need special normals and vectors in order to be able to copy the post appropriately cool so then i need to flatten out the normal so i'm going to say at n dot y is equal to 0 and i also want to normalize it just to make sure it's a unit length there so say normalize at n and we want to do the same thing down here but we also want to reverse the normal here so let's just paste in that code and then before it let's uh actually reverse it needs to go the other way there we go yeah so now we've got the end here pointing the opposite direction as the start point cool so with that done now we need to basically set up the the vectors here so that we can control how far it's leaning in z and how far it's leaning in x so let's uh drop down a wrangle note here and uh we'll call this post angles like so and i'm going to make it so that this guy only runs over our group's points right so that way we're not running over every single point which is great so then let's set up two float parameters so one for angle x that's going to be equal to radians because it has to be in radians to do the quaternion rotation and so we convert the degrees and the reason why i do that is because when you go and put this into houdini engine end users or level designers who are using your tool they're used to you know thinking of rotations and degrees right so we want to convert it back to radians just so it's easier for the end users so i'm going to call this post angle x and this one's going to be z like so because we're going to control those particular rotations so i'm going to say if this particular point that we're working on is in point group end so we're going to say 0 for the incoming geometry n for the group name and the current point number right because we want to treat both the end and start differently but we won't we want to work on all of those guys in the same wrangle node so we both we have both the end and the start groups coming in so i need to write a little bit of code to basically decipher or to kind of partition up where the code goes all right so let's get the other one set up so we just need one more if statement here set up and this one's going to be working on the starts cool there we go so if to commit code you might notice that i'm not really you know clicking out of it there very much while i'm writing code i just do control enter when i'm done and that basically commits the code and then let's uh houdini cook the wrangle node without me leaving the uh the editor here all right so let's create a new quaternion and so this is going to be rot x and this is going to be equal to quaternion and we want to use angle x and we want to rotate on at n so that's our main pivot basically and so then we say b at up is equal to a q rotate and we want to use that raw x quaternion in the v up as the pivot as well so now let's uh expose that there and let's actually visualize this as well as we're working on it so we can verify so let's type in something for like 10 yeah so there you go so now we're rotating this guy so this is basically controlling that x lean cool uh and then we just need to do the same thing for the other side sort of the start but we just need to negate the uh normal for this guy cool so now we have control over the both sides are the same you could always you know add a little bit of noise in there too if you want them to be a little bit different i'm not gonna do that um in this video at least all right let's do a vector four and this one's gonna be our raw z there we go and that's going to be equal to a quaternion as well and this time we're going to use our angle z like so and we are going to do a v right for the pivot and then our at n is going to be equal to a q rotate and that's going to be rot z and n so you probably see a pattern here when you're dealing with rotations uh custom rotations here you just build the quad journey and then use q rotate to rotate the normal that you want all right so that looks like that needs to be negated yeah because i want positive values so i want the end user to always put in positive values and just take care of it in the x code right so i'm going to do a negative angle z for this guy yep so now it's always positive and so that's controlling that z lien all right so let's copy that code there and let's paste it in right here and then let's uh remove the negative so now they should be yeah so if we did that you can see we are leaning perfectly on the both sides all right so with all that done we just need to go and copy this to the other side that's why i'm splitting it up because each side needs a little bit different of the treatment so for this particular side we don't need to invert the right so let me actually visualize all this stuff so you guys can see uh we don't need to convert the right or reverse the right on this side uh it's already fine so that's fine there cool and you can see that our angles are going in the wrong direction here so um let's just do this all we need to really do is go to this post angles wrangle node copy the uh parameter for our angles we just need to negate them so let's just copy the post angle x and the post angle z there and just paste them as a relative reference and then negate the value so now we have a way let's actually merge those together together so let's do a merge here and visualize our vectors here so now we have a way of just using these single values here to rotate perfectly on both sides yeah and we can always drop down a box here just to test this out so let's do like .251 and .25 and i'll use a match size node and we'll do a min for this so it just sits right on the ground there and then we'll drop down a copy to points node like so and the target points we want to set up as our end and our start there you go very cool let's turn off all of our component displays and test out our values here so let's test out our lean to the z yep and our lean to the x looks good all right so we are good to go let's actually um let's get rid of this test post because we need to set up something a little different for the final posts but we had to do this part we had to get all of our vectors set up so let's just get this organized here so i can be happy there we go cool we are now set up to basically build the the rest of the bridge so with that uh let's move on to the next section all right so what we're gonna do now is focus on uh just building out the official posts here now that we've got all these vectors built for us so i'm just going to move this over to the side here and we're going to drop down a subnet and i'm going to call this build post we're also going to do all the rope curves in this node as well because i want to show you guys you know setting up the multiple outputs in these subnets as well so it's always good it's a good thing to know so i'm just going to get this set up here i'm going to call this that curves in and hit shift s on the keyboard to get my wire design cool so with this done um what we can do right off the bat is start to build the post itself and to do that i'm going to actually this time rather than using a box i'm going to use a line and i'm doing this because i want to procedurally generate the uvs for this so we're going to approach this a little bit differently and i'll most likely update the wood planks as well so to do this i need a line and a grid so this grid is going to serve as the profile that we feed into a sweep node and so for this grid here what i want to do is i'm going to set this up to i don't know something like 0.15 and let's actually just copy this over here and paste it over there so then we just have the one value to adjust let's do a spacebar g on the keyboard and we um then want to get rid of all these extra subdivisions so we'll just do two and two for the rows and columns and the grid there and then uh what i'm going to do is drop down a poly bubble node here because i want a little bit of bevel on the actual profile there so i'm actually going to switch this over to points and we're just going to bevel the edge there something like that that's good for now and then let's drop down a poly frame node so we can do our flow normals for our line just so the sweep node works appropriately all right there we go and then let's do a sweep node and let's speed these guys into there like so and it looks like we need to orient our grid so let's do that and put it on the x y plane awesome there we go so i think i'm actually going to make this a little bit tinier because in the sweep node we can go and apply scale along the curve and i i want to taper this a little bit just give it a little bit of a stylized look so there we go actually felt pretty good there all right so leave it there we'll have to expose those guys to the hda parameters here pretty soon inside of the uvs and attributes tab i want to go and compute my uvs so i'm going to save my scene here and hit 5 on the keyboard to go to the uv view and we're going to take a look at this and i don't want to normalize this and then for the seams i don't want to snap to the nearest tile boundary i actually want this to be you know the same exact size as it is in 3d space okay so there we go now we have you piece awesome so you want to go back to perspective view let's now take care of the caps all right so we need the caps up here and uh that's another reason why i'm also you know producing it this way because then i can uv the caps independently all right so let's do a poly cap node there we go and we are going to need the patch one thing i should note you'll notice that this is just a polyfilled node even though it's a selection in the the node library as polycap it's really just a polyfill node that just has a preset on it right so you can actually set this up yourself it's just a single polygon basically it's all that's all it did so i just wanted to point that out all right so we need to produce that patch group and what i'm going to do here is go and split off the patches or the caps all right so i'm going to select the patch group and invert that selection so now we have the patches coming out of the second output here and i'm going to go and blast away a primitive zero so if i were to put the null node in here just so you guys can visualize this and turn on your primitives uh you can see we don't need the bottom one and it's always going to be on the bottom there so let's remove primitive zero so let me get rid of that guy there we go so i don't need this null node anymore excellent let's drop down a poly extrude node and let's give it a little bit of height and a little bit of inset as well so just a little bit and then a little bit inside yeah cool all right and then finally we need to generate some uvs so let's drop down a uv project node all right and uh with the uv protect node selected hit enter on the keyboard to see the projection plane so all we need to do is just do a negative 90 here and uh we now have uv's all right because we're working in the center of the world this you know works completely fine we're going to move it and copy it to points later so let's merge together the post now and the caps so now i have uvs for these guys which is great awesome so with that done let's uh now go and um i'm actually going to put this into subnet so i'm just going to do that we'll call this a post just keep things nice and organized in here and i want to then copy this to the point so we're going to do a copy to points node and we're going to feed that guy into the first input that guy into the second input now right off the bat you can see that we don't we only want to copy to our start and end groups so for our target points up here let's just do end and start there we go so now we've got uh some posts beautiful all right so one thing that we're going to have to do because now what i want to do is focus on the the ropes so currently we have the bottom ropes already created or at least the curve for the ropes i need to create that top curve as well so what i'm going to do here is i'm actually going to go back into the post network here in this sub network let's organize these guys by doing a shift l on the keyboard what i need to do is actually include the line in here as well right so that initial line because this represents the height we might actually carve it a little bit so the the top rope actually comes out a little bit lower than the top of the post itself so let's go and get an object merge node here and i'm going to call this get line and uh let's go now and just drag and drop that into there set the transform to none because we don't need to import any transformation information so now i've got the line over here so let's carve it first so we have control over the placement of that top rope and you'll notice that it's actually carving on the bottom there so let's do the second u and we'll just yeah pull that down just a bit excellent so i need two groups now so the first one is going to be um our post line that's what i'm going to call it and it's going to be primitive so it's just going to select everything this way we can separate it after we copy it to the points from the actual post geometry and then the second group i'm going to create is a group to isolate out just the top point there so i'm going to call this my top point and set the group type two points and put in base group of one right because if you look turn on your point numbers you can see we have zero down here and one up here i just want to isolate that out so i can also blast away point zero excellent um and with that we pretty much have everything that we're going to um need i believe for this so let's merge these two guys together and put down another merge node just merge these guys together and then we'll output that so we have a line right in the middle there that's going to get copied onto those points so i'm going to do an output node down here there we go excellent so now if we look at our copies and go into wireframe mode by hitting w on the keyboard you can see there's a line in the middle of each one of those posts and now we can do is separate that stuff out so i'm going to go now and do a split so i can split away the post geometry from those lines so i'm going to do a post line so that gets me the lines i'm going to invert the selection and if i put a null node down you can see now i have the post geometry on this side and i have the lines over here which is perfect so now all we need to do is just blast away that bottom point like a soap all right so let's do um top point and then just reverse it so we get just those top points there and with that we can then use an add node so if we do an add node and we set this to skip every nth point i believe let's do our groups of ends points so we don't need to delete geometry let's just go into our polygons tab go to by group there you go groups of endpoints perfect and with that we can now go and resample it and on this resample node let's include all the data so we need to build up our directions again with all this stuff and i'm actually going to set this to that 0.5 value which we could get from our type properties so we're going to do ch and then two of those guys and then we want to do the um plank i think it was the plank plank depth yeah there you go perfect all right so with that done let's go and create our tangent make this the normal was our floor flow normals and this is our curve u value beautiful and then we need to go and get the shape as well so let's go up to the bridge shape and let's just copy this hang shape node then go back into our build post here and just apply that there there you go so now we're going to basically connect this hang shape to a single float ramp in our parameters but we can control the top value so it looks a little bit different than the bottom sag awesome so at this point i also i'm going to need to be able to determine left and right here so let's do this i'm going to make a little more space up here and create a group node and in this group node i'm going to group um just the zero primitive so if i turn on my primitive numbers we're going to group this guy i'm going to call that left like so and put in a 0 here this way you can split off and work on the individual sides when we do the side ropes all right and then we're going to actually need to do that for this side as well there we go and then let's merge these two guys together now i have our ropes or at least our rope curves which is looking good all righty and then let's now go and build our um the side ropes here sorry i was thinking about that for a second all right so let's do a resample and what i'm going to do is i'm going to for this one say that we are going to resample actually based off of maximum segments the reason why i'm doing this is because i need to have the same amount of points so i can create these side ropes right rather than a length because these two lines are curves are different lengths right so we'll get a different resample value if we use the maximum segment length all right so then let's uh do a split here and i'm going to split on left so now we have the ability to work on just the left or the right side and for this we only really just need to do an add node here i'm going to delete the geometry but keep the points and we'll do a by group and inside of here we need to do a skip every end point and if we move the slider here at some point here we'll get completely vertical lines now if you look at the number that's choosing it's going to be 1 plus this number so we can just copy this particular parameter here and paste it in for this parameter and just do a plus one so now your procedural full on yeah perfect we've got all of our directions in place looking good so let's just uh do an alt left click drag to make a copy of that guy so now we've got the right side there and let's just merge them back together there we go so now we've got all of our direction vectors all set up it's actually kind of funny that they are displaying there because i don't have a visualize node down here so this must be a a bug and who do any 18 5 all right so now we basically have all the curves uh if we were to merge together uh this node with this node yeah let's um hold on a second let's take care of this display issue here let's see if this fixes it nope let's drop down another uh visualize node now where are those guys coming from that is pretty funky let's put this into the output here go up a level there we go i just had clicked the visualization so you can always click that on if you have visualizers on your geometry all right so with that done i need let's actually cut this output off here like so and i'm going to take the post geometry as output 0 and then let's create another output node like so you can also alt click and drag this but it'll give you an error right off the bat that's because we have output zero output one and this one's trying to be output zero as well so you'd have to put this to two in this case because we have three of them now right all right so now we've got all the uh the curves for the ropes and we have our posts pretty cool all right so with that you know what i'm going to start assembling this stuff together so let's set this up before we close out this chapter or section here so i'm going to drop down an object merge node and let's drop down a null node and for this first output here we'll call this out posts and i'm going to call this the assemble node you guys probably see me do quite often there we go so i got that in there let's go and add another slot into our assemble object merge node and add our planks now so we're starting to assemble the whole thing together into one piece of geometry let's send that out to the output and uh we can also just make sure we have normals down here so for now i'm just going to make them all just completely hard angles cool there we go so now we've got that stuff and we also have the the ropes coming out of here but we need to actually create the geometry for it so we'll do that here in the next chapter let's now put the display flag on that output node and to save our scene and let's also save our hda all right and let's go back to unreal and let's uh let me get rid of my test one there and let's go now and do a rebuild all instances to update it there we go so now we've got our posts added on how cool is that there we go yeah very nice okay so i'm going to close it out there and move on to the next steps all right so let's do the ropes now so i'm going to do another subnet i do like to keep these guys pretty organized lately so i'm going to call this build ropes and let's just go ahead and get the output or the null node set up for this so we'll say out ropes and uh this is pretty cool little technique super easy nothing crazy about it but a quick way to make ropes procedurally so let's do a null node here and i'm going to call this curves in shift dust change my wire designs there all right so now we've got all these curves set up for us let's go now and turn all these into ropes so the first thing i want to do is delete a bunch of attributes off here it'll just mess with the sweep node so let's do an attribute delete and uh let's go now and delete away our current uh normal our right and our up those are the ones that will be the culprits and also we need to get rid of the texture of these because we're going to produce some uvs for the ropes using the sweep node and i've found if you have uvs coming into a sweep node already on your points or your curve it overrides the sweep node and um so it's just one of those things that you know the more experience you have with the sweep node you'll start realizing so that's why i'm doing this um up front cool so let's do a new poly frame node to regenerate those float normals for us and then let's do a for each uh connected or actually we can just do primitive right because these are all individual primitives so let's just loop over each one of those individual curves using this for each primitive loop here there we go and let's go and set this to single pass so we can just focus on the one all right so let's turn on our point display and then drop down another resample node here i'm going to give this just a little bit more points to work with it'll make the the rope geometry a little more dense but it'll look better all right so i'm going to do then a sweep node and in this sweep node where you're going to go and select the round tube so let's actually turn off our primitive display there and our point display we can actually turn on our shaded on wire to see this little better let's also reverse the cross section seams looks like it's going the wrong way awesome so instead of actually outputting all the quadrilaterals here we just want to do the rows that'll basically give us the cross sections here right and we also want to set the columns to three because i'm going to twist these guys and then re or basically turn them back into curves using the points from these these triangles and so i'm going to apply some full twists here that'll create a really cool looking pattern and so let's just start with 10 there for now so at the end of this here i'm going to go and create a new add node and we're going to do a delete geometry with key points and i'm just going to leave it that way so we get a spiral kind of like a dna sequence type thing right cool so then at the end of that all these guys should be set up so let's turn off our single pass now so now we've got you know all these guys with little spirals uh let's do a sweep note now and on the sweep node let's just do actually we need to do in the odd node we need to turn this back into curves hold on once i got ahead of myself there let's go to polygons by group and then we want to do the three or value of three four groups of end points and skipping every end point and that'll create the spiral curves for us so yeah forgot a step there all right so then let's go back into the sweep node that we created and we'll set this guy to the uh round tube type you can see we're already getting a really cool rope design that's really fat and you can play around the resolution of this i'd keep it kind of low at least for now and the res i mean the radius doesn't need to be so high which also means we need to go back up to our previous sweep note here and just drop down the radius there as well that basically controls the how tightly bound these guys are and then we can go to our twists down here and just keep upping that but you're going to notice that you're going to run out of resolution which means that you have to go and add more to your resample node and that'll get you a little bit more resolution around your rope there and some of these guys aren't cooperating quite nicely i have to find a good value there for all these let's leave it at point one for now and uh let's actually reduce the amount that we have there so that's in our build posts up here i didn't start exposing all those guys to the hda and for the twists i think i found a value of 18 worked well let's do 18. yeah it seems like it's got everybody there perfectly some of these guys are a little bit rough there so after playing around the settings a little bit i finally got into a pretty good spot here i'm still a little rough for my taste i would you know go and maybe resample the uh the sides a little bit differently maybe we take this re-sample note up here and we do resample on the sides differently do is not have the sides anymore let me get rid of that group let's take a look here so we have left patch are there any point groups i can use we can probably do something with those starting ends pretty soon let's go and then create a group then for our sides we had it up there at one point our side curves where did they go yeah they're right here so let's just group these guys and i'll call these sides and everything's hooked up just fine there now so now with that group created i can resample differently on those ones so let's try this it's going to be sample on the sides only and oops i have the group selection on there let's turn on our point display so now i should have control just over yeah that's what i'm looking for so i can do that one and then for this one we can do an exclamation mark which stands for not sides so now i have control over the resample for this one as well individually it looks like what's what we're going to need for these ropes here let's take a look yeah let's see here so those side ropes really need a lot more don't they there we go yeah so you can see it's really starting to form a nice look uh we could also twist them separately as well so let's do that as well so let's do a sweep node and i'm going to set this one to not sides yep there you go and then let's uh just move this off to the side duplicate it with the alt left click and then we'll just get rid of that exclamation mark there there we go and so i think it's just the amount of twisting that we need to reduce on these ones let's go to 10 and then let's merge them back together always lots of experimentation with this stuff but you start getting used to the techniques uh and then just customizing it for you know your needs yeah that's what i was looking for in individual control let's actually go down here and just frame all so yeah now we have control over the side twist and the top twists to get really custom looks for both let's see if we reduce now the resample i don't need as much be a lot of geometry cool so we've fixed all that there we go so now we got something looks like you know pretty cool ropes now we can also on the side ropes there now since we have a separate one just reduce the the radius of this here make it a little thinner do the same we could do the same thing down here here and do uh sides so this one's going to be not science let's actually verify that here see if the group got transferred nope all right so i'm just going to leave it like that all right you can go and you know separate all that stuff out and create different groups uh with that so at least we have some ropes now um let's color these guys a little bit give them a little bit of like a brown color yeah and let's add it to our assembly there we go boom this is really starting to come together we're gonna have to go and you know scale out these planks a little bit be cool to get a little bit more variation on that they're sitting like right on top of the ropes which isn't totally realistic that does not look safe to me it also looks like they're right in the center let's go fix that oh yeah i didn't put a match size here so let's do a match size and set the justify wide to minimum that way it's sitting on the rope yeah still that does not look structurally sound so we'll do something a little bit different here in a second but anyways you know that's a quick way to make ropes really really fast well looks pretty cool let's actually now go and save this so we're going to do a save node type and go back to unreal and always test just to make sure everything's working yep there we go it's starting to look cool it is taking a bit of time for it to actually generate the so we're going to probably need a debug display that is definitely a long cook time so let's uh do that really quickly before i close out this chapter so i'm gonna go back and do my video here or my sorry my hip file here and uh let's do we're gonna have to just duplicate actually let's do a switch here because if i just feed this in here like so i should just get ropes and actually i need to move this guy over here let's make a duplicate so that does all those guys and this one we just need to get rid of the grouping so we just get tubes which should be more performant for a houdini engine and then we'll just what we'll do is we'll add a switch here so we can switch to the final resolution i you can always go and reduce the amount of geometry too it's just taking a while for it to cook yeah i think that'll work just fine for now let's test that out so i'm going to go and save my hda go back to unreal and rebuild all instances let's test out the speed now yeah much better so we'll just expose um the toggle there so when the artist or whoever's using this particular hd is ready to bake it down to a final prop um they can just switch it to the final and then cook it from there so there we go pretty cool so now i got some ropes thanks so much all right i think it's time now to go and start promoting some parameters up here we need to make a new folder for the ropes now as well so let's do let's call this uh ropes folder i'll just give it a label of ropes like so and let's now go and promote some of these parameters here we might actually be able to speed some stuff up from a cooking standpoint all right so i'm going to call this the debug switch and let's just go and promote this so this will allow us to switch between our low-res and high-res i'm going to call this the um debug or ropes let's just do an r we'll call this debug switch and we'll say use hi like so and we'll just keep it off by default and this will be a toggle yeah hit apply cool all right so a couple other things we want to do i want to control the resample rates here so let's see this guy's .08 and this one's 0.03 all right so we'll do this here i'm going to do a separator so for the first one let's do alt middle mouse click and the second one same thing and then let's just move those guys into there and so for the first one we're going to call this the r underscore length rope or actually say length sampling something like that so we'll say length sampling and then for this one let's just actually copy this here we'll call this the side sampling there we go and uh yeah i think these guys are a little bit too much we'll put this up like 0.5 for the max and 0.001 for the min we go hit apply perfect now be nice also to have control over the size of these things as well so that's all controlled in here so we'll call this the length size let's put in another separator let's make sure our ropes folder is also collapsible and hit apply there we go all right so these are the radius or radii for the different uh ropes here so let's go and alt click that one i'll mouse click that guy and then alt middle mouse click this one we'll call this the r length radius so our length rad and then length radius and this will be the r side rad side radius like so and again put in a nice minimum value so you can't get to zero and then 0.5 for the max let's do that because if it was zero then you wouldn't see anything it just makes it feel like it's broken there you go hit apply cool you can also control the twisting and stuff like that i'm gonna leave that stuff out for now and then i think finally we just need the last radius here yeah let's do this one this will be our final radius lots of parameters here so far 0.01 and 0.5 for the max excellent uh we can also promote the color as well let's do that let's put in a separator here make it easier all right let's accept all that stuff there oh the one thing i know i i definitely need to put up there's the uh the shape the hanging shape so let's get that up there so let's go to bridge shape and in here let's promote this guy so then we have this is going to be our global so we're just going to promote that by doing an altman mouse click and then we have two intensities so we're going to do one that is the um lower so i'm going to call this the g for global lower hang val so let's say lower hang value or intensity there you go and i'll put the max to something like five and we'll do point one for a minimum it's gotta be something and then we also have the upper so if we go into our build post this is where we built the the other hang shape and now what i want to do let's actually do this i'm going to right click here go to parameters and i'm going to select my global oh i need to apply it first there you go all right so i'm just going to right click this a copy parameter we're going to connect it i want the shapes to be the same i just want the intensities to be different so let's alt middle mouse click this second intensity here and we'll call this the upper hang so i'm just going to copy these parameter names here and just change out the lower to upper there we go now let's get the label as well we'll call this upper and let's do 0.1 for our minimum and 5 for the max not that you already need it you never know though and apply and accept so those were two very important ones i wanted to get out there excellent all right so i think we're good to go let's go and actually save this now and go back in unreal and i'm gonna do a rebuild all instances there you go cool so now we have quite a few more controls at our disposal if we go to the houdini parameters let's hide the transform so you see that we actually have this really nice curve now that allows us to control that kind of global shape but then we have our intensities now where we can also increase the sag for the top and the bottom so it really allows you to get some really cool shapes there you know all procedural everything's being uv mapped so far actually the planks need to be set up for that all right so let's uh check out our use high that takes a bit for it to cook just too much geometry but it is working it just takes a bit for it to actually cook it that was looking pretty cool so far let's play around some of these parameters might be able to get it to go a little bit faster so let's just do 0.08 for our side guys there yeah those they all still look pretty good let's make the the length radius a little bit bigger let's do like .025 make it really stand out and then looks like we need to do another radius in here so if a side radius of 0.000 i don't know one five yeah those that just kind of straightens it out so you're gonna have to mess around with it yeah i'll i'll include all my updates and stuff like that in the final hda for you guys so this one looks like it needs to be like half of the length sampling yeah our length radius 3.015 it looks better it'd be also nice to get the little knots you know for where these two different rope pieces attach but i'm going to keep moving forward so there's that i'll start exposing more parameters you know the process is actually quite boring um and i i just don't think that you guys want to watch me promote every single parameter in here unless i get to something that you know is really important for you guys to see i'll put it on the video but uh for most of these guys i'll include the final hda so you guys actually have access to it and then uh you guys can see all the parameters i promoted for everything so yeah it's coming up pretty cool so far all right let's keep moving forward okay so the next thing i want to do here really quick is um actually build a better plank that has uvs and also take care of you know a random scaling of value um i also want to make the ropes there just a little bit bigger and actually i forgot um let's go into the build ropes real really quick i didn't actually oh no i did so yeah i actually just hooked this up to the length red so i can control the debug version um in the unreal engine so if i go to my parameters here and i do the length so let's go to ropes now i do the length radius that will fatten up those debug meshes yeah cool all right also allows you to see your resampling which is nice as well so do something like that see what the high looks like yeah that needs a little bit more work for sure but the technique is the same it all comes down to dialing and all those values uh you know at the end of the day you're most likely going to be using this geometry for the final game version it's just the uh high res needs to be tweaked a little bit so you can transfer it or you can just take a tiling rope texture and just you know pipe it down these guys anyways let's take care of the the new plank now so i'm actually going to just push all this stuff off to the side here make a new sub network and we'll call this plank the reason why i'm doing this is because i want some uvs um on it as well so let's drop down our null node we'll call this actually we don't need a null node for this one because we're going to be building geometry in here so all these all these guys can just sit off to the side here so i'm going to start this with the line actually so let's do this and this line is going to be set in the x direction like so and then i'm going to use a match size node to center it up in the world there we go perfect and i'm doing that because i'm going to you know i want it centered up in the world so i can copy it to the points cool so then i need my grid so let's make a grid here and let's set it to the xy plane and make the size oh let's just do 101 for now and two and two for the rows and columns so we have a nice clean grid so let's take a look let's do a poly bubble to give it some a little bit of a bevel on those points so it's just about with the points something like that and then let's go and hook up the sweep node this will allow us to then sweep that shape yeah so let's reverse it cool so yeah our our sizes are definitely a little bit off so what we're going to need to do here is actually go to our original box here and so the size in x is our bridge width and that's actually going i'm going to randomize this here pretty soon so i'm going to leave that alone 0.05 is our y size so let's go back in here and change our y size to that yeah there you go and then our depth that's hooked up to the parameter there so then let's put that in for the uh the x and that was definitely a little bit too much that's because it needs one more of those guys there you go cool so let's make their bevel a lot smaller awesome so with that all set up we can go over our sweep node down and take care of our uvs so let's do that we'll do computer vs i don't want to normalize them so let me save my scene here and um show you what's happening here so i don't want it all snapped like this to the zero to one ratio or zero to one space i want it the actual size in 3d so we got nice clean uv mapping beautiful so now let's take care of the caps doing that same technique that we did for the post so i'm going to use a poly cap node there we go and we are going to then output the patch group so we can split on that and uv just the patch sides there and also let's actually invert that but we can also use a polyextrude node to you know bump it out a little bit give it a little bit of an inset which will look nice so just go out a little bit and then just a little bit for that inset something like that and then let's do a uv project there we go now let's uh select the uv protect node hit enter in the scene view there and let's rotate the projection plane and y so we get our uvs projected perfectly cool so let's merge those two guys together put that merge node and pipe that guy in there we go set that guy up and now we have all our uvs and we'll lay these out here in just a little bit but at least they're there and i don't want to have a bunch of uv layout notes i just want to do it at the end because it's a performance hog i've noticed so let's do that so now i have a new plank geometry which is perfect and i'm going to actually yeah let's just cut this off hold y on the keyboard and left click drag let's pipe it into our match size node so it's sitting right on the grid there not in the center that way when it comes to the points it's sitting on top of the ropes all right there we go we are all set up there and we don't really need this anymore yeah i'll leave it there just for now just in case i don't want to delete all my work all right so um the next thing i want to do is you know on a per point basis i want a different size and the the width there and so to do that i need to do a for each point node or loop here and loop over each one of these points because each one of the points can have a specific random scale value that we're going to assign here right now so to do that we're going to do an attribute randomized node and this is going to be rand width scale like so i'm going to call this w scale all right and i'm going to set this to that main width so the minimum size has to be the bridge width that we set so we're going to say that's our minimum size plus a little bit extra so it's sitting just a bit over the the uh width of the rope so i'm going to say plus 0.1 and then let's do let's actually yeah let's do this let's copy this here and we'll make two flip sliders here to control we'll say plus one just to get that randomized but we'll create two float sliders for this so you can control this addition all right so now if you actually were to go to your uh geometry spreadsheet here you'll notice that we have a width scale and it's random right so on a per point basis right because in this loop here we're looping through each point we can actually extract the data that's sitting on the point there using a point expression and so to make this easier on myself i'm going to drop down on null node and this null node will just be an easy way for me to find the point that i want to extract data from all right so with that all set up let's dive back into our plank here and the thing or the node that's controlling the width of our plank here is this line node right and this is cool because um as i change this let me actually zoom out here you know the uvs are updating constantly for us right so we're constantly getting our ues generated for us which is great so i can use this value then to extract that point data and to do that we use a point expression so we say point and the node we want to get the data from is that loop point node so we say dot forward slash dot dot forward slash to jump up and out right to get up and out to here so we can get access to this node and then uh we need to say uh which point right and then we need to say the um name of the attribute so w scale and then we want to say zero for the index and since it's a float value it's just a zero all right cool so now if i were to look at all my planks we have a different scale for them all right so let's set up our type properties for this so in our paint planks not our paints our planks here let's go and add two float sliders and a separator just to make this easier for us to see and i'm gonna call this my um what would i call this planks i didn't actually do a good job naming those guys so we'll say planks and we'll call this min scale so i'm in scale for the label and then we'll do planks max scale and max scale for the label and we should go and set up some default values so the min scale i'm going to say is 0.1 and our max scale let's say it's like 0.5 and then for both these guys let's set this up so it's like 0.01 to 1. again you can always change this stuff later on so yeah let's hit that i'm going to save my scene accept looks good so now in our rans with scale here let's replace these hard-coded values with our parameters right so we say ch dot dot forward slash dot dot forward slash i believe to get up and out and then we want to do planks um mint scale yeah we go and then let's just copy this just to make it easier on ourselves and we'll do max scale there we go cool so let's save our scene and let's open up our parameters and mess around with that so yeah in our global now let's hide everything else there now we have control over that min scale and our max scale there uh we probably we can also do like a seed value as well that's probably a good idea to set up so you can kind of randomize it yeah it's already pretty wide but you can see now we can't actually go past our max our bridge width right so if we go to our global here that goes and then we have our min max scale and that basically allows us to kind of pop it out a little bit more so let's add that seed value in there let's go back in here actually first foremost let's go and uh back in our type properties and let's just create a seed value so that's in our planks so let's do planks scale seed and we'll call this scale seed and your range can just be zero to one it has quite a bit of an effect so we'll say 0.5 hit apply and accept and now in our attribute randomized node you can go to the options here this is your global seat so this allows you to pick a different you know seed value so let's hook it up to our properties so do dot forward slash dot dot forward slash and we want planks um scale seat yeah there we go so now we can save our scene save our hda take a look at our parameters here actually when you do it there so yeah now we can go and pick different ones from here i like that much better so let's uh save this and test it out inside of unreal so just select your hda do uh rebuild all instances it re-imports it then re-cooks it i do have the uh high-res i've been messing around with it a little bit more let's go and select this guy here i'm gonna switch it back to the debugs and let's just make those guys a little bit fatter too much yeah there you go cool so let's play around with our uh scale stuff here so if i pick a different c value yeah it looks pretty cool kind of like it a little bit more a little more cartoony that way you know let's remove a few more yeah look at that that's pretty cool this is starting to get quite full featured there'll be still more to do um the next thing i want to work on now is i want to add the little support ropes right so we have i mean obviously structurally you know this bridge wouldn't hold itself up unless these posts are really deep into the ground um you know usually they have like some sort of rope you know that's pegged into the ground coming off here that's helping to keep it going so i want to get that in there as well so let's do that so yeah let's go and now take care of these at least the the curve for it and we'll get some rope on there as well since we've already got those networks set up so really all we need to do is the basic idea is to get the two end points you know at the ends of these curves here make sure the normals are facing away from each other and then figure out where what the distance is from here so we could probably use a couple of the pieces of geometry we've already created so like the post line we'll get that top point and make sure that it has you know the proper normal so we can project a line outwards from it so that is what i'm going to attempt to do here in this particular section so let's uh dive inside and uh so here we have the uh the rope curve so i'm gonna need basically i'm going to need these top points here so that is coming from there oh and so let's make sure let's see what kind of grouping we have on here so all i want to do is find my point groups so i have so those guys are hosed but we have top points and it's just it got all hosed because of the um resampling right so you can see how we have the uh the groups are about halfway so that's all coming from that resampling there so one thing we can do for this this basically all the information i need right here uh we have normals but we can actually redo the normal so let's do this i'm going to show you guys a cool little trick here to find the endpoints without doing a group by range so let's do a wrangle node and let's feed that in here we're going to call this find nays or find n's i'm going to use the neighbors functions in this right now a little idea behind this is if you look at you know the points each point here on the curve so if i look at this point right here how many neighboring points does it have that are connected well it has two right and all the other points basically have two that are in the middle except for the end point standpoints only have one so that's an easy way for us to identify the ends on this guy here and so all i need to do is do an int and we'll call this maze and we can get the neighbor count so we say neighbor count and we want to do zero and at pt number so the current number point number that we're running over right so then i'm just going to say if nays is equal to one that means you're an endpoint so i'm going to say i at group is equal to end or ends that's equal to one there you go so now if i look at my point groups here we have ends it's kind of hard to see so let's actually do a group delete after a while you get a lot of these groups in there so i'm just going to put in a wildcard right so clicks everything out so you can see now we have our ends group so really quick way to find the ends when you have lots of geometry the group by range wouldn't work in this case without us having to lay down a few more nodes and split you know the two pieces apart so we could find just the ends this uh just a better way to go about it there cool so with that um let's do this i'm gonna actually do a blast and we're gonna blast away anything that's not the ends there so i'm gonna say ends that leaves us with these two points like so which allows us then to do a poly frame yeah and we can do our flow normals there we go so now we have perfect normals to begin with here all right and all i need to do now is flip one of these guys so if we take a look at our point numbers like so what we want to do actually we can do a trick here where um we can loop through on a primitive basis and just point the uh normals away from each other yeah so let's do that um so i'm gonna do attribute wrangle try to do this all with a wrangle node instead of looping so call these away facing normals yep all right so we're going to loop through per primitive uh what i need to do now is i need to say endpoints so i need to get all the points from the current primitive and to do that we do uh print points so we say prim points and you could leave one parenthesis open there to find out the arguments that this particular function takes so we need the geometry and the prim number which is just the current prime number that we're looping over all right so that's going to be equal to two right so we only have two points here which basically means that um all you need to do is just get uh the first point and the second point in their positions and then do a little bit of vector subtraction to find the the away facing normals right and so i'm going to do vector nurm a is equal to points zero and actually what we need to do let's do this first i'm gonna do uh vector pause a is equal to uh points and we wanna get from the incoming geometry we want to get the position attribute and that's going to be points zero so that's pause a and then i want to do pause b so let's just copy that line and this will be one this works because we only have two points right so let's just make sure that that doesn't throw any errors yeah we're good so then uh normal a i believe is pause a minus pause b and vector nerm v is equal to pause b minus pause a there we go let's put a little space in here just for being neat and then we can just set so basically you need to set the normals now right so uh we do this by doing setpoint attribute because remember we're running over primitive so we don't have access to the points that's how we set attributes on points in the primitive context so i'm going to set a point actually i'll pick the wrong one so set point attribute set point attribute there you go so 0 i want to set the n or normal we're going to set it on point zero and we're gonna do norm a and set to make sure that it sets and i didn't like that for the point number oh it's because it's the wrong name yep that's working we also need to normalize it but let's finish our code here really quick and i'm gonna go and say norm b and point one right there you go so now we're facing away from each other uh let's just normalize this right here so we have unit vectors there we go sweet all right so now we have our way facing um normals which is perfect so let's let's do this i'm going to build a different subnet for this so i'm going to do another output and we could probably put it over no this will be fine right here we go yup output 2 is fine so with that we'll just move this over here let's do another subnet and we'll feed that in and i'm going to do what should we call these build tie downs i don't know support ropes something like that so anyways i'll let you guys pick a cool name all right i'm just going to call them tie downs awesome so let's go and make sure let's just template all this so we can uh get an idea of what else i need to do so the other piece of information that i need here is the height of just the total y size of our um our post curves our post lengths and to do that we can actually build up a detail attribute that just goes along with the geometry here so let's do that really quickly where did i split the guys here so post lines right here so yeah what we can do right here let's drop down another attribute wrangle node and i'm going to call this the post line height let's run over detail because we're going to add a new detail attribute this is going to be a float value and we're going to say f at post height let's do underscore post height and we're going to do the um we're going to get bb box size of the incoming geometry and the y size there we go so now if we look at our detail attributes here you can see that we have a value of 0.8 all right and you you'll notice that if we come all the way down here the detail attribute is still moving along with the geometry right still being pushed down this whole stream here and you can see that it's still available and now that particular detail attribute is on the curve yep so we can use that information to create a line that looks like it's being tied into the ground so let's do that so let's drop down a null node here now i'm going to call this geo in and we don't really need the geometry anymore we just really need those points there so i'm just going to delete the geometry but keep the points and i'm going to create a line now and this lines got a point in the z direction for this to work right it's because the direction that the normal is pointing is going to be is the z direction so when i copy this so i do a copy to points now select these two guys and feed it in there like so you can see how now they're being copied in their normal directions which is great so now we have control over that length for the line so now what we need to do is we need to move the endpoints down that detail attribute amount right so this amount right here that's going along with the geometry so let's create a group and this group's going to be the endpoint so we'll call it endpoint we need to set our group type to points and it's just it's going to be one because the line just has zero and one and that endpoint is one so regroup just that guy so now for each one of these guys if i go to my group and attribute list here you can see let's actually do another group delete to clean things up so it's easier to see just put in the wild card there you go so now you can see we have the endpoints awesome so now all we need to do really is uh drop down another attribute wrangle node this time we're going to run over points we're only going to run over that endpoint group and let's get the data we can actually get it from this guy because it's still on this yeah so let's just put the data in there one thing i do like to do in this scenario is to use a little knot so if you hold down alt and then click you create a little knot there so that will pass height past post height and we'll just negate it so because we're already at the the highest point right that's what we copied to so i need to do is say at p dot y minus equals a detail so the incoming geometry from in input one there right so this is zero one and we want that uh post height yeah post height so the name of the attribute is post height and just 0 for the first index there you go so now we've got the curves for it now we might want to make that a little more intense so we're going to you know do some addition so we'll say plus some sort of intensity value i might want to sink it into the ground a little bit more just to be you know kind of gamey about it yeah so now we have a little bit more beautiful and we also have control over how far out that goes right yeah so let's just do a quick sweep on this and test this out and i'm going to also create some uvs for it so i don't want to normalize and i don't want to snap let's save our scene now let's change the surface shape to our round tube and then let's hook up so we don't need all those columns there leave it at six and then we're gonna do ch dot dot forward slash dot dot forward slash i want the um rope length rad yeah there you go so it's the same length the same width as the the ropes um and the lengthwise not the side ribs cool yeah i think that's going to work and we have uvs too yep beautiful let's uh just output that and add it on and test it out in unreal yeah look at that it's a nice extra little touch there beautiful so yeah let me go out of template mode here and let's just make sure that we actually put that into the assemble node sorry i was just getting lost and looking at it uh we also need the color too you know one thing we could do let's just merge these two together since i want the rope colors to be the same so let's just do this i don't need the tie downs let's uh then go grab the color note out of here and uh so i'm using the u and i key to quickly fly in and out of the nodes there much much more handy and that looks like it said it all wow it's because these guys are all off now they just need one of those dot dot forward slashes removed because we moved it up a level there you go excellent and i do like to even these guys out let's make it feel organized anyways yeah so there we go that's how we build those kind of tie downs i wish i actually knew the official name from they might not even have an official name you never know so let's go and rebuild our our instance there we go look at that let's uh test this out here so let's actually select it and let's uh move this around in the scene yeah looks like it's working pretty nice let's one thing i always test with these kind of setups is to kind of you know really flip it make sure everything's rotating appropriately so i just flipped the two handles yeah everything's looking good let's move this guy over here excellent yeah this actually kind of turned out cool not that i ever had any doubt all right cool so i'm going to end this section there i'm not really sure what i'm going to do next i'm going to think about it here for a second i think i want to add a couple more things on here it'd be nice to texture this up too uh so far that's actually looking pretty cool let's turn on the hi-res i do need to work on that a little bit more but still it's looking pretty sweet we do need to make a rope a high-res rope for that for our tie-downs that was working out it'd be nice to do little knots too you know for these guys maybe that's what we'll do next all right let's move on okay so i'm going to do a couple things in this section i want to give some color to the posts over here they're looking a little bland right now and also we want to do the knot so let's do the knots first here so i'm going to jump into the build ropes node here and i'm going to drop down a blast node because what i want to do is just get those side curves that we have so i'm going to go and get the sides in this case uh you can do the knot sides or you can just use the delete non-selected so i'm just going to leave it like that so uh let's do some flow normals for these guys actually do they already have them no yeah so let's do the flow normals for these guys now beautiful because i want the you know the knots to be in line with the actual rope for the sides there so that'll work next thing i need is a circle this will form as the base kind of path for the circle and the base radius also and so i'm going to copy this to the points each one of those points there all right and we also need to make this on the zx plane so it's following those guys there and it looks like actually we are getting a little bit of oddness and that's most likely because we have some extra attributes so let's take it from here yeah there you go that's what i'm looking for so i just want to get rid of those old uh right values and stuff like that look a little off let's just keep moving forward and see how it looks in the end there uh we're gonna make this pretty tiny you know because these are just kind of knots that loop around the rope make it look like it's holding on a little bit better all right so with that let's make sure we turn on polygons for those guys it's looking good so far and then let's do a loop so let's do it for each primitive here so we can look through each one of those guys and perform the knot the taurus knot now i'm not going to do any backs for this you can actually do it quite quickly with um sweep node and the add node or resample node so i'm going to do the sweep node and we're going to do our round tube with the three sections cross sections so round two three cross sections let's make it a little bit smaller here and let's just output the the rows right and then let's do some twists let's do this we'll do some full twists here just like three we don't need a ton there all right and then we're gonna do the add node so we turn them back into curves and delete geometry keep the points and we'll do skip every nth point put it to three that way we get the beginnings of our taurus knot at least i'm also going to make this closed that way we get these curves that are basically you know inner interweaving with each other like so we can also add a couple more um i actually need them down here oh i need to actually put this down there you go now we'll get better resolution so i had to turn this on because if you have it uh plug or if you have the display flag on this guy the cache isn't updating so you need to put the display flag so this guy cooks cool so now you can see that we have kind of this tourist nut thing going on and then i'm going to resample this so let's resample and let's do maximum segments that way of control over the resolution of these guys and i'm going to output the normal so the flow normal using the resample this time so there you go cool so yeah now we have a pretty cool tourist not let's do a subdivision curve as well just make it a little smoother and then we'll just do a sweep and we will do round two let's go back to our shaded view and drop down this resolution or that radius there probably don't need as many loops there there we go so now we got a doorstop we can control a bunch of things let's actually just get it merged and i'm actually going to merge it in so we always have these guys i think they'll look pretty cool and then let's hook it up so that we have the same oh let's also turn off the single pass there we go so now we're getting there getting closer um let's go get the length rad channel and put that into i believe this guy so let's do that and we'll do a times something like 1.5 there you go so it's just a little bit bigger and that controls that this controls the radius of each individual strand and then we have our twist i don't think i need as many twists let's just do two that looks better and then maybe make it a little bit fatter here yeah that's all you really need let's take a look down here yeah it looks fine yeah very cool all right so i'm actually going to call that good i think that was going to work out just fine uh i'll probably let's let's mix up the normals as well down here i'm doing it kind of globally so you know for the playing some post that's fine having the hard edges i think for the ropes i'm gonna make it soft so we'll just do this just 180 there we go those look better than unreal yeah it looks pretty cool i know it's not like super realistic or anything but it does the job you know honestly if you're running through a game and you're the players is running through this they're not going to sit there and be like oh my god you know it's not totally connected properly some people might i don't know anyways um all right so let's take care of the colors on the post then so i'm going to go to my build posts here and we have plenty of room here to take care of this of course you know a better thing to do is just to do it on the post itself and the reason why is because you know it's all centered up in the world and we can build a gradient pretty easily and again i'm not going to use the labs notes because i don't like to include them in my hdas when i'm using houdini engine it's just a little risky to do that in terms of versions and you have to leave them unlocked all that stuff so let's let's go and drag or create a wrangle note and this is going to be my my ramp value so i'm going to do ramp here and we can actually do a color ramp inside of these guys so let's put it on the points and what we need to do is build a ramp that basically goes from zero to one based off the height of the post here so to do that we need to first get the size so i'm going to call this the um size this is going to be a get size like so and we want to feed in the first input there all right so now we have the y size and basically we need to just fit we also are going to need our box min and box max for this so let's do vector box min and box max we'll do get bb box uh just get bb box really so it gets all of them all at once and you feed in box mid and box max like so i'm sorry i'm doing this on the wrong line here i've got ahead of myself there we go cool there you go so but basically what happens if you actually look at the documentation here for this uh if it basically is like a ref if in c sharp it outputs um the value into the variable that you're feeding in and that's what the little and symbol means for that stuff all right cool so now we have the minimum and the maximum and all we need to really do now is say at cd is equal to fit at p dot y there you go dot y and we want to fit it between box min dot y and box box max dot y and then fit it to zero to one like so there you go so now we have a gradient and let's actually excuse me there um let's actually put that into a variable called ramp so we can actually create a fitting ramp here so basically i'm going to then say at cd is equal to ch ramp we'll call this gradient and we'll feed in the ramp value there and then let's create the float parameter and now this allows us to kind of basically remap the ramp there of course we don't have a lot of polygons on this right if i were to go to wireframe view we don't have any polygons and since we're working with vertex colors we need to add some more points here so yeah that'll be that's fine so i just did five points there so now we can you know really adjust where that ramp starts cool so then um yeah we can we can use that value in a color node so you could always just put this into something like f at ramp or actually that's called gradient like so and then we pump that into a color node and then we can affect the colors so we say point and we want to do ramp from attribute and we do gradient so we get the same thing right um and actually that means you know honestly we don't really we could always just we don't really need to create a ramp here so let's actually i'm going to show you how to get rid of your spare parameters let's do this let's get rid of that guy and uh but now you notice that we have the spare parameter that we created so all you need to do is just come up here and say uh delete all spare parameters that clears it out all right so now we have you know this ram down here but we can actually colorize it so i'm going to make this a little bit like green i think and this one's going to be the wood color so do something like that and maybe the green is a little too much there get up more in like a wood color a little darker too yeah let's make this a little bit lighter so it really pops awesome now we got some color there and let's actually move our output down there we go and let's move the display flag down there yeah very cool and it looks like i host something because the reps are really really low now it's funny let's see what i did ah that's right let's go and take a look at a copy of points to see where that um error actually starts to happen oh so there's our points oh i see that's what it was because i added more points to the line right so quick way to actually fix that it's good that that happened it happens to me all the time i forget about stuff so quick way to get rid of all this here even before the carve here um let's just do a facet node this allows you then to remove inline points and uh yeah so that now we only have two points there it's kind of hard to see yeah there we go so now we should be back in business let's set our display flags back and take a look at looks like i fixed it very nice yeah so i just wanted to colorize those and add the the taurus knots up there makes it look a little cooler a little more detailed let's um now go and save this here and go back to unreal and we'll do a rebuild all instances and this this does happen every once in a while with uh v2 we got this gls running i don't know and so it's going to crash me and we're back all right so um let's go and test all this stuff out now everything's looking pretty good here let's grab this guy and move this over here yeah it's still pretty speedy even with those nuts still on it's pretty cool it's coming along quite nicely i am digging it all right let's take a look here yeah i think everything's doing pretty good i love the little knots there really had some detail so all right so i think the last thing i'm going to do in this video um is just to organize the uvs a little bit better and then i'll probably make some textures just with a quick swim mixer nothing crazy and i'll probably show that in a later video a follow-up video all right let's move on to the next step all right so i'm going to do the uv layout at the very end here just take note that if you had a lot of uv layout nodes you know in individual subnets here it'd actually be a drain on performance and your hdl's go a lot slower the uv layout node is really um heavy on performance it really does take up quite a bit so i try to save it for the end sometimes i even add a switch to toggle it on and off so when you are ready to bake it out at least you can top it on and have all your uvs laid out so the first thing that we need to do here is i need to set up a grid this is basically going to serve as my uv layout because i'm going to be using a trim sheet for this that i make in crystal mixer and so i need to kind of divide this up based on how i want to split everything up and so you can do this like as a manual process you don't have to make the salt procedural it's just really there to let you organize your uvs appropriately so all right so let's take care of this here um let's take a look at the clip plane i want to point this in the z direction so we get this guy split in half now i'm just going to keep all primitives here and turn on my wireframe on shader by doing shift w and i think i'm going to move this up a little bit and then i'm just going to duplicate it and then i'm going to move this down so i'm basically you know creating the areas of my trim sheet where i'm going to have different woods and a rope texture and then i need something for the the caps on the wood planks and all the posts so those are all the different textures i'm gonna need cool so i split that guy up so these are to be different woods over here so i'm going to do a wood for the post and a wood for the planks and then i'm going to put my end caps here and the rope texture over here though we're actually going to need the rope texture to tile so that means we can actually make another one of these here and i'm just going to pull this guy all the way up here we'll put the rope up there let me actually just move these guys and make it a little bit more even yeah let's do this those end caps don't need to take up that much texture space they're pretty small anyways yeah it looks good all right so let's take a look at our prim numbers now so what i'm going to do is blast away print two and then let's put two here and i'll say delete non-selected well actually let's do a split sorry about that so let's do a split because i do want to keep the other pieces i just want to process prim two a bit differently so let's split on two there we go and then let's copy one of these clip planes here and i hit enter to show the gizmo so this one let's actually center it all back up and everything this one needs to be on the x direction like so and uh yeah well i'll probably just put the caps over here like a little you know the you can see the the rings and the wood basically for the end caps and that means we'll have an open space or something over here all right so with that let's uh merge all this stuff together yeah cool so now we got all of our individual shells created all right uh one thing we're gonna have to do currently you'll notice that the clip node um if i were to turn on my point display here it doesn't actually separate the geometry right and in order for this particular technique to work we need to actually separate this geometry out here now this piece did but there there's a better way to do this and also we need to generate some uvs here so i need to do a uv project and we'll just feed that right in there we just need to put in 90 for this guy so yeah so now i've generated uvs and so what we want to do now is we want to associate certain uvs with a certain id here notice that we have these primitive ids we can actually clean these up a little bit better as well by doing a sort node down here so if we do a sort let's just sort by the z direction so we have zero one two three four yeah so now it's a little bit more in order there and so we're gonna use these particular ids here to send different uv shells to different uh islands right think of these guys as little target islands that we want to send things into so we're going to do a bit of work here so i'm actually going to bundle all this up into a subnet and we're going to call this our uv layout let's feed in the geometry all right we'll kind of walk through this the first time you do this it can be a little confusing but once you do it once you get it it's pretty easy after that all right so we got our short node and we have uv set up for this right um i might actually i'm well i could leave it like that we'll put the rope down here i was going to drop down a uv transform node and flip it so a negative of y negative one and y we'll flip it but yeah then we'd have to center it doesn't actually matter that much you could change the pivot and everything but this will be fine so i'll just remember the texture needs to be this way all right uh you could also flip the geometry so let's take care of this so what i'm going to do is create a new for each primitive here this will separate out each primitive and then merge it back together but the uv shells will be separated out which the uv layout node wants and also to make this work we need to assign an id now i just want to use the primitive numbers for the ids for these target islands here so i'm going to go and create this meta node i'm going to call this loop data like so and drop down a wrangle node here and i'll wire the loop data into the second one because this has the iteration attribute on it that i want to use all right so we'll say set island id like so and i'll set this this needs to be a primitive attribute and i'm going to call it i at target is equal to detail and we're going to get the input from one we're going to get iteration like so there you go sorry iteration there we go um it's been a long day there we go cool so now on each one of these guys on the primitives we have a target and it just so happens that it's the same number as our primitive number you could also just use the premium but i just decided to do it this way all right so uh let's get the incoming geometry so that'll be this input one right here and let's put down our null node we'll say geo in and then we will focus on just one part so we'll do i think the planks first and then we need a uv layout node and we're going to hook up our incoming geometry in our uv layout right so this is basically how i want my uvs to be laid out what goes in each of these islands we have haven't actually set yet but we set the ids for the target all right so we have our geometry so how do we do this so let's start with the planks first and let's go up a level here so let's say let's actually go back in there sorry guys um let's say i want my planks to be in island one all right so all we need to do is go up to our planks over here nope make sure we have uvs first off just make sure we check all this stuff very good and all we need to do is drop down a wrangle node you can also do this with an attribute create node but we're going to say sets island id and this has to be a primitive and we're going to say i at target is equal to 1. that's all we need to do all right so if we were now to come back in here let's take a look at this note here what i want is all those plank pieces to go into island one so in order to do this we need to go into the uv layout node rather than packing into rectangles here which actually is working out pretty well but i want a little bit more control yeah and so um i just set it to islands from second input uv attribute is what we want but we want to go up to this target assignment and we want to set the target attribute to target like so now well it looks like all the jumps so we need to go and set all that stuff up on each one of those because basically what's happening is we have a bunch of attributes on there and some of these guys yeah so target yeah so the target got wiped out here so that means that during that merge right up here all those guys got screwed over i don't see a1 anywhere yeah all right so the posts they're gonna go into let's go back in here and take a look turn on our criminals they're gonna go into two so we can just uh set that up appropriately here so i can set this to two you can already see they're starting to move around it's all these guys moved so the planks moved to one which is good right now all of these guys all the posts move to um the second uv shell so hopefully you guys can see all this happening while i'm doing this so then the ropes all need to be in what was the id for it let's check that again here zero all right looks like we have uvs for all that stuff so let's set the ev shell or island target so it's gonna be zero let's take a look always make sure to save while you're doing this as well those eyes didn't seem to want to go let's go into yeah they went looks like they went up there let's make sure we have uvs on everything so we got this guy what is this one oh that's yeah that's right i didn't make the uvs for these ones and we don't want to do normalized and we don't want to snap i just want to leave it that way these guys are not even set up either jeez i do want length weighted but not normalized there we go and let's do this one yeah there we go okay so all those guys should have ev's now which is good the tie-downs let's check it out looks like i did those guys too all right so we set the island id there we go so yeah now they're all being placed down there which is great so almost there um all the caps then so this is where we're gonna have to get a little bit fancy because all those well those are all a bunch of different pieces up there we're getting there though so the caps one over here i want all these caps to go into a different one let's go back into the uv layout node and set a few other things here i'm going to do by island position in 3d and we'll scale to match their positions actually let's do yeah in symmetry that'll work just fine now we can do 90 degree rotations there we go let's do 180 degree rotations that'll be fine are all these guys up here you can always find out if we just select the points and then go to oh it's all these guys all right so i finally got it sorted out um and so i'm just going to walk you through what i did and um this is a very slow operation so we're going to put in a switch node for it but it does get all your uvs laid out for you so i'm just going to put a output node here so um on the uv layout node we need to turn on our island attribute and the reason why i was getting all those rope pieces up here um was because it just ran out of space and it was because it was trying to spread all that stuff out and some of these you know rope uvs are really long and so i need to stack them on top of each other but i just want to stack just the rope pieces onto on top of each other and not you know all these other pieces and so you can see now here i have my shells i'm getting you know my caps where the caps need to go i'm getting the the posts for the post wood and the planks for the plank wood and then the ropes for where the rope's going to go on the trim sheet and so all i need to do now and i'll probably do this off camera but you'll be able to see it in the hda it's just randomize and scale the uv shells a little bit differently after the uv layout operation but in order to set this up what i did let me jump up and show you guys so on on the ropes i set the target to zero and the island to zero and that basically will send them to this particular shell down here plus it'll stack them on top of each other it treats it as one island basically and then i have these two wrangles here so for the first one i just set all the posts to two and if you still want to spread all the shells out use a negative one for the island attribute and then what i did is i grouped all the patches right so those are all the let's go up one if i were to look at all my patches here those are all those patch pieces right so i want to have a different texture on those guys and so um that's what i did so i just on the patch group i just sent them to a target of three and an island of one and uh did the same thing here and then i sent all the planks to target one and set those guys to a negative one so they laid out appropriately and that gets me all these guys laid out into the shelves appropriately now it's really slow so you know we need to drop down a switch node so when we're ready to bake you know we turn it all on basically you can also accomplish that with some uv transforms it's a little bit more work but it probably speeds up speed it up a little bit i'll test it out for you guys and see what happens but that's how you deal with the uv layout node in just one uv layout node using a predetermined layout alright so just wanted to show that there so we should probably expose that stuff here let me actually go up here and make a uv folder call this uv and make it collapsible and i'll just promote so let's just promote this switch here so i'll just do a alt middle mouse click and we'll say layout uvs and layout uvs and we'll make it a toggle oops let's do a toggle and default is off cool so that should work just fine of course let's save this guy that pretty much does it uh for this particular video got really long so hopefully you guys weren't too bored there's lots of cool stuff in there we made a nice cool little bridge for houdini engine version two so thanks so much
Info
Channel: Indie-Pixel
Views: 5,001
Rating: 4.9794869 out of 5
Keywords: Houdini, Houdini Engine V2, Procedural Props, Procedural Modeling
Id: cEmM17r24y4
Channel Id: undefined
Length: 155min 5sec (9305 seconds)
Published: Sun Apr 25 2021
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.