Using Hints - Advanced

Using Hints - Advanced

Submitted by: SenceSence on 11 Jan 2019 06:28
Last updated by: cold_blood3dcold_blood3d on 29 May 2020 22:42

BETA

Using Hints - Advanced

In this tutorial, we will take a look at the so-called hints and what they're used for, what they do and so on. Each tutorial lecture is labeled with a subheader so in case you look for a specific thing you know right away where to find it.

What is a hint?

"Hints" and "Skip" are used as a texture on a world brush which then will tell the engine in which angle/position from the player a w-poly (World Poly) can be skipped if not seen to lower your r-speeds (Render-speeds). This would result in better performance since your machine will render less at once.

First, we need to build ourselves a map where we can assign our hint to, to reduce its r-speeds. In this case, I created a simple room.

Hints_A2.jpg

I did split its ground into four separate parts, the reason for this was to increase its r-speeds a bit.

Hints_A4.jpg

Ingame it looks like this, on the top left you can see that it has currently 12 w-polys.
We can take a closer look, how those w-polys are put together. If we open the console now and insert the following command "gl_wireframe 2"
we can see the wireframe of each w-poly.

Hints_A5.jpg

If we watch the map now out of the "World" we can see the 12 Polys.

Hints_A6.jpg

As soon as we enter the world the w-polys rise to 16.

Hints_A7.jpg

And the reason for this is that it also renders the faces which we don't see and those are the ones behind the player.

Hints_A8.jpg

As long as we were outside of the map those didn't get rendered because I did use a null texture on the outer faces of those world brushes.
So in order to get rid of faces that remain hidden from the player while he is inside the "world" and without using null textures, the hint texture is used.

This is where we will use the hint method. First, we start creating a brush using 1 hint texture on the side and for the other faces skip textures. The hint texture tells the engine if we don't see the w-polys in our viewport and they're behind the hint brush they can be discarded. This works similar to a null texture except that we have to tell now the engine where that NULL texture is, while the engine doesn't find it on its own.

Example of using hints.

We start creating a brush the way mentioned prior.

Hints_A0.jpg

Now we add the brush to our room.

Hints_A9.jpg

remember we don't have to apply the brush to left and right, one site is enough to be effective on both sites.
I did mark the hint texture in-game

Hints_A16.jpg

As we stand in the center of the hint brush nothing happens because the engine things we're on both sites of the hint texture.

Hints_A17.jpg

But when we move far to the right of the hint, we can see now that the w-polys on the left are discarded.

Hints_A18.jpg

same with the opposite if we move to the left.

Hints_A16.jpg

The numbers of w-polys differ because the surfaces are split up unique.

Hints_A10.jpgHints_A12.jpg

Section 2 - Pyramid Hints

Hints___A19.jpg

So let's try something out here. If we now place the hints in the map like this it would give the possibility of 4 rendered sections.
Ingame we would have no different effect.

Hints__A19_.jpg

Nothing changes if we stay in the center. But if we move to a corner or wall for example.

Hints__---A19--__.jpgHints__---A19---__.jpg

Very nice! but what do we do now about the center where the hint has no effect.

Experimenting

We're going to add more hints of course.

We want that if we are at the center some of the faces we don't see get discarded too.

Hints__----A19---__.jpgHints__----A19----__.jpg

If we add those the engine can now discard even the faces we don't see. Even if we are at the center.

Hints__----_A19----__.jpg

We just lowered our r_speeds yet again. We also can add hints for the top and bottom faces now, it looks like this.

Hints__---___A19--__.jpg

results in a corner now.

Hints__----_A19_----__.jpg

we even see changes now if we crouch.

Hints__---_A19--__.jpg

}

Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License