SUBSIM Radio Room Forums



SUBSIM: The Web's #1 resource for all submarine & naval simulations since 1997

Go Back   SUBSIM Radio Room Forums > Silent Hunter 3 - 4 - 5 > SH5 Mods Workshop
Forget password? Reset here

Reply
 
Thread Tools Display Modes
Old 11-02-13, 06:08 PM   #1
Rongel
Grey Wolf
 
Join Date: Jan 2009
Location: Finland
Posts: 859
Downloads: 174
Uploads: 0
Default Mystery of the lagging starshells revealed!



Normally this kind of situation would melt your computer and halt it for 10 seconds. But in this setting there was absolutely no lag. Not even a millisecond! The reason for the lag seems to be quite simple: the light node in starshells materials in material.dat file. I replaced the main node to be just normal 4/100 node and all lag was gone! So it is fixed?! No!

Removing the light node removes also the light from the ships and the light bonus that enemy units would get. So basicly my modded starshells/flares work like this:

- working starshells/flares that sparkle in the sky
- working waterlevel reflection
- absolutely no lag!
- no light reflecting to ships
- no gameplay effects, ships don't see you any better

I made also test and changed TDW's merchant ship starshells and flares, and lag was gone from there also. So basicly we can get "eye candy" effects, distress flares and starshells, but they don't have any real effect.

To get this working, somekind of light that SH 5 understands should be added to the flares, but as far as I know, there isn't any. SH 5 doesn't seem to have any actual light sources except the sun and the moon. So I rest my case now, maybe some more HC-modders know how to fix this completely, still I think it's better than nothing!
Rongel is offline   Reply With Quote
Old 11-03-13, 03:31 AM   #2
vdr1981
Navy Seal
 
Join Date: May 2010
Location: Србија
Posts: 6,078
Downloads: 581
Uploads: 13


Default

Rongel, this is very important breakthrough , TY very much!

Quote:
Originally Posted by Rongel View Post
- no gameplay effects, ships don't see you any better
So, with "default" starshels ships can actually see you better ?
vdr1981 is offline   Reply With Quote
Old 11-03-13, 04:40 AM   #3
gap
Navy Seal
 
Join Date: Jan 2011
Location: CJ8937
Posts: 8,215
Downloads: 793
Uploads: 10
Default

Brilliant finding Rongel; this reduces our field of investigation considerably

Two thoughts:

- as I have told you a few weeks ago, SHIII and SH5 starshells are pretty similar when looked on file. Yet, afaik, SHIII isn't affected by the same lagging issue as SH5; at least not as much. This is pretty weird considering that SH5 is an evolution of the previous game, and makes me to wonder if the culprit is some of the (4/2) node attributes which might have changed since SHIII, rather than the node itself.

- SH5's and, if memory serves me well, SHIII's starshell omni light effects are animated, probably for simulating light trembling. In SH5, this effect has a rate of one frame every thirtieth of second, and can be a serious fps eater. I am pretty sure that removing the LightAnimation node, or toning its frame rate down, would make the game much smoother when the starshell effect is played, and wouldn't affect starshell's functionality.

Quote:
Originally Posted by vdr1981 View Post
So, with "default" starshels ships can actually see you better ?
yep, likewise when you are within searchlight's beam
__________________
_____________________
|May the Force be with you!|
...\/
gap is offline   Reply With Quote
Old 11-03-13, 05:53 AM   #4
Rongel
Grey Wolf
 
Join Date: Jan 2009
Location: Finland
Posts: 859
Downloads: 174
Uploads: 0
Default

Quote:
Originally Posted by vdr1981 View Post
Rongel, this is very important breakthrough , TY very much!

So, with "default" starshels ships can actually see you better ?
Thanks! Yes, with default starshells ships get a boost to visual range, it's easy to see with the "visual sensors" activated in the map/TAI map-mode.
Quote:
- as I have told you a few weeks ago, SHIII and SH5 starshells are pretty similar when looked on file. Yet, afaik, SHIII isn't affected by the same lagging issue as SH5; at least not as much. This is pretty weird considering that SH5 is an evolution of the previous game, and makes me to wonder if the culprit is some of the (4/2) node attributes which might have changed since SHIII, rather than the node itself.
Quote:
- SH5's and, if memory serves me well, SHIII's starshell omni light effects are animated, probably for simulating light trembling. In SH5, this effect has a rate of one frame every thirtieth of second, and can be a serious fps eater. I am pretty sure that removing the LightAnimation node, or toning its frame rate down, would make the game much smoother when the starshell effect is played, and wouldn't affect starshell's functionality.
I have a background in SH 4, and the starshells seem to be identical, and there wasn't no lag in SH 4. My first test was just like you suggested to remove the LightAnimation-node, but it had no effect, starshells lagged just like before. So it wasn't the culprit.

When I had made the non-lagging starshell, I tried to add the omni-light to sub-node, but as soon the light node was there, the lagging started again. Even when I changed the omni light to particles.dat lag began again. So to me it seems that there can't be any other reason than the omnilight-node.

It lights the ships really beautifully, it's direction is also calculated, and I think this causes stress to computer. There is even a small lag when the effect goes out. My guess is that SH 5's Granny-world doesn't understand the light system from the previous games. Infact there doesn't seem to be any "real lights" in SH 5, even the lights in the bunker and in the sub are just bright 3D objects with a particle halo around, they don't emit actual light at all!
Rongel is offline   Reply With Quote
Old 11-03-13, 07:13 AM   #5
gap
Navy Seal
 
Join Date: Jan 2011
Location: CJ8937
Posts: 8,215
Downloads: 793
Uploads: 10
Default

Quote:
Originally Posted by Rongel View Post
My guess is that SH 5's Granny-world doesn't understand the light system from the previous games.
Sounds plausible and... it sucks
__________________
_____________________
|May the Force be with you!|
...\/
gap is offline   Reply With Quote
Old 11-03-13, 09:55 AM   #6
Rongel
Grey Wolf
 
Join Date: Jan 2009
Location: Finland
Posts: 859
Downloads: 174
Uploads: 0
Default

Quote:
Originally Posted by gap View Post
Sounds plausible and... it sucks
Don't give up hope, gap! We are all waiting for the Wizard to return
Rongel is offline   Reply With Quote
Old 11-03-13, 10:19 AM   #7
gap
Navy Seal
 
Join Date: Jan 2011
Location: CJ8937
Posts: 8,215
Downloads: 793
Uploads: 10
Default

Quote:
Originally Posted by Rongel View Post
Don't give up hope, gap! We are all waiting for the Wizard to return
Yep after long pondering and careful consideration, I have come to the serious conclusion that we are at a deadlock. Only a miracle, or the Wizard in person, can rescue us
__________________
_____________________
|May the Force be with you!|
...\/
gap is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -5. The time now is 07:00 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright © 1995- 2025 Subsim®
"Subsim" is a registered trademark, all rights reserved.