View Full Version : Mystery of the lagging starshells revealed!
http://i1231.photobucket.com/albums/ee503/rongel777/SH5Img2013-11-02_224320-1.png
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! :stare:
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!
vdr1981
11-03-13, 03:31 AM
Rongel, this is very important breakthrough , TY very much! :up:
- no gameplay effects, ships don't see you any better
So, with "default" starshels ships can actually see you better ?
Brilliant finding Rongel; this reduces our field of investigation considerably :up:
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. :hmmm:
- 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.
So, with "default" starshels ships can actually see you better ?
yep, likewise when you are within searchlight's beam :yep:
Rongel, this is very important breakthrough , TY very much! :up:
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.
- 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. :hmmm:- 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!
My guess is that SH 5's Granny-world doesn't understand the light system from the previous games.
Sounds plausible and... it sucks :-?
Sounds plausible and... it sucks :-?
Don't give up hope, gap! We are all waiting for the Wizard to return :D
Don't give up hope, gap! We are all waiting for the Wizard to return :D
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 :D :O:
stoianm
11-03-13, 10:43 AM
I noticed something like that.. related to lag.. some time ago. I forgot to tell you.... each time after I install mods... I make a mod for myself.. remove red flare. I modify. 2 lines.. in zones.cfg:
[DistressFlareWarship]
Multiplier=1.000000
Flotability=0.000000
Critic Flotation=0.300000
Armor Level=-1
HitPoints=130
Destructible=No
Critical=No
Effect1=Command_room_crewman_splinter_explosion_es cort, 40
;Effect2=Distress_Flare_Red, 75
FloodingTime=59.999996
CargoType=None
[DistressFlareMerchant]
Multiplier=1.000000
Flotability=0.000000
Critic Flotation=0.300000
Armor Level=-1
HitPoints=65
Destructible=No
Critical=No
Effect1=Command_room_crewman_splinter_explosion_me rchant, 40
;Effect2=Distress_Flare_Red, 75
FloodingTime=59.999996
CargoType=None
I just put in front of thos 2 lines '';'' to not be executed.... if I am remember well, tdw knows that this red flare is resource consuming, but I do not remember if he fixed that!
That is right stoianm, but I think Rongel was looking for a way to make flare effects lesser GPU intensive, without giving them up. And no, TDW has not addressed the proble yet :salute:
stoianm
11-03-13, 11:13 AM
That is right stoianm, but I think Rongel was looking for a way to make flare effects lesser GPU intensive, without giving them up. And no, TDW has not addressed the proble yet :salute:
I understood.. he succeeded only.. to keep the eye candy effects only.. it is better something than nothing for me, anyway.. I would like to use the half solution! :)
I understood.. he succeeded only..
More or less: if I understood correctly, starhells would appear as a bright star in the dark sky, but they wouldn't cast light :hmm2:
stoianm
11-03-13, 11:45 AM
More or less: if I understood correctly, starhells would appear as a bright star in the dark sky, but they wouldn't cast light :hmm2:
better than to have nothing.. like I have now!
http://www.world-of-smilies.com/wos_starwars/starwars023.gif
tonschk
11-03-13, 12:24 PM
Thank you :up: Rongel :yeah:
I understood.. he succeeded only.. to keep the eye candy effects only.. it is better something than nothing for me, anyway.. I would like to use the half solution! :)
It's easy to make warships to fire these no-lag starshells, just modify the materials.dat file, I can do that, but the merchant starshells and distress flares come from TDW and their files need editing too, and also the new FX update zone file removes the starshells. So i'm not sure how to proceed...
I'm not that keen on modifying TDWs work, best situation would be that he does the changes. Can't remember what the modding etiquette says... Is it okay to make this kind of patch???
It's easy to make warships to fire these no-lag starshells, just modify the materials.dat file, I can do that, but the merchant starshells and distress flares come from TDW and their files need editing too, and also the new FX update zone file removes the starshells. So i'm not sure how to proceed...
I'm not that keen on modifying TDWs work, best situation would be that he does the changes. Can't remember what the modding etiquette says... Is it okay to make this kind of patch???
TDW's flares are about identical to stock starshell effects. He just copied the effects/materials into new files, introduced the difference between red and white flares, and changed the way they are used in game: white flares fired by invisible guns, red flares triggered by compartment damage. That's all.
The new materials are stored in TDW_FXU_Flares_Materials.DAT. I don't think that editing that file and releasing it as a FXU-compatible patch, would break any etiquette rule, especially if we consider that it contains stock effects essentially. On the contrary, you would infringe the rules if you took FXU, changed a few features of it, and released it as whole new mod of your own. :yep:
SnipersHunter
11-04-13, 01:57 PM
Nice Thread
The new materials are stored in TDW_FXU_Flares_Materials.DAT. I don't think that editing that file and releasing it as a FXU-compatible patch, would break any etiquette rule, especially if we consider that it contains stock effects essentially. On the contrary, you would infringe the rules if you took FXU, changed a few features of it, and released it as whole new mod of your own. :yep:
Yep, maybe I'll release a mod in a few days, and just make sure that people know half of it is TDW's work! Hm, I think it would also need the unchecked ship-weapons file. :hmmm:
Here is another picture of the no-lag starshells in action, you can see that it lights the ocean level, but not the ships:
http://i1231.photobucket.com/albums/ee503/rongel777/SH5Img2013-11-03_194130.jpg
Yep, maybe I'll release a mod in a few days, and just make sure that people know half of it is TDW's work!
Imo your patch has little to do with FXU, as it "only" fixes a stock bug which, incidentally, is still present in the mod by TDW. On the other hand, making the patch compatible with FXU is an instrinsecal way to give TDW credit for his great work :up:
Hm, I think it would also need the unchecked ship-weapons file. :hmmm:
I don't get you here :hmmm:
vBulletin® v3.8.11, Copyright ©2000-2025, vBulletin Solutions Inc.