After testing different methods in hammer, I came up with this method for curving a pipe created by displacements.
This tutorial is about making the curve in a pipe created by using Subdivide.
In this tutorial i expect you having basic knowledge of:
The Vertex Tool
Using Displacements
Using Subdivide
And of course how the hammer editor works.
I'm going to try to make this understandable for any noobs, by explaining things, and using a lot of pictures.
Remember that the Questions are only for the step they are put in.
- Step1 , Creating the Displacement Brush -
First, create a basic block, I made mine 128*128*256. (Which is going to be a big pipe, big enough for a player to crouch inside <- Just used for you to get a clue how big it is, you're not going to make a hollow pipe in this tutorial)
This is the brush we will be making the pipe out of. I used the texture 'models/props_c17/metalladder002'
Select it, press Shift-A, go to the Displacement tab, press Create, then OK.
This creates a displacement, if you decrease the Power, you will get less moveable points on the displacement.
Select the bottom and top faces, then press Destroy. (Hold Ctrl while selecting them to select both)
This removes the selected faces.
- Step2 , Creating the cylinder shape -
Copy the Displacement 2 times above eachother. (Copy: Drag and Drop while holding shift)
Copying it 2 times should leave you with 3 identical displacement brushes.
Select all 3, press Shift-A, go to the Displacement tab, press Subdivide.
After a moment, you will have 3 cylinder shaped displacements but the upper and the lower one will have quadratic ends.
After:
- Questions -
---- Q: What happends if I skip this section, and just Subdivide the first brush? ----
---- A: You get this brush, with quadratic ends. ----
- Step3 , Connecting 2 pipes -
Remove the top and bottom displacements. (Use the delete button to delete them when they are selected)
You don't want any of the quadratic shaped ends.
Copy the remaining displacement, then press Ctrl-M and rotate it 90 degrees in either the X or Y axis. Then place them so they touch at the corner as shown in the picture.
This is how you want your pipe to curve, it doesn't matter what way it curves, because you can rotate it later.
Then enable vertex mode, and select the upper displacement. Move the vertex shows on the picture, to the other side of the opposite displacement, as shown on the picture. (The yellow dot has nothing to do about where you are supposed to be moving it, but this time, it's going to the yellow dot, just to make sure that you're not using the yellow dot as a helper in other cases). REPEAT for other displacement.
Select the vertex in 2d mode, by dragging a box over it, just to make sure that you select the vertexes on BOTH sides (Look at the picture in 3D view, you'll notice that there are 2 red dots).
After:
- Step4 , Creating the curve -
Now you should have a "connection" which looks like mine. Now, copy the displacement as shows in the picture (so it touches the original).
Just a step for making the pipe curve correct, this will be deleted later.
Press Ctrl-M, and rotate it 180 degrees in the Z axis.
...
Repeat the same steps for the other displacement. But rotate it in either the X or Y axis. (It depends on what way your pipe is curved, just try both X and Y, and see which on turns it the way it's turned on my pictures, this also needs a 180 degree rotation)
We want to do the same for both ofcourse.
Select all 4 of them, press Shift-A, go to Displacement tab, press Subdivide. Remember to delete the outer displacements now, as we don't need them anymore.
This will create the curved pipe this tutorial was all about.
After:
- Questions -
---- Q: What happends if I skip this section, and subdivides only the 2 displacements? ----
---- A: As mentioned before, you will get quadratic ends. ----
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
---- Q: What happends if I skip this section, and just Sews the 2 displacements? ----
---- A: You will get a corner, instead of a curve. ----
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
---- Q: What happends if I skip this section, and use cylinder shaped displacements at each end (The ones we created in the beginning, Instead of the ones I used vertex tool on)? ----
---- A: The end of the pipe, which is supposed to be touching the wall, will not be straight, and therefore, not fit on the a wall unless you put it INTO the wall. ----
- Step5 , Final Touch -
Copy/rotate around to make it fit in your level.
You now have a curved displacement pipe. In the picture below, I made some more pipes, with other dimensions.
- Made By: GrantaX -
- Example Map: Not Uploaded -
An example wouldn't help the creation of the pipe.







