Engine Trails and explosions .. possible fix
Posted: Mon Feb 01, 2016 12:22 pm
Just wanted to ask other peoples experiences with oolite.oxp.Norby.Trails.oxz
Often during explosions, trails goes up to 900 or so entities, bringing framerate down to 3 or 4 FPS for minutes at a time. Most people I've given OOLITE to, have this happen, and they get very frustrated during ship fights... It's a pity as trails look AMAZING!!!!
A good example is shooting at a refuel station. About 500 entities are created, even before it explodes, bringing FPS down to almost 0. Explosions often happen during fights (duh) which is when low-frame-rate becomes a joy-killer.
I've managed to reduce this happening by changing a few lines in trails.js .. give it a go if you like!
Dropping maximum entities down to 400 instead of 1000 makes a huge FPS difference during explosions..
if( a > 400 && w.$Length > 10 ) { //low fps or too much entity
Also, the TRAILS script has a hard-set of 15fps .. don't know about you but 15 FPS is way too jumpy. ... so having this higher by default would be cool
this.$MinFPS = 35; //if fall below then will reduce the max. dataKey number
The best fix would be to possibly remove trails on explosion fragments (which is again, a pity as it's quite pretty), but the FPS hit is just too much.
Often during explosions, trails goes up to 900 or so entities, bringing framerate down to 3 or 4 FPS for minutes at a time. Most people I've given OOLITE to, have this happen, and they get very frustrated during ship fights... It's a pity as trails look AMAZING!!!!
A good example is shooting at a refuel station. About 500 entities are created, even before it explodes, bringing FPS down to almost 0. Explosions often happen during fights (duh) which is when low-frame-rate becomes a joy-killer.
I've managed to reduce this happening by changing a few lines in trails.js .. give it a go if you like!
Dropping maximum entities down to 400 instead of 1000 makes a huge FPS difference during explosions..
if( a > 400 && w.$Length > 10 ) { //low fps or too much entity
Also, the TRAILS script has a hard-set of 15fps .. don't know about you but 15 FPS is way too jumpy. ... so having this higher by default would be cool
this.$MinFPS = 35; //if fall below then will reduce the max. dataKey number
The best fix would be to possibly remove trails on explosion fragments (which is again, a pity as it's quite pretty), but the FPS hit is just too much.