R_SPEEDS- PART 2
So you understood the first part? Good good.
Now we are gonna need to understand what VIS is to carry on in this tutorial.
VIS stands for Visible Information Set and
what it does when it compiles is work out what parts of the level are drawn
at any time the player is there. So if the engine can "see" a huge
open area then it is gonna take longer to compile and r_speeds are gonna rise.
Let's look at an example.
I set up a very basic area for this example.


At this point the engine is drawing the room
we are in, the corridor and the room down the end there with the crates in
it.
Take note of the r_speeds at this point.

Now one thing we must remember is that the
engine draws areas even when the player can't see them. To find out what it
is drawing at any point type gl_wireframe 2 in the console.
(r_draworder 1 for software mode)

As you can see the far room is being drawn
by the engine even though we cannot see it. This is very important to remember
so always check with the console command.
Right, how can we lower the r_speeds in this
situation? Add a door? nope, as a door would be an entity and rather unfortunatly
entities don't block VIS. :(
There is a way though, cast your eyes below.


As you can see I have deleted the old corridor
and added a bend. Let's see what this can do for us now.


As you can see the engine is drawing much
less then before, and for the final verdict:

As you can see the r_speeds have been cut
by almost 50%. Plus having a U-shaped corridor is far more interesting then
a straight one.
When you are making your maps always think
about what the engine can see, as CS is multi-player and every r_speed you
can knock off will reduce lag.
Experimentation is key.
By
Blink