DarklightGames / DarkestHour

Darkest Hour: Europe '44-'45
https://store.steampowered.com/app/1280/Darkest_Hour_Europe_4445/
69 stars 21 forks source link

Cambes En Plaine Advance #888

Closed AndrewTheel closed 6 years ago

AndrewTheel commented 7 years ago
kashash commented 6 years ago

Fixed almost all the github issues that were for cambes, but like ladder I tried and couldn't fix it, I've set up ladders before but this one I have problem with so I'd need help please I've optimized it as much as I could, added some more bsp to cut the nets on the map, but when it comes to the fps, the map is optimized as it can, all the statics have strictly low cull distance set on them, and any less trees and the map would lose its realistic appearance of how it was in real life, if any players have problems with fps they should lower the fog distance

AndrewTheel commented 6 years ago

Okay so first of all about optimization. After reviewing one of the laggiest parts of the map, I noticed 80% of the problem is the deco layers. Running at 5ms with only 100,000 triangles. The static time is only 2ms and running at 400,000 tri.

20171118114728_1

Notice how the deco is nearly 5 ms, the total ms is nearly 16 (sorry its hard to read). Anyways, I think if we remove the deco layers we'll save render time enough to drop down to 11-12ms or so.

Here we have portals that are doing absolutely nothing but chopping up the BSP (very bad)

I also noticed a very high texture count (above 400 textures is too high). All hidden and "unlit" surfaces on BSP buildings should be black and UNLIT. The reason being is that you reduce the chance that one of these hidden surfaces uses a texture not used in the level. But setting it unlit you reduce the lightmap complications, which can improve build time and lesson level size.

There is no reason to use such a big blocking volume to block the window. Blocking volumes also block free roaming spectators, those who parachute from the sky, etc. With a blocking volume this large, it would break the map from having parachuting, which sure it doesn't have them now, but there might be situations where units want to use the map in that way. Also having a blocking volume, but an opening the player can obviously get out is annoying. Imagine being alone in the house and having an entire squad come into the house after they've shot at you etc. and you try to escape to the roof only to find out that you can't and then you are shot because you were blocked by an invisible wall.

You can find it easy by searching the objectname of the static I have selected.

The lamp does not have a cull distance set

No cull distance on outhouse, but have them on larger shed

No cull distance(s)

You can prob put a high cull distance on these window frames

Use a high value like the trees

Found some palette

This is very concerning, not sure why this BSP bottom/face is not appearing, can't even select it like I can select invis BSP faces. Yikes!

This roof should not be BSP

Vegetation bAcceptProjectors I still found some with it on! Groups should be used sparingly and kept organized and updated. Otherwise they are not useful. I can't trust any of these groups. They don't include all of the statics they should AND there are just too many groups. I've recently discovered objects/actors have a limit to their groups string, so if its in 2-4 groups with long names, it'll cull them and the groups thing wont' even work. image

To make sure you have all the vegetation selected before making the vegetation bAcceptProjectors=false, you should begin by selecting as many different trees, hedges, bushes, grass, etc. Then slowly add them to a group. You can append a group by the plus button. Once you've added a bunch, turn off terrain and roam around in perspective looking for additional vegetation.

image

Add the next selections to the new veg group then, click the veg group to show and hide again (will update it). Do this until you cannot find ANY vegetation after roaming around for awhile.

Don't forget to check up against buildings or even inside them!

image

Once you have all the vegetation on one group, you can select all in the group and set the bAcceptProjectors to false.

Conclusion: I think after you've gutted the deco layer, the render MS will be 12 max, which is much better than 16. However, I bet it'll avg more like 10.

If I'm wrong then we can further improve FPS after that by making billboard trees and reducing fog, but lets hope I'm right.