Powered by Max Banner Ads 

Model fading optimization

Simple Model Fade Optimization

Perfectly optimized levels are a goal of every mapper, so knowing all the tricks to optimize each aspect of your map is important. Hopefully this short tutorial will help you in your current and future projects.

Setting up the models in your level to fade out at certain distances has some huge advantages as you can understand; however, there is also a downside to using model fade settings as they can take the player out of the environment if props are just appearing and disappearing while they move around. So you need to be smart about what models you want to fade in/out.


Compatible Prop_* Types:

  • prop_dynamic
  • prop_dynamic_ornament
  • prop_dynamic_override
  • prop_physics
  • prop_physics_multiplayer
  • prop_physics_override
  • prop_static

For this tutorial I’ll be using some prop_physics Barrels.

You can see my example map below showing barrel models with the same fade settings at various distances from the players view.

Now this is only an example to get the idea across of what happens. A transition distance of this length is actually more costly to render than the model itself. You want the transition from completely visible to invisible to be as short as you can get it without it being too sudden and drawing attention to itself.

There are only two settings you need to change in the models property window.

Start Fade Distance – The model will be rendered normally to this distance then begin its transition.

End Fade Distance – The model will not be rendered anymore past this distance.

But rather than try to guess what the distances are you want for your model, go to the top menu bar and click the “Show Helpers” button which looks like this:

Now just put in 100 and 200 for the “Start Fade Distance” and “End Fade Distance” respectively. You can now just use the helpers in the 2D views to set the distances you want.

Or,

You can move your camera to the spot in your level that you want the model to be rendered normally to – the “Start Fade Distance” value – and click the camera value button in the models properties – – and it enter in the distance the camera is to the model. Then I would suggest just taking that number and adding 100-200 to it for the “End Fade Distance” as you don’t want the transition to last too long where it actually costs more to render. You just want that prop gone as soon as you can.

One last option available for setting the fade effect on models is the “Screen Space Fade” option thats only available on prop_statics. What this does when turned on – “Yes” is selected” – is change the distance values you entered in to pixel values. So you can make it fade away if it takes up X number of pixels on screen. Somewhat useful in doing large open areas and not wanting to tune each model by hand based on its position – ferns for example.

Checking your fade Settings
This is another nice feature in hammer, once again go to the top menu bar and look for the “Toggle Model Fade Preview” button – – and now without having to compile the map or anything you can just use the 3D Camera to check out the distances used and tweak them as you see fit.


Not that hard eh? Its a really simple trick but it can do wonders in a level where models are not hidden properly – visleafs not being removed – and occluders can’t be used to solve the issue for one reason or another and so on.

Some good basic things to use this effect could be:

  • Gabage/trash
  • Small plants
  • Barrels :P
  • Light Fixtures
  • rubble/rebar

And of course any other small detail type of models that you’re using and are not necessary to be seen at all times but only within close proximity. Do players really need to see the beer bottles in the fridge from 90 feet away? not really :P

Small note, if you want to apply this effect to brushes as well then all you need to do is tie them to func_lod which will perform much the same way as the model fade settings here.

Anyways, I hope this simple little tutorial helps out some people and adds to their growing skill set.

-Logan “Lost” Dougall

  • Share/Bookmark