Realm667/WolfenDoom

Improving performance (general issue)

Opened this issue · 4 comments

  • Rewrite (some) EffectSpawner and /decorate/sfx classes using particles.
  • Started, ash and cinders converted. Consolidation of static methods into one helper class might be in order.
  • Optimize status bar widget code.
  • The overhead might be because of something similar to what has been removed in 8c6a454, needs testing.
  • Add a forced limit of zombie actors on C3M0_A (+remove them on previous zones after getting to the last?)
  • Restore (& optimize) UFO explosion actors from Chapter 2.
  • Optimize player and weapon Tick().
  • Abandon FastProjectile bullets for hitscan faux-projectiles.
  • Optimize Tick() for Base/Nazi classes (include checks for the actor being dead/out of player sight).

It's worth mentioning that raindrops can't be converted to particles because raindrops are 3D models. This is important for maps like C1M2 and C3M0_B.

Also, watch out for more complex movement code, like the Fireflies seen on INTERMAP. Particles cannot move in a non-linear fashion like that.

This might have been discussed earlier --- would it make sense to exclude dead Base actors (health <= 0) from culling?

Here are the stat vm 10-tic function call statistics on TEST_DLG (where culling is not needed at all) for two versions of code, the current BoA version and the one with a health <= 0 check in Tick():

Statistics

Current version: 6500 calls at map start, 39000 after spawning 100 WGuards with notarget, 39800 after idfa, 19400 after killing them and gathering all the weapon/ammo drops.
With a check: 6500 calls at map start, 25000 after spawning 100 WGuards with notarget (I wonder why), 25800 after idfa, 11700 after killing them and gathering all the weapon/ammo drops.

We however have large open maps, and I wonder if this could lead to even worse performance drops.

I am completely out of this discussion as I have no idea technically about this :)

Just gonna drop this too: SM02 goes very slow on my end at the start and looking also on top of the "icy" area you can see from the distance: Freezing and removing actors doesn't change much if anything, but using IDBEHOLD-L cheat improves greatly the experience in terms of framerate, so the problem comes mainly from SpotLights placed in map (which probably go through portals too).

Difference is 21-23 fps without cheat vs 60-70 fps with cheat on, Vulkan render, only Bloom enabled