Jump to content

Script Lag: How to tell if you have it and how to fix it


thernn

Recommended Posts

Hi Skyrim Lovers,
I am sure many of us have been plagued by the horrors of script lag. I run over 300 mods with many merged so that I can get below the 255 mod limit. This includes script heavy mods such as Wet and Cold, Footprints, INPC, DCO and many others. I too have suffered from debilitating script lag caused by all these mods. However through browsing online I have found ini tweaks that can nearly remove this problem. While others may have found these tweaks it is often debated whether or not these tweaks work and many may be reluctant to try them. I have performed a test that shows the effectiveness of these tweaks and I have provided pictures showing scripting lag with and without these tweaks.
To see how bad your script lag is you will need a mod called Convenient Horses. This mod requires Skyrim 1.9.32.0 and SKSE and you will also need SkyUI to access the MCM menu.
The reason that we need access to Convenient Horses's MCM menu it contains a script latency tester. This can be located under Main and is the 3rd option under General. Now I recommend to let it run for at least a minute and see what your estimated latency is. It would usually take my script lag about 20 seconds to really get going. Keep in mind that events like people talking to you and especially opening menus will cause a spike and this should be ignored. We just want your average lag when you are standing and running around.
In a perfect world your script latency should be around 50ms but 100ms is just fine. Anything 150ms or above is likely going to cause trouble. Even if you are in the optimal range I would recommend that you go ahead and make these tweaks anyway as I've found that it also reduces script lag spikes that can cause the game to stutter.
I have uploaded here images of my script lag with and without the ini tweaks.
You can see that with a vanilla skyrim.ini my script lag is 1600 ms outside and nearly 800 ms inside. HOWEVER with these tweaks I will give you my script lag is now 86ms outside and 96ms inside. That is a MASSIVE drop and all I have done is add a few lines to Skyrim.ini ! My processor is an i7 ultrabook model so it is TDP throttled and is basically comparable to a higher end desktop i3. So this will help with older processors too as the game is not taking advantage of them.
So now to show you these tweaks which will be done under the PAPYRUS category. A vanilla skyrim.ini PAPYRUS category should look like this. These are the only changes I made to get this huge difference.
[Papyrus]
fPostLoadUpdateTimeMS=500.0
bEnableLogging=0
bEnableTrace=0
bLoadDebugInformation=0
To reduce your script lag you should change your Papyrus section to this.
[Papyrus]
fUpdateBudgetMS=4 (Start at 1.2 and increase by .5)
fExtraTaskletBudgetMS=4 (Start at 1.2 and increase by .5)
fPostLoadUpdateTimeMS=1000
bEnableLogging=0
bEnableTrace=0
bLoadDebugInformation=0
Another correction thanks to chanchan below. Do not increase those values willy-nilly. They should ALWAYS be below the script fire value that your FPS allows. For example, 60FPS gives you a maximum of 16ms, 35FPS gives you a value of 30ms, and so on.
Thanks for reading and let me know if you have any questions, comments or tweaks for me to try.
Edit: I hope this was the right forum section.
Edit Edit: Hang on making some tweaks based on a reddit discussion.
Updated: Please read Mastercobia's post here www.reddit.com/r/skyrimmods/comments/22rbk5/whats_the_best_papyrus_tweaks_to_use/cgq4qk0
Edited by thernn
Link to comment
Share on other sites

Thank you again. I am running at 40 fps and I've stabilized at 4.5 ms. The script latency stopped ballooning at that point. So I'm not close to that limit. I will pass that on to the other post on reddit.

Edited by thernn
Link to comment
Share on other sites

  • 1 year later...

 

Hi Skyrim Lovers,
I am sure many of us have been plagued by the horrors of script lag. I run over 300 mods with many merged so that I can get below the 255 mod limit. This includes script heavy mods such as Wet and Cold, Footprints, INPC, DCO and many others. I too have suffered from debilitating script lag caused by all these mods. However through browsing online I have found ini tweaks that can nearly remove this problem. While others may have found these tweaks it is often debated whether or not these tweaks work and many may be reluctant to try them. I have performed a test that shows the effectiveness of these tweaks and I have provided pictures showing scripting lag with and without these tweaks.
To see how bad your script lag is you will need a mod called Convenient Horses. This mod requires Skyrim 1.9.32.0 and SKSE and you will also need SkyUI to access the MCM menu.
The reason that we need access to Convenient Horses's MCM menu it contains a script latency tester. This can be located under Main and is the 3rd option under General. Now I recommend to let it run for at least a minute and see what your estimated latency is. It would usually take my script lag about 20 seconds to really get going. Keep in mind that events like people talking to you and especially opening menus will cause a spike and this should be ignored. We just want your average lag when you are standing and running around.
In a perfect world your script latency should be around 50ms but 100ms is just fine. Anything 150ms or above is likely going to cause trouble. Even if you are in the optimal range I would recommend that you go ahead and make these tweaks anyway as I've found that it also reduces script lag spikes that can cause the game to stutter.
I have uploaded here images of my script lag with and without the ini tweaks.
You can see that with a vanilla skyrim.ini my script lag is 1600 ms outside and nearly 800 ms inside. HOWEVER with these tweaks I will give you my script lag is now 86ms outside and 96ms inside. That is a MASSIVE drop and all I have done is add a few lines to Skyrim.ini ! My processor is an i7 ultrabook model so it is TDP throttled and is basically comparable to a higher end desktop i3. So this will help with older processors too as the game is not taking advantage of them.
So now to show you these tweaks which will be done under the PAPYRUS category. A vanilla skyrim.ini PAPYRUS category should look like this. These are the only changes I made to get this huge difference.
[Papyrus]
fPostLoadUpdateTimeMS=500.0
bEnableLogging=0
bEnableTrace=0
bLoadDebugInformation=0
To reduce your script lag you should change your Papyrus section to this.
[Papyrus]
fUpdateBudgetMS=4 (Start at 1.2 and increase by .5)
fExtraTaskletBudgetMS=4 (Start at 1.2 and increase by .5)
fPostLoadUpdateTimeMS=1000
bEnableLogging=0
bEnableTrace=0
bLoadDebugInformation=0
Another correction thanks to chanchan below. Do not increase those values willy-nilly. They should ALWAYS be below the script fire value that your FPS allows. For example, 60FPS gives you a maximum of 16ms, 35FPS gives you a value of 30ms, and so on.
Thanks for reading and let me know if you have any questions, comments or tweaks for me to try.
Edit: I hope this was the right forum section.
Edit Edit: Hang on making some tweaks based on a reddit discussion.
Updated: Please read Mastercobia's post here www.reddit.com/r/skyrimmods/comments/22rbk5/whats_the_best_papyrus_tweaks_to_use/cgq4qk0

 

 

I just read the post you linked to, and boy did you guys save my skyrim life. Skyrim became more stable and no more unreasonably high script lag. Thanks a lot bro.

Link to comment
Share on other sites

  • 1 year later...
  • 2 months later...

You really shouldn't be updating ANY of the ini values without knowing what they do.

And posts like these should not be made unless you EXPLAIN what the tweaks do.

 

If you don't know, don't post, lest we get inundated with the already endless flood of broken game posts.

Link to comment
Share on other sites

If no visual signs, biggest one will be in the log.. stack dumps. But that's if the scripts involved are screwed up in such a way to cause them(like unrestricted OnHit events, etc). INI changes can't help/prevent script lag. It's on the coder to know what the heck he is doing.

Edited by Rasikko
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...