How to create static models with a LOD?
-
- Posts: 210
- Joined: Fri May 28, 2010 2:30 pm
How to create static models with a LOD?
I just played a round of Far Cry and watched the grass fading in and out and the trees losing more and more detail with increasing distance. I know that Quake 3 uses LOD too, for example for player, weapon and ammo models. What I want to know is: when I create my own md3 models (for example a high-poly tree and the same tree with just a few polys), what do I need to do to make the game use the model's low-poly versions at a certain distance?
[url=http://www.victorkarp.com]Portfolio[/url] - [url=https://victorkarp.com/tutorials/quake-3-mapping-tutorials/]My Quake 3 mapping tutorials[/url] - [url=http://www.lvlworld.com/author/DaEngineer]My Quake 3 maps[/url]
Re: How to create static models with a LOD?
Static mapmodels (misc_model) are "baked" into the BSP during the compile process.
You just need to use dynamic models by using the model2 key within a func_*.
- Create a small caulk-brush (hidden in the ground but not in the void) and a origin-brush.
- Turn both brushes into a func_static.
- Add the dynamic model key (model2 models/mapobjects/mymap/tree.md3)
- In this case your lower poly models must be named: tree_1.md3 and tree_2.md3.
Do not include clip-brushes within the func_static. There's a clipping bug when using the model2-key.
The big problem is the really short range of the LOD effect. The "r_lodscale" cvar that controls the range is cheat protected. This is really a shame, because "r_lodbias" isn't cheat protected and does basically the same.
You just need to use dynamic models by using the model2 key within a func_*.
- Create a small caulk-brush (hidden in the ground but not in the void) and a origin-brush.
- Turn both brushes into a func_static.
- Add the dynamic model key (model2 models/mapobjects/mymap/tree.md3)
- In this case your lower poly models must be named: tree_1.md3 and tree_2.md3.
Do not include clip-brushes within the func_static. There's a clipping bug when using the model2-key.
The big problem is the really short range of the LOD effect. The "r_lodscale" cvar that controls the range is cheat protected. This is really a shame, because "r_lodbias" isn't cheat protected and does basically the same.

[url=https://sst13.de]Q3A Maps - by sst13[/url]
[url=https://steamcommunity.com/id/_sst13_/myworkshopfiles]Quake Live Workshop[/url]
[url=https://steamcommunity.com/id/_sst13_/myworkshopfiles]Quake Live Workshop[/url]
-
- Posts: 210
- Joined: Fri May 28, 2010 2:30 pm
Re: How to create static models with a LOD?
Great, thank you! That works just fine. That r_lodscale is cheat protected is indeed a problem. The map in which I want to use this LOD foliage is intended to be played with Eraser's EntityPlus mod. I'll ask him if he can remove the cheat protection for this cvar.
[url=http://www.victorkarp.com]Portfolio[/url] - [url=https://victorkarp.com/tutorials/quake-3-mapping-tutorials/]My Quake 3 mapping tutorials[/url] - [url=http://www.lvlworld.com/author/DaEngineer]My Quake 3 maps[/url]