Tutorial: How to make a sphere

06/05/2010 20:16
Page 1 of 1
Fliborecord holder Tournament #206/05/2010 20:16(edited 07/05/2010 13:53)

WARNING! The following tutorial is not recommended for beginners and following this tutorial will probably take quite some time. I only can recommend you to read this if you're a mapping expert and interested in Hammer/HL engine. If you want to save time, just grab my .rmf (the outcome of this tutorial). If you want to know more about the half of a sphere, just skip to the end.

Prologue

Since the dawn of time man has tried to figure out ways to create a sphere in the Half-Life engine. Now the beginning of the big breakthrough has finally happened: I bring to you, a tutorial about how to make some stuff that resemble a sphere.

Part 1: Splitting the faces

Firstly, open up your Valve Hammer Editor (doesn't really matter which version).

1. Make a cylinder with "x" faces like this (dimensions don't really matter, I went with 256x256x256). http://img263.imageshack.us/img263/8996/tut1m.jpg

2. Select the vertex tool and click on the cylinder you just created. http://img687.imageshack.us/img687/6705/tut2n.jpg

3. Select two neighboring yellow middle points while holding down CTRL and press CTRL + F when they're selected (splits a face). http://img218.imageshack.us/img218/8903/tut3.jpg
http://img532.imageshack.us/img532/5762/tut4y.jpg

4. Repeat the procedure, but emphasizing that both points have to be YELLOW, not white. That means you have to skip one face of the cylinder (well handle the skipped face later). That said, move to the next two neighboring yellow middle points. http://img203.imageshack.us/img203/4804/tut5.jpg

5. Now for the face that was skipped. You should see 2 neighboring white vertices HERE http://img219.imageshack.us/img219/5089/tut6z.jpg. Select them both while holding down CTRL and then press CTRL + F.

You should now have something like this: http://img691.imageshack.us/img691/8468/tut7x.jpg

6. What then? Well... Just repeat the procedure over and over until all of the faces have been split. Just remember the rule of thumb: You can only use CTRL + F for two yellow OR two white points.

After you've done it, you should have something that looks remotely something like this: http://img199.imageshack.us/img199/5804/tut8x.jpg

7. Well, simply continue splitting your vertices up the next floor like this (my vertices look sad): http://img525.imageshack.us/img525/6140/tut9s.jpg

Do that to however many floors you like. The formula for calculating how many times you have to push CTRL + F with this method is:

Number of floors * Number of faces


IMPORTANT! Keep in mind that HL engine is not limitless! I tried to make 8 floors with 16 faces but Hammer refused to split any more faces for me in the middle of the last floor. 7 floors with 16 faces worked fine.

Here is a picture of a fully split beginning-of-a-sphere: http://img688.imageshack.us/img688/4720/tut10.jpg

Now you have 2 choices. You have to make either a half sphere or a full sphere. A half of a sphere can be bigger and the top is like it should be on a sphere. The full sphere looks like a ball, but the top and the base of it are not exactly how they should be, but it's close enough.

Part 2 Way 1: Give that half of a sphere some curves!

8. Take your vertex tool and in the 3d view select a top vertice of your cylinder. http://img140.imageshack.us/img140/3523/tut11.jpg

9. Now drag it in the middle from the top 2d view. http://img243.imageshack.us/img243/5021/tut12.jpg

10. Repeat the procedure for each top vertice and most importantly MERGE them. It should look like this: http://img99.imageshack.us/img99/4220/tut13.jpg

11. Take out your vertex tool and select vertices (make a selection in the 2d view and press enter, it will choose all of them) as shown in this picture: http://img153.imageshack.us/img153/706/tut14.jpg

12. While still having the vertex tool selected, press ALT + E. This will bring the vertex scale tool to you. Put some value in it, for example 1.2 (just for trivia I actually used 1.7 unlike in the picture). http://img22.imageshack.us/img22/5844/tut15.jpg

13. Repeat procedure for every group of vertices in a tasteful way fiddling with the numbers until the bottom: http://img405.imageshack.us/img405/1963/tut16.jpg

Part 2 Way 2: Give that sphere some curves!

14. Select the group of vertices in the top of your thing (make a selection and press enter to get them all selected) and push ALT + E. This brings you to the vertex scale tool. You should now have this: http://img402.imageshack.us/img402/8946/tut17.jpg

15. Okay, here comes perhaps a brain puzzling part. Select a value so that the vertices are really close to being in the same point (as they would if you put 0 in the tool), but that they don't go to the same coordinates. If you're unsure, just select a safe number which leaves some room for the vertices. I chose 0.050. http://img695.imageshack.us/img695/747/tut18.jpg

16. Now just work your way for every floor of vertices until the middle and then start doing the reverse for the bottom floors so that your sphere narrows towards the bottom. If you did that, you should have something like this (mine is very low-poly because I didn't have time): http://img504.imageshack.us/img504/5227/tut19.jpg

That's pretty much it.

Epilogue

Due to lack of my time I haven't had time to experiment enough with making these spheres. Making a full technically correct sphere definitely should be possible, but to what extent? I bumped into problems when trying to make a full sphere. Whenever I was trying to do step 10 to the very bottom vertices of the cylinder the whole brush freaked out whenever I tried to move the second last vertice in the middle. I noticed some tiny flaws in my cylinder, but I couldn't figure out a fix to the problem. There can be a solution to it (other than just pretending that the vertices are going to the same place, see step 15), that's why I'm writing this. I want someone to find this out. I hope someone finds this helpful.

Technical properties: The half of a sphere should be surprisingly non-buggy. You don't even have to be careful with it, you can twist, rotate and resize it anyway you want. You can even mess up with the vertices a bit. In-game the half looks decent and feels superb (at least compared to my old spheres). It is seriously damn smooth, try it. Same goes to the full sphere, but I wouldn't recommend making the sphere smaller as the top and bottom could mess up.

Resources:
Both high- and low-poly half spheres and a very low-poly full sphere: http://www.sendspace.com/file/d3l0yb


If you spot any mistakes, don't hesitate to notify me as I did this on a hurry. Please share your thoughts.

dEMolite mapper06/05/2010 23:34

added to the overviewlist
nicely done Flibo :)

Pieshels mapper07/05/2010 09:50

I have tried to make something like this before, but I always failed somehow.
Now that I know my mistake (I tried to connect the top vertices with CTRL + E not knowing that they don't connect properly that way) I will try to bring this a little further.

So I experimented a bit and managed to create something sphere-ish.

The trick is to leave the top and the bottom flat.
Compilated.
No errors. Pure sphere.

I will put some screens and .rmf when I get home because this pc I'm currently on is laggy as hell.

Fliborecord holder Tournament #207/05/2010 13:10(edited 07/05/2010 13:11)

Originally posted by Pieshels
I have tried to make something like this before, but I always failed somehow.
Now that I know my mistake (I tried to connect the top vertices with CTRL + E not knowing that they don't connect properly that way) I will try to bring this a little further.

So I experimented a bit and managed to create something sphere-ish.

The trick is to leave the top and the bottom flat.
Compilated.
No errors. Pure sphere.

I will put some screens and .rmf when I get home because this pc I'm currently on is laggy as hell.


Do you mean that the base and top would be little circles? Yes, that would work, but technically it's not a sphere :P Thanks for reminding though, I should add that to the tutorial as that's a very useful way to make a sphere though and it definitely would look good too on most occasions.

I'll add a sphere made with your way in the .rmf and try to merge it with the tutorial. Thanks.

st@mbeto. mapper07/05/2010 20:14

nice flibo :x

PsYxOpAt mapper07/05/2010 20:19

awesome very usefull :)

hm^ mapper VIP05/10/2011 17:51

hey,

Like a year ago i used this tutorial to rebuild my sphere for
hm_deathsphere.
Ok, it is in german, but the pictures speaks for them selve.

Here is the rmf-file from my sphere:

klick me

hf

PS: There is also a tutorial about to make a ball.

klick

OFFBEAT06/10/2011 00:35

Very useful hm^, nice one, thank you ^^

mkzLight04/04/2013 06:08

thank's

Page 1 of 1

Please log in to post replies.