Jump to content

[KSP >= 1.3.0] TweakScale - Under Lisias' Management - 2.4.7.6 - 2024-0322


Lisias

Recommended Posts

42 minutes ago, chadillac said:

I'm having issues and I've narrowed it down to some interaction between Parallax and Tweakscale. I've already posted on the Parallax thread but I thought I'd ask here as well. I'm getting the message in the loading screen saying that certain .dll's cannot be found, and then parts do not scale. As soon as I remove parallax, it works fine. Any suggestions?

Any help would be greatly appreciated.

You (and Parallax) are being bitten in the SAS by a nasty KSP bug on the Assembler Resolver thingy  yada yada yada. TL;DR. when something borks being loaded due a faulty dependence, everything else trying to load something (or to use a thingy called Reflection) borks relentlessly due the bug. And since TweakScale makes heavy and critical use of exactly these two things. TweakScale yells when it detects this happened (because a faulty TweakScale will ruin your whole savegame).

Publish your full KSP.log on dropbox or something, and I will inspect it looking for the troublemaker. Chances are that there's a dependency missing somewhere, or perhaps something else conflicting with Parallax and then triggering that KSP bug I mentioned above.

Cheers!

Link to comment
Share on other sites

14 hours ago, jebycheek said:

Is there any chance that  TweakScale will able to change the plume (stock waterfall maybe?)and smoke scales along with the engine scale changes.:)

Yes, it's on the back log to support (or at least to try!) Stock Plumes:

https://github.com/net-lisias-ksp/TweakScale/issues/27

It's taking a bit longer than I had anticipated, however… :P 

In the mean time, you can install SmokeScreen and RealPlumes-Stock . TweakScale is supported by SmokeScreen:

Spoiler

On the other hand, Waterfall is also supported (with a glitch… :/ ) by installing TweakScale Companion for Frameworks:

https://github.com/net-lisias-ksp/TweakScaleCompanion_Frameworks/releases

The thing has a glitch that I still didn't managed to fix: when reverting to launch, the Waterfall effects lose the scaling… :( But other than that, it works.

Edited by Lisias
tyop! Surprised?
Link to comment
Share on other sites

1 hour ago, Lisias said:

Yes, it's on the back log to support (or at least to try!) Stock Plumes:

https://github.com/net-lisias-ksp/TweakScale/issues/27

It's take a bit longer than I had anticipated, however… :P 

In the mean time, you can install SmokeScreen and RealPlumes-Stock . TweakScale is supported by SmokeScreen:

  Hide contents

On the other hand, Waterfall is also supported (with a glitch… :/ ) by installing TweakScale Companion for Frameworks:

https://github.com/net-lisias-ksp/TweakScaleCompanion_Frameworks/releases

The thing has a glitch that I still didn't managed to fix: when reverting to launch, the Waterfall effects lose the scaling… :( But other than that, it works.

Oh!!!  that is just sweet! thank you man, can't wait to try, i say you're already accomplished a wonderful job,and by your talent It will be Solve someday .:D

Link to comment
Share on other sites

On 5/14/2022 at 11:23 PM, Lisias said:

You (and Parallax) are being bitten in the SAS by a nasty KSP bug on the Assembler Resolver thingy  yada yada yada. TL;DR. when something borks being loaded due a faulty dependence, everything else trying to load something (or to use a thingy called Reflection) borks relentlessly due the bug. And since TweakScale makes heavy and critical use of exactly these two things. TweakScale yells when it detects this happened (because a faulty TweakScale will ruin your whole savegame).

Publish your full KSP.log on dropbox or something, and I will inspect it looking for the troublemaker. Chances are that there's a dependency missing somewhere, or perhaps something else conflicting with Parallax and then triggering that KSP bug I mentioned above.

Cheers!

 

That would be incredible! Thanks. I took out everything but parallax and tweakscale to hopefully make things a little simpler.

https://www.dropbox.com/sh/6t9uj3q0x6yaakq/AAAxVVYeRF_Rw1S1glNyVQ0sa?dl=0

Link to comment
Share on other sites

2 hours ago, chadillac said:

That would be incredible! Thanks. I took out everything but parallax and tweakscale to hopefully make things a little simpler.

https://www.dropbox.com/sh/6t9uj3q0x6yaakq/AAAxVVYeRF_Rw1S1glNyVQ0sa?dl=0

Found it!

[LOG 11:20:09.486] AssemblyLoader: Loading assemblies
[WRN 11:20:09.488] AssemblyLoader: Assembly 'Kopernicus' has not met dependency 'ModularFlightIntegrator' V1.0.0
[WRN 11:20:09.488] AssemblyLoader: Assembly 'Kopernicus' is missing 1 dependencies
[ERR 11:20:09.620] ADDON BINDER: Cannot resolve assembly: Kopernicus, Culture=neutral, PublicKeyToken=null

[ERR 11:20:09.620] ADDON BINDER: Cannot resolve assembly: Kopernicus, Culture=neutral, PublicKeyToken=null

[ERR 11:20:09.626] AssemblyLoader: Exception loading 'ParallaxSubdivisionMod': System.Reflection.ReflectionTypeLoadException: Exception of type 'System.Reflection.ReflectionTypeLoadException' was thrown.
  at (wrapper managed-to-native) System.Reflection.Assembly.GetTypes(System.Reflection.Assembly,bool)
  at System.Reflection.Assembly.GetTypes () [0x00000] in <9577ac7a62ef43179789031239ba8798>:0
  at AssemblyLoader.LoadAssemblies () [0x000e6] in <39c0323fb6b449a4aaf3465c00ed3c8d>:0

Additional information about this exception:

 System.IO.FileNotFoundException: Could not load file or assembly 'Kopernicus, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies.
File name: 'Kopernicus, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null'

Parallax could not be loaded because Kopernicus wasn't loaded, and Kopernicus wasn't loaded because you forgot to install ModularFlightIntegrator!

Install ModularFlightIntegrator and things will be fine!

Cheers!

Link to comment
Share on other sites

NOTAM

Well, it's a bit embarrassing, but sheet happens and people borks. So do I now and then…. :blush:

Since 2.4.6.10 TweakScale is trusting KSP-Recall to keep KSP on its toes, applying fixes and patches for KSP's idiosyncrasies so TweakScale can focus on its core business (scaling) instead of trying to survive such idiosyncrasies (not to mention doing things in a way that could damage 3rd parties the same way KSP did to TS).

However… I missed a detail… :0.0:

When KSP 1.9.0 came and royally screwed up TweakScale on Editor, I didn't fully understood the problem at that time (I had less than 2 years of KSP modding at that time, I was still a rookie on this business) and ended up concluding it was a change on the KSP engine (and not a bug on Editor), so while doing my attempts to understand the problem, I ended up with a kludge on the Scale Engine core that resulted on things happening the way I intended on KSP 1.9. But that broke scaling for KSP < 1.9 (in special, KSP 1.4.4 to 1.7.3), what I "fixed" by adding yet another kludge on the Scaling Engine for [1.4.4 <= KSP <= 1.7.3].

Then, recently and after 2 years developing KSP-Recall, I became (hopefully) more experienced on this thing and realised that what I was doing on TweakScale was way less than ideal. Then I coded a proper work around for the problem that was screwing up TweakScale on KSP-Recall (this one reusable to every 3rd party with the same problem if needed) and released TweakScale 2.4.6.10.

But...

I forgot to remove the second kludge, and the after math is that TweakScale started to misbehave from KSP 1.4.4 to 1.7.3… (sigh). This appears to explain why I detected some increasing usage of older TweakScale versions (as 2.4.5.x ones) in the last months…. :blush:

Oh, well… At least people found their way around the problem.

To reflect this, I downgraded TweakScale 2.4.6.10, 2.4.6.11, 2.4.6.12 and 2.4.6.13 on CurseForge to be compatible only on [1.3.0 <= KSP <= 1.4.3] and [KSP >= 1.8.0] . TweakScale 2.4.6.8 and earlier should be fine (pending verification).

On the bright side, now that I know about the problem, I published a (hopefully) fix on the TweakScale BETA 2.5.0.44 (available only on github). Brave Kerbonauts that don't fear the Krakens are invited to beta test it on every supported KSP version for eventual bugs I may had allowed to pass trough - the Scaling Engines were significantly simplified on the process, and I think it's safer to spend some time double checking things before publishing a proper release with the fix.

For people willing to further learn about the problem, see https://github.com/net-lisias-ksp/TweakScale/issues/249.

Cheers.

 

Edited by Lisias
some entertaining grammars made less entertaining.
Link to comment
Share on other sites

Hello there!

I'm having a weird (and a bit annoying) bug with Tweakscale in KSP 1.12.3. When I import a craft to merge it with another one (and ONLY when I merge it), I have some parts (like here, the flag. It also happens with the Mystery Goo container) that are out of place, even though they're fine on the craft itself when loaded normally. I'm using Tweakscale 2.4.6.13 with latest KSP Recall.

https://imgur.com/a/qdf4eX3

Here's the log: https://drive.google.com/file/d/1mtv_1Ua-BOECx4uvGYm5LLI8fe1l6rj-/view?usp=sharing

So, any ideas?

 

Link to comment
Share on other sites

2 hours ago, hugoraider said:

Hello there!

I'm having a weird (and a bit annoying) bug with Tweakscale in KSP 1.12.3. When I import a craft to merge it with another one (and ONLY when I merge it), I have some parts (like here, the flag. It also happens with the Mystery Goo container) that are out of place, even though they're fine on the craft itself when loaded normally. I'm using Tweakscale 2.4.6.13 with latest KSP Recall.

https://imgur.com/a/qdf4eX3

Here's the log: https://drive.google.com/file/d/1mtv_1Ua-BOECx4uvGYm5LLI8fe1l6rj-/view?usp=sharing

So, any ideas?

Hummm… And by ALT-CLICK on them, it happens the same? 

Anyway, I'm checking this out. I need to check if it's a missing use case on TweakScale, or a missing use case on Recall.

Good thing it's happening with the Goo Container, so I can double check this on older KSP versions.

I'm working on it, I will be back to you soon.

— — POST EDIT — — 

I had reproduced it using a scaled up MK1 Inline Cockpit and two Goo Containers attached radially.

It appears to be related to radial attachments….

— — POST POST EDIT — — 

Unsurprisingly, it does not happens on KSP 1.8.1 .

So we have a bug on on the 19x scaling engine, or something is missing on KSP-Recall.

— — POST POST POST EDIT — — 

And now the problem is gone… Can't reproduce it again on 1.9.1….

— — POST POST POST POST EDIT — — 

@hugoraider, I found the "problem". :)

You have a craft file with a previous "version" of the AttachedOnEditor module. The latest KSP-Recall has an update on it, bumping it to V5. When you load a craft file with data from a previous release, it tries to migrate the info to the new specs - but not all data are available at this time, due the KSP >= 1.9 bug on Editor!

To fix the "problem", load the craft file that fails to be merged and save it. This will fully update the internal data to V5, and the next time you merge that craft file, it will work fine.

In essence, it's the same workaround I explained on this post:

(the subassemblies are just craft files used on a fancy new way).

A proper way to update his info is possible using the KSP Upgrade Pipeline thingy, but I'm still trying to figure out how to use it. Until there, this is the quickest way out of the mess.

Cheers.

Edited by Lisias
POST POST POST EDIT
Link to comment
Share on other sites

2 hours ago, hugoraider said:

Thanks for the quick reply! I tried your workaround and it works, but not in all cases. Like here, it actually makes things worse :0.0:

https://imgur.com/a/0o3YeLq

Damn. Send me the craft file, I need to eyeball it.

I suspect it's a missing use case on KSP-Recall by now.

In the mean time, rollback KSP-Recall to 0.2.4.3 and see if the situation improves.

Edited by Lisias
hit Save too soon.
Link to comment
Share on other sites

10 hours ago, hugoraider said:

Hi! 

I (more or less) reproduced the problem:

169170256-83ef5494-880a-4092-bdfc-edcf80

And created an issue on Recall for it : https://github.com/net-lisias-ksp/KSP-Recall/issues/44 (I think it's a missing use case on Recall, and not exactly a bug on it).

To tell you the true, it may be a similar problem I solved on Procedural Parts. With a bit of luck, a similar fix will do the trick.

I will come back to you ASAP - Day Job™ is demading more attention than usual this week, so I'm afraid I will have time for this only on the WeekEnd.

However, I have a hunch: perhaps by adding AttachedOnEditor on everything the problem may be mitigated (I had a somewhat similar misbehaviour recently on a system where AttachedOnEditor wasn't patched on some parts, as it's happening on the craft you provided on my rigged rig).

Backup everything (as this may backfire on us) and put this patch somewhere on the GameData where you will remember to remove it later (I suggest GamaData/__LOCAL/KSP-Recall.cfg).

@PART[*]:HAS[!MODULE[ModuleAsteroid],!MODULE[ModuleComet],!MODULE[KerbalEVA],!MODULE[ProceduralPart],!MODULE[WingProcedural]]:FINAL
{
        %MODULE[AttachedOnEditor]
        {
                active = True
        }
}

As a matter of fact, KSP-Recall 0.2.2.4 already does it when TweakScale is installed. Are you using Recall 0.2.2.3 or older? I couldn't download your KSP.log, as it was already on the trashcan when I tried to download it.

You will need to load and save the craft (to refresh the AttachedOnEditor internal data) before being able to attempt a merge with it.

In a way or another, let me know about the results.

Edited by Lisias
tyop! Surprised?
Link to comment
Share on other sites

2 hours ago, hugoraider said:

I tested your patch and it doesn't seem to work. And yes, I'm using KSP Recall 0.2.2.4.

Yep, I finally found something weird here. I found a weird NRE happening on a Stock part you are using (Heatshield0) that doesn't happens on a (almost) vanilla KSP 1.12.3 installment. Remove that Patch from your rig, it's useless.

Someone is screwing up the Heatshield0 , inducing AttachedOnEditor to bork, what kills the thread, what leads to that result I posted above.

It's unknown if it's the same thing happening to you (your screenshot is different from mine), but it's an anomaly no doubt.

I'm still working on it, I will advise any news.

Full details on https://github.com/net-lisias-ksp/KSP-Recall/issues/44

However… In the mean time you want to play the game, so right now I can give suggest you to remove the Heatshield0 from that craft file and see if the problem goes away,

If the problem is still there, I'm afraid that the easiest way out of this mess until I fix it is to remove TweakScale from your rig ;.; - what will prompt KSP-Recall to do not patch AttachedOnEditor on anything. The source of the problem will still be there, but since the triggers will not be in use, you will probably be able to keep playing in the mean time.

I will come back to you as soon as I have more news about this.

Link to comment
Share on other sites

Quote

Yep, I finally found something weird here. I found a weird NRE happening on a Stock part you are using (Heatshield0) that doesn't happens on a (almost) vanilla KSP 1.12.3 installment. Remove that Patch from your rig, it's useless.

Uh... I'm not sure to get this, which "patch" are you referring to?

Link to comment
Share on other sites

3 hours ago, hugoraider said:

Uh... I'm not sure to get this, which "patch" are you referring to?

That "GamaData/__LOCAL/KSP-Recall.cfg" one I posted a bit before and that did't worked for you!

Link to comment
Share on other sites

10 minutes ago, hugoraider said:

Oh, ok lol. Btw, maybe I installed it wrong? Cause I didn't have a KSP-Recall.cfg in LOCAL folder, so I created it and pasted your patch in it.

Almost surely not. That patch could be placed virtually anywhere, I suggested saving it on that __LOCAL thingy to easily locate and remove it there when needed (as we did now). 

But once I detected the Heatshield0 problem (and it was correctly patched with AttachedOnEditor), this eliminated any chance of that patch being necessary, because the trigger for the problem is AttachedOnEditor being patched on at least one part with something weird.

Link to comment
Share on other sites

1 hour ago, hugoraider said:

Alright, was just making sure. And did you figure out how to fix it yet?

Still having my cheeks mercilessly bashed by the problem.

This kind of problem I'm getting from AttachedOnEditor, historically, is related to parts being screwed up somehow by being mangled at runtime (as Procedural Parts does) or while being "Compiled" by the Part Compiler - something happens, the worker's thread is killed, and a lot of things are left behind - as creating the data structures AttachedOnEditor needs to work.

Checking my KSP.log that should be pretty similar to yours, I see a huge amount of exceptions being thrown by the Part Loader, so my current hypothesis is that that crapness is related to the problem at hands. As soon as I have time, I will hunt and remove all the parts borking the Part Loader and see if the situation improves (if any of that borked parts are being used on the sample craft, then we have one more evidence to corroborate the hypothesis).

Then I will reevaluate.

This thing is going to fight back...

Link to comment
Share on other sites

On 5/19/2022 at 5:21 PM, hugoraider said:

I see. Good luck with it then! :D

Found the source of the problem! (finally!)

The "Grus*" parts from Tantares are flawed somehow. I don't know yet what's happening with them, but the problem until the moment is only happening with them.

I initially considered that it could be a conflict or bad interaction between AttachedOnEditor and ModuleProceduralFairings (the only Module left after I started to dismantle the parts looking for the source of the problem), but when using the Stock Fairings (that also use the ModuleProceduralFairings), nothing wrong happened.

So it's something on the mentioned Tantares parts for sure. Couldn't figure out exactly what yet (I suspect it's something similar as the problem I had with Procedural Parts, but it's only a guess at this moment). The best (or less worst) work around I could find for now is to remove AttachedOnEditor (and also TweakScale in abundance of caution) from all the Grus parts that have ModuleProceduralFairing.

I'm trying to figure out a work around for the WeekEnd. Keep an eye on https://github.com/net-lisias-ksp/KSP-Recall/issues/44 .

— — — POST EDIT — — — 

@hugoraider, I'm stuck.

Besides having a lot of parts throwing exceptions on Part Load, a few others have yet new problems that are screweing up AttachedOnEditor. However, it is needed by the part nevertheless otherwise the parts would be scattered around while trying a merge (and probably ALT+Clicking them) - so we are in a catch-22 situation: can't use the AttachedOnEditor on the part, but can't use the part without AttachedOnEditor.

Further work on it seems fruitless to me because:

  • It's not something wrong on KSP-Recall neither TweakScale.
    • So there's nothing I can do on them
  • It's really something on some parts of Tantares (and relatives)
    • So it's no up to me to fix them
  • Historically, 3rd party add'ons were reticent on accepting my pull requests with the fixes
    • So it's usually a waste of my time trying to fix them myself.

I think you should talk with Tantares maintainers about this issue. I will gladly help to diagnose and fix the problem if this will lead to the problem being fixed on their side, but I ask you to understand that I reticent on doing it by myself.

Edited by Lisias
POST EDIT
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...