Jump to content

[KSP >= 1.8] KSP Recall - 0.0.6.1 - 2021-0209


Recommended Posts

KSP Recall - a bag of tricks and stunts to overcome KSP blunders, screw ups and borks, trying hard to do not introduce new blunders, screw ups and borks.

In a Hurry

Description

It aims to need minimal coupling (if any)with existent code, as well to be selectively injected on the broken parts in order to prevent unholy interactions with third-party modules that decide to fix things their own way.

The following fixes are available once installed (and applied only when needed!):

  • Resources being reset to prefab when a part has his Resources changed by an Add'On (as TweakScale) (i.e., by Alt+Click a part, or by using symmetry) on KSP 1.9.x . 
  • Losing Resources' amount settings when cloning parts (Alt+Click) on KSP 1.9.x
    • As described here.
  • Parked crafts (even without wheels) drifting the Heading randomly on KSP >= 1.8
    • Crafts with wheels also drifts, but due a different problem - still to be tackled down.
    • This was discussed here.
  • I.C.A. (Instantaneous Craft Annihilation) on KSP 1.11.0 when launching or switching back to vessels with some older parts, when the vessel is over a static with collider (does not happens when the craft is directly over the PQS ground)
  • More workarounds will be implemented as requested.

Known Issues

None at the moment. :) 

 

Installation

This release has no hard dependencies anymore.

You need to have Module Manager 4.0.2 or newer installed.

 

How to use

This is not intended to be "used" by end-users. It provides services to Add'On authors and fixes automatically some problems on some Fuel Switches.

Currently, the following services are available:

Automatically restores Resources changed by Fuel Switches.
 

Spoiler

 

As the title says, KSP-Recall detects when something changed on the craft (while Editing it) and tries to restore the Resources as intended by the Add'On authors, brute forcing the right way over the KSP 1.9.x. had brute forced its way (that breaks some Add'Ons).

However, and you as an user must be aware of it, some Fuel Switches don't cope very well with others. It's highly probable that you will have problems on installing more than on Fuel Switch on your KSP, because some of them install themselves on the parts without caring about any other one already there.

On a rule of thumb, it's possible to have more than one Fuel Switch installed on KSP. What you can't is have more than one Fuel Switch installed on the same part, and this is where most Fuel Switches authors are stomping their own toes.

Right now, this is what it's known to the date:

  • Interstellar Fuel Switch
    • Works without KSP-Recall.
    • it coded it's own Resource Management, so it's imune to KSP 1.9 "bruteness".
  • Firespitter
    • I detected no problems on it
  • Anything that supports (or it's supported by) TweakScale
    • TweakScale already handles KSP-Recall, so anything that makes use of Scale_Redist is already covered
    • Modular Fuel Tanks is one of that Add'Ons, as long nobody shoves it on parts that already have another Fuel Switch.
  • B9 Parts Switch should work. As longe there're no other Fuel Switch installed on the same part.
  • Other fuel switches:
    • As long the OnEditorVesselModified is fired on each change (or one of the Custom Events from Recall, see below), it should work fine.
    • Please report on this thread anything that you thing is wrong. I'm fixing them as I'm aware of them.

 

 

Preventing resetting ot the default (stock) configurations of resources on Add'Ons that customizes it.
 

Spoiler

 

Issue #1.

Add'Ons that supports TweakScale using Scale_Redist.dll but do not change resources themselves will be automatically fixed - TweakScale "calls" KSP Recall as the last step of the rescaling, anything you do on IRescalable::OnRescale(ScalingFactor factor) will be preserved.

Add'Ons that also changes the Part's resources outside of the OnRescale callback or without direct support for/from TweakScale will need to add the following lines of code every time their Part Resources are changed:





            // send Resource Changed message to KSP Recall if needed
            if (0 != this.part.Resources.Count)
            {
                BaseEventDetails data = new BaseEventDetails (BaseEventDetails.Sender.USER);
                data.Set<int> ("InstanceID", this.part.GetInstanceID());
                data.Set<Type>("issuer", this.GetType ());
                part.SendEvent ("OnPartResourcesChanged", data, 0);
            }

// note: If your part can be set to have <ZERO> resources, omit the "if" above to hint Recall that it should delete any internal cache for the part

It's extremely important to send this event only at the last moment possible, after changing the resources. There's no guarantee about when this Event will be handled (it can be handled right on the spot, or only next week - nobody knows). You can only be sure about when it will not be handled: before being issued. So do whatever you need, and add that lines above before the end of the function/method/procedure/whatever to avoid risking Recall caching your resources before you are done.

Add'Ons that support TweakScale by handling the OnPartScaleChanged event need to add that lines above too as the last step of their scaling tasks. Since Events are completely asynchronous, there's a good chance that by the time TweakScale sends OnPartResourceChanged to Recall, you could not  handled yet (or be in the middle of the handling!!!) your OnPartScaleChanged , and so Recall will essentially undo what you had done on your part (as it will get a snapshot of the current Resources before the change).

 

 

WARNING

This Add'On is being used with success by most users, but yet... please make backups - just in case.

Bug reports are encouraged, feel free to to it here or in the Issue Tracker. Ideally both. :)

And, finally, KSP-Recall WORKS FINE WITH Module Manager. Anyone telling you you need an alternative fork of MM is telling you nonsense.

 

Edited by Lisias
0.0.6.1 is on the Wild. Distribution channels updated as time allows
Link to post
Share on other sites

First!

Remember to use the mod S.A.V.E

On 3/1/2020 at 2:13 PM, Lisias said:

This release temporarily needs the installation of KSPe (from KSP API Extensions /L). Next release will have the needed functionalities embedded to avoid this hassle. Link on the Download Page from Github.

WARNING
Lasciate ogne speranza, voi ch'intrate

 

[snip]

Like

(I ran out of likes for today)

Congrats for the new release, @Lisias

Edited by VoidCosmos
Link to post
Share on other sites

@Lisias, you have forgot to follow your own thread :) And this is quite fast solution. Things to do, though is to change TS dependency on CKAN. Once it is tested and confirm to be stable, TweakScale 2.4.3.10  and later for KSP 1.9.x should have dependency on KSP Recall to work properly. CKAN staff should be notified to add both, KSP Recall and TS dependency in metadata files.

Link to post
Share on other sites
4 hours ago, kcs123 said:

@Lisias, you have forgot to follow your own thread :)

Closed fixed. :sticktongue:

 

4 hours ago, kcs123 said:

And this is quite fast solution.

I got lucky, and TweakScale is blessed with engaged users.

The most time consuming part of the job is diagnosing the bug and confirmation of a deterministic M.O. for the misbehaviour (and this is the reason I'm near traumatised by Race Conditions - my worst experiences ever on Software Development were due Race Conditions), and the users did that for me.

What I didn't expected was spending 50% of the development time fighting the weird Unity serialisation support, however. Well, I think I nailed it too.

But I don't think this is ready yet - the worst part is to avoid stomping third parties toes, what can be a problem as historically some authors are less than collaborative on these issues.

 

4 hours ago, kcs123 said:

Things to do, though is to change TS dependency on CKAN. Once it is tested and confirm to be stable, TweakScale 2.4.3.10  and later for KSP 1.9.x should have dependency on KSP Recall to work properly. CKAN staff should be notified to add both, KSP Recall and TS dependency in metadata files.

That will be a challenge, as I don't know how CKAN would behave on such a Stunt. TweakScale is 100% compatible to every KSP release since 1.4.0 (the only exception is 1.8.0 - for while, I will tackle is down too next weekend), once the glitches are workarounded. But Recall would be needed only on some KSP releases - and don't know how to tell CKAN about this.

Perhaps a "suggested" dependency for 1.9.x (and in the near future, 1.8.0)? I make Recall a hard dependency of TweakScale (what's not, things are working by events), and I can shut TweakScale out of the KSP releases that don't need Recall.

Another problem is the patches themselves. A way of selectively patching things depending if the KSP release being run would be incredibly useful (and I'm not the only one asking for this), but the current status quo suggests not to rely on MM for anything but the strictly unavoidable, so I need to cook some safety measures on runtime to avoid working on KSP releases without the problem (and you know that people will just install this thing no matter what! :D ).

Well, since I need some time to proper test this stunt, I have some time to figure out what to do on CKAN. A new release 2.4.3.11 for TweakScale is on the way, anyway, so I will update netkan for .11 only and save ckan guys a bit of work.

I will tell you the true: I'm worried about how this will behave with Fuel Switches (specially IFS, that is imune to the problem Recall is fixing now and I don't want to be the source of a new problem instead of solving this one).

Link to post
Share on other sites

Quick stuff: Just installed KSP Recall, and it gave me a terrifying warning about it being installed wrong in a 999_ folder. Thing is, it already came like that inside the zip file. I will attempt to correct this and will update afterwards.

Also, I'm gonna attempt to run this with Snark's Simple Fuel Switch, and see how it goes.

EDIT: something went wrong: https://imgur.com/a/tV2YwRC

(alt-copied the tank)

I think I'm gonna have to test this with a pure install. Hang on...

Edited by Vegetal
Link to post
Share on other sites

Did a pure install, 1.9.1.2788, installed Recall and API extended, and the latest Tweakscale.

Still no sauce: https://imgur.com/AbfjoXP

On the pic you can see my Gamedata folder. Again, I alt-copied the fuel tank, and this was the result. I also changed the 999 on the Recall folder to 000.

 

Edited by Vegetal
Link to post
Share on other sites
5 hours ago, Vegetal said:

Quick stuff: Just installed KSP Recall, and it gave me a terrifying warning about it being installed wrong in a 999_ folder. Thing is, it already came like that inside the zip file. I will attempt to correct this and will update afterwards.

Yeah. It was the first thing I saw after I came back to it. I had updated the thing to 0.0.1.1 due it, it's fixed on the latest now.

Sorry for that.

 

5 hours ago, Vegetal said:

Also, I'm gonna attempt to run this with Snark's Simple Fuel Switch, and see how it goes.

Yeah. Fuel Switches are going to be a problem. The "fix" will be a no brainer, however - but I need to implement a new event handler on the next 0.0.2.0 release, as the handler I'm using now is TweakScale specific.

 

5 hours ago, Vegetal said:

Did a pure install, 1.9.1.2788, installed Recall and API extended, and the latest Tweakscale.

Still no sauce: https://imgur.com/AbfjoXP

Humm.. Interesting. I need to reassess the situation.... I will be back soon

------- POST EDIT --------

Of course, it didn't worked for you. I'M AN IDIOT. :mad:

You need to use TweakScale 2.5 Beta, as I just realised that I compiled it in DEBUG mode, what shoves tons and tons of log messages on KSP.log, delaying the execution of the event handler on the other PartModule!!!

We have a Race Condition here! And I completely missed that!

What's happening is that the code is sending a event to the listeners before executing some code. Events are asynchronous, so God knows when the listener will handle it - so we just send them after we are 100% done, but on the current code, we have the event being fired before all things are done - so, in a now heavily multithreaded environment as we have nowadays, there's a good chance that the listener would run before TweakScale finish everything.

If the listener runs before TweakScale do its magic, it will backup the original values, and when the cloning is done, it essentially reapplies the original values instead of the intended ones.

Damn, sorry by wasting your time.

I will fix TweakScale Beta to behave in a more sensible way, I will update KSP-Recall accordingly and I will advise here and on the TweakScale thread.

Edited by Lisias
DAMN! :( - I can't emphasise how idiot I was.
Link to post
Share on other sites
3 hours ago, Lisias said:

Damn, sorry by wasting your time.

Hah, not at all man. I just barely know the basics in python, so I'm glad to help by at least testing stuff, as I don't have the knowledge to code like you guys.

Btw, you rock :wink:

Link to post
Share on other sites

Announce.

KSP Recall 0.0.2.0 and TweakScale /L Beta 2.5.0.9 are available for the brave Kerbonauts willing to risk their SAS with these stunts.

Really, really, use these only on disposable KSP instalments - not even S.A.V.E. can save our sorry SAS if something on KSP Recall goes wrong and start to play havoc. Exercise prudence - I need your help on testing these things, but I don't want you risking your savegames on it.

Good Luck! :) 

-- POST EDIT --

Some screenshots here (with the sample craft).


75645696-bcd76700-5c25-11ea-8e76-19c1c60

Edited by Lisias
Pictures or it didn't happened!
Link to post
Share on other sites
5 hours ago, Lisias said:

Announce.

KSP Recall 0.0.2.0 and TweakScale /L Beta 2.5.0.9 are available for the brave Kerbonauts willing to risk their SAS with these stunts.

Really, really, use these only on disposable KSP instalments - not even S.A.V.E. can save our sorry SAS if something on KSP Recall goes wrong and start to play havoc. Exercise prudence - I need your help on testing these things, but I don't want you risking your savegames on it.

Good Luck! :) 

-- POST EDIT --

Some screenshots here (with the sample craft).


75645696-bcd76700-5c25-11ea-8e76-19c1c60

Está bem @Lisias. Is it that dangerous!?
Link to post
Share on other sites
5 hours ago, VoidCosmos said:
Está bem @Lisias. Is it that dangerous!?

Potentially yes. I'm brute forcing my way over Squad's brute force way. :P

Something goes wrong, you end up with a Craft with the resources completely messed up.

Since I still don't know how much brute was Squad on the matter :sticktongue:, anything I had missed can silently mangle your crafts (and savegames once you launch them), and by the time we realise it you probably had spent some days on the game, with me having to buy from SpaceX the first ticket to Mars to save my neck. :)

For starters, I confirmed a new KSP misbehaviour on Reverting the Flight to the Vehicle Assembly, in which radially attached parts are getting displaced towards inside the part they're attached. On big crafts it's easy noticeable, on smaller ones perhaps not - and if you don't hit the New button on the spot, subsequent Loads and Saves will end up corrupting your crafts. [it sounds like a missing "clear the workspace" while Loading and Reverting, but since this is being noticed on KSP Recall + TweakScale, i need to at least diagnose properly the thing]

What's dangerous is not necessarily what I'm doing (it's a bit, but I know my trade), but what I still need to do and I don't know yet.

(I like living on Earth, don't wanna flee to Mars! :D )

Edited by Lisias
Added a clarification - italics between brackets
Link to post
Share on other sites
On 3/1/2020 at 4:44 PM, Lisias said:

That will be a challenge, as I don't know how CKAN would behave on such a Stunt. TweakScale is 100% compatible to every KSP release since 1.4.0 (the only exception is 1.8.0 - for while, I will tackle is down too next weekend), once the glitches are workarounded. But Recall would be needed only on some KSP releases - and don't know how to tell CKAN about this.

Perhaps a "suggested" dependency for 1.9.x (and in the near future, 1.8.0)? I make Recall a hard dependency of TweakScale (what's not, things are working by events), and I can shut TweakScale out of the KSP releases that don't need Recall.

Only thing that pop up on my mind is to use separate version numbers. For KSP 1.9.x and further, use higher version number for TS. That can have dependency on KSP reacall. For KSP 1.4.x up to 1.8.x use lower version numbers without dependency on KSP recall. TS code could still be same, even same compile, just need to be distributed separately with different version number. Rudolf made similar stunt with IR Next. That is to satisfy CKAN syntax and handling of various KSP and mod versions.

For users who do manual installs, it might be oversighted need of new dependency. For those, "simple" warning in TS code if it run on KSP 1.9.x instance should do a trick. It will be hard to help those who don't read forum posts and warning messages on screen, no matter of font size and color.

Link to post
Share on other sites
On 3/2/2020 at 1:09 PM, kcs123 said:

Only thing that pop up on my mind is to use separate version numbers. For KSP 1.9.x and further, use higher version number for TS. That can have dependency on KSP reacall. For KSP 1.4.x up to 1.8.x use lower version numbers without dependency on KSP recall. TS code could still be same, even same compile, just need to be distributed separately with different version number. Rudolf made similar stunt with IR Next. That is to satisfy CKAN syntax and handling of various KSP and mod versions.

Your idea made me have another one. Let's see if it sticks.

I'm heavily biased on keeping the PACKAGE name tied to the PRODUCT, but things doesn't needs to be this way. I can have different life cycles for the Product and for the Package - I already started this stunt with the Companions, but this ones on the patch level.

TL;DR: The current "Symbol" for TweakScale on CKAN has reached EoL. It will be deprecated, with a substitution being pushed on the next release.

That substitution will be targeted to the KSP version in use:

  • TweakScale Support for KSP 1.4.x
    • And now it's easier to deliver for KSP 1.3 and 1.2 too!!
  • TweakScale Support for KSP 1.5.x
  • TweakScale Support for KSP 1.6.x
  • TweakScale Support for KSP 1.7.x
  • TweakScale Support for KSP 1.8.x
  • TweakScale Support for KSP 1.9.x

Technically, only 1.9.x and "Everthing else" are really needed, but this way it's easier to the Common Kerman to cope!

Each Package will have TweakScale Core (just a fancy name for the current TweakScale, that will be as it is) as dependency, and this one will be essentially the same for everybody (as it is until nowadays), as well anything else I have to cook for the thing to work fine on that environment.

TweakScale 2.4.3.12 will be "final TweakScale" from the CKAN point of view, and it will be tied to 1.8.x forever on the NetKan file. I will check the netkan documentation about showing warnings on install, I think I remember reading something about this.

SpaceDock keeps the same, CurseForge keeps the same, Github keeps the same, KSP-AVC users will use the same .version as usual - these guys are already used to do things manually, it will not be worse to support than people installing older TweakScale copies (embedded on updates of some Add'Ons) over a newer one.

And the nice thing about it is that I don't need to update two or more packages on each TweakScale new release - the dependency check will do the trick by itself, new "Support" ckan packages will only be necessary if I need to change the dependencies for that package.

We call this 'Meta Packages" on the FOSS World.

--- POST EDIT --- 

There's some things I need to do in order to finish the 2.4.3.x series that will demand more time, and I feeling the need to publish KSP Recall support on it as soon as possible. So I will push .11 tonight with support for KSP Recall, and postpone the final "CKAN" release for the .12

Edited by Lisias
post edit
Link to post
Share on other sites

Well, I did some testing, and I think the results might point you in the right direction...

https://imgur.com/tg80ZtQ

https://imgur.com/kkH3RS3

Ok, so, the parts being displaced on revert, like what is shown in those pictures, you already knew. Thing is, I tested with a bunch of other stuff, and that didn't happen. I tested all the rover wheels, and the only affected is the one on this picture - the one that comes with the expansion, forgot the name. I tested engines, tanks, crew capsules, structural beams, most didn't suffer from this issue.

The only culprits so far are this wheel, and LFO tanks. LF tanks didn't show this behavior, the foil tanks also didn't, and even the Twin Boar, which is half engine, half tank, didn't.

It wasn't a complete test, I just had a hunch it was a type-specific issue and chose some parts to test. Hope this helps somewhat man!

EDIT: On the rover picture you can even see scaled I-beams and solar panels, and they didn't have the same issue as the wheels.

Edited by Vegetal
Link to post
Share on other sites
17 hours ago, Vegetal said:

Well, I did some testing, and I think the results might point you in the right direction...

https://imgur.com/tg80ZtQ

https://imgur.com/kkH3RS3

That's wonderful news! So it's a problem on some parts, not something happening on the code (or a combination of new code and missed details on the config files. perhaps - I will check).

What's really matter is that this is not caused by anything TS and Recall is doing, it's a misbehaviour que was detected due resizing. So I can push this into mainstream, after making it "safe for public consumption" (i.e., internalising some features from KSPe to eliminate the dependency, and coding safety measures to prevent being installed wrongly).

------ POST EDIT --------

It's a combination of parts.

Resized Mk0 LF tanks and Resized Advanced Nose Cone Type B does not triggers the Wandering effect. 

Resized FL-T400 LFO tanks and Resized Advanced Nose Cone Type B does triggers the Wandering effect. 

Resized FL-T400 tanks tanks and Resized Advanced Nose Cone Type A does not triggers the Wandering effect. [FIXED THIS ONE]

Edited by Lisias
Typed something in a hurry, fixed above!
Link to post
Share on other sites

A new Event to support Third Parties' Add'Ons in need to having their resources preserved was added and it's currently available for evaluation:

            // send Resource Changed message to KSP Recall if needed
            if (0 != this.part.Resources.Count)
            {
                BaseEventDetails data = new BaseEventDetails (BaseEventDetails.Sender.USER);
                data.Set<int> ("InstanceID", this.part.GetInstanceID());
                part.SendEvent ("OnPartResourceChanged", data, 0);
            }

See OP for details.

KSP Recall 0.0.2.0 (currently on the wild) support this call.

-- -- POST EDIT -- -- 

This Event is now deprecated. See OP for the current Event. (it still works, but will be removed on the a future release, probably 0.1.x.x)

Edited by Lisias
Event deprecated
Link to post
Share on other sites

So, i've tried latest tweakscale beta and ksp-recall together and run into weird issue, i couldnt find any reasony why it happens, i dont know if it's happening to me only etc. Here is the thing;

- Game stuck on loading screen; https://drive.google.com/file/d/1C4trQgbHrOZev4cpv2MQE3PxV-yY6qyk/view

Only new mods i've installed are tweakscale and ksp recall so i tried deleting ksp recall and ta da, game loads properly, but i know ksp recall is now pretty important to tweakscale, i want to find solution.

here's the log file; https://drive.google.com/open?id=1SBafIiHkb5AWFOJEut7Dqdqtef9WEg3y

i will think about what did went wrong more but just wanted to let you know, maybe you'll notice something wrong there.

Link to post
Share on other sites
3 hours ago, qromodynmc said:

So, i've tried latest tweakscale beta and ksp-recall together and run into weird issue, i couldnt find any reasony why it happens, i dont know if it's happening to me only etc. Here is the thing;

- Game stuck on loading screen; https://drive.google.com/file/d/1C4trQgbHrOZev4cpv2MQE3PxV-yY6qyk/view

Only new mods i've installed are tweakscale and ksp recall so i tried deleting ksp recall and ta da, game loads properly, but i know ksp recall is now pretty important to tweakscale, i want to find solution.

here's the log file; https://drive.google.com/open?id=1SBafIiHkb5AWFOJEut7Dqdqtef9WEg3y

i will think about what did went wrong more but just wanted to let you know, maybe you'll notice something wrong there.

You forgot to install KSPe (KSPAPiExtensions/L). This dependency will be embedded on the next release of KSP Recall, if you prefer to wait a bit.

Be advised that TweakScale 2.4.3.11 will have KSP Recall support, so you don't need to hush into using TweakScale Beta just because of it. TweakScale Beta can change patches and interfaces, what can ruin your savegame on the long run.

Huummm... Do you know what? I'm pushing TweakScale 2.4.3.11 and KSP Recal 0.0.2.1 tonight. Hold it just a little bit, buddy.

-- -- -- POST EDIT -- -- -- 

Update de Visual Studio had bitten me. Still updating, damn it.

Jesus Christ, Microsoft, I bought a Mac to get rid of this!!! :mad:

-- -- -- POST POST EDIT -- -- -- 

:mad::mad::mad::mad::mad::mad::mad::mad::mad:

03_I-hate-Microsoft.png

-- -- -- POST POST POST EDIT -- -- -- 

@qromodynmc, TweakScale 2.4.3.11 is on the wild, check the announce. Please use this one.

KSP Recall is being updated to get rid of the dependency in a couple hours max.

Cheers!

Edited by Lisias
AAAARGHHH!!!!
Link to post
Share on other sites

Announce.

We are now in Pre-Release status! :) I have some confidence that this stunt my work fine, after all! :D 

KSP Recall 0.0.2.2 Pre-Release and TweakScale 2.3.4.11 (Release) are available for the brave Kerbonauts willing to risk their SAS with these stunts.

Exercise prudence - this thing is still not properly tested with Fuel Switches. Use S.A.V.E. just in case.

Good Luck! :) 

-- -- POST EDIT -- -- 

I had borked on the deployment of the 0.0.2.1, fixed it and re-released it.

Edited by Lisias
0.0.2.2
Link to post
Share on other sites

A strange new behavior emerged.

Installed the latest stuff (Recall 0.0.2.2, Tweak beta, NO api extensions) after deleting the old stuff.

Tested loading a flight with scaled parts (except no radial attached ones) after coming back to the space center, as I encountered bugs in other mods when I did that before - parts out of alignment etc - but nothing wrong until that.

Tried creating a ship with radial tanks for testing the same thing, this happened: https://imgur.com/JC7aOYJ

As soon as I right clicked on the radial tanks to bring up the PAW, this happened, and the FPS tanked noticeably hard. After I clicked "new vessel", FPS came back to normal, but right click behavior didn't. Exited the game and came here to report on this. Forgot to get any logs though :(

Link to post
Share on other sites

 I felt a great disturbance on the Scale, as if millions of lines of code suddenly cried in
Null Reference Exceptions and were suddenly silenced by empty try catches.

I fear something noncompliant has happened...

4 hours ago, Vegetal said:

Tried creating a ship with radial tanks for testing the same thing, this happened: https://imgur.com/JC7aOYJ

Investigating. I don't like the smell of this. :/

Spoiler

giphy.mp4

SQU... (i mean
 KRAAAAAAAAAKENS!!!

 

Link to post
Share on other sites
8 hours ago, Vegetal said:

A strange new behavior emerged.

Installed the latest stuff (Recall 0.0.2.2, Tweak beta, NO api extensions) after deleting the old stuff.

Tested loading a flight with scaled parts (except no radial attached ones) after coming back to the space center, as I encountered bugs in other mods when I did that before - parts out of alignment etc - but nothing wrong until that.

Tried creating a ship with radial tanks for testing the same thing, this happened: https://imgur.com/JC7aOYJ

As soon as I right clicked on the radial tanks to bring up the PAW, this happened, and the FPS tanked noticeably hard. After I clicked "new vessel", FPS came back to normal, but right click behavior didn't. Exited the game and came here to report on this. Forgot to get any logs though :(

I have confirmation, but - and again following your previous hunch - only when a Making History part is involved (didn't tried Breaking Par.. I mean, Ground yet).

You don't need to launch or recover vessels (thanks God), I launched stock only crafts in a sequence and didn't noticed any (perceptible at least) misbehaviour. But as soon as I used a scaled FX-TX440 (from Making History), I reproduced your issue (not exactly as yours, I got a PAW for Variants instead of what you got, but everything else is the same - including the CPU sky rocketing until exiting VAB).

I noticed an infinite repetition of the following Exception on the KSP.log.

[EXC 22:21:47.901] NullReferenceException: Object reference not set to an instance of an object
	UIPartActionResourceItem.SetSymCounterpartsAmount (System.Double amount) (at <48dcb08e2e1542e2af1286b02d2eb072>:0)
	UIPartActionResourceEditor.onSliderChangeProcess () (at <48dcb08e2e1542e2af1286b02d2eb072>:0)
	UIPartActionResourceEditor.Setup (UIPartActionWindow window, Part part, UI_Scene scene, UI_Control control, PartResource resource) (at <48dcb08e2e1542e2af1286b02d2eb072>:0)
	UIPartActionWindow.AddResourceEditorControl (PartResource r) (at <48dcb08e2e1542e2af1286b02d2eb072>:0)
	UIPartActionWindow.SetupResourceControls (PartResource r, System.Boolean clearFirst, UI_Scene scene, System.Int32& controlIndex) (at <48dcb08e2e1542e2af1286b02d2eb072>:0)
	UIPartActionWindow.CreatePartList (System.Boolean clearFirst) (at <48dcb08e2e1542e2af1286b02d2eb072>:0)
	UIPartActionWindow.UpdateWindow () (at <48dcb08e2e1542e2af1286b02d2eb072>:0)
	UIPartActionController.UpdateActiveWindows () (at <48dcb08e2e1542e2af1286b02d2eb072>:0)
	UIPartActionController.UpdateEditor () (at <48dcb08e2e1542e2af1286b02d2eb072>:0)
	UIPartActionController.Update () (at <48dcb08e2e1542e2af1286b02d2eb072>:0)
	UnityEngine.DebugLogHandler:LogException(Exception, Object)
	ModuleManager.UnityLogHandle.InterceptLogHandler:LogException(Exception, Object)
	UnityEngine.Debug:CallOverridenDebugHandler(Exception, Object)

Well... I think KSP Recall way of solving the problem is inducing Making History parts to a bork. At least it works on Stock Parts, so I'm not doing something too much exoteric, it's something specific to Making History (until the moment).

Well, I have some ideas to test. I'll be back on this matter soon.

Really thank you, @Vegetal, KSP Recall (and me) would be in a deep pile of rectangular pieces of paper :sticktongue: without your help - I just don't have time these days to do exploratory tests as you are doing, I just would not be able to catch these misbehaviours!! Thanks again!

Edited by Lisias
Link to post
Share on other sites

I don't know why you think only expansion parts cause this. I just replicated the error with any fuel tank here, even Mk3 tank fuselages.

What I noticed: surface attaching a single tank doesn't seem to cause any trouble, console stays normal when I right click the tank. The problem arises when I try to use any level of symmetry. It looks like something in the code isn't prepared to handle copying the tank around the vessel. At least that's what I think with my limited knowledge of all this.

And again, my pleasure to help. I already used this mod a lot:cool:

EDIT: Mega weird...if you place a tank below your capsule, and alt-copies it to place it radially with symmetry, nothing wrong happens. It only goes wrong when you pick a new tank on the parts list and try to surface attach it with symmetry. No hunch from me this time, I'm gonna let the professionals figure this one out :huh:

Edited by Vegetal
Link to post
Share on other sites
On 3/4/2020 at 10:58 PM, Vegetal said:

I don't know why you think only expansion parts cause this. I just replicated the error with any fuel tank here, even Mk3 tank fuselages.

Until this moment, all the glitches I had found had a MH part attached on the craft. No craft using only MH parts had such a glitch - and I tested some of them.

So, at least for the subset os tests I'm doing, MH parts are always involved on the mess, while the same craft without MH parts worked well.

 POST EDIT

My testing procedures were biased. The MH parts were always involved on the mess because I was attaching them by last, and so, I was taking them from the Part List, as the Stock ones were already on the craft.

The biases tests that followed the incident, so, reinforced my bias as I was testing what I was wanting to see...

"We formulate our questions based on the answers we want to hear."
House, Gregory. 

However, I have a problem... I managed to build this thing without having the glitch, and this craft has no MH parts. I had, even, added more parts to it right now, randomly, trying to trigger the problem - but everything is working right no matter I scale things before or after getting them from the Part List and shoving and attaching them...

75944612-ea671f00-5e76-11ea-937b-544cfd8

/POST EDIT

 

On 3/4/2020 at 10:58 PM, Vegetal said:

What I noticed: surface attaching a single tank doesn't seem to cause any trouble, console stays normal when I right click the tank. The problem arises when I try to use any level of symmetry. It looks like something in the code isn't prepared to handle copying the tank around the vessel. At least that's what I think with my limited knowledge of all this.

Cloning is involved for sure - as it the only thingy I'm messing up for now. 

What I found is that the problem is not on the symmetry itself, but in the presence of a MH part on the craft. Or at least, on the MH parts I randomly choose.

When I managed to reproduce your issue, I used stock tanks on the radially attached subtrees, but scaled down an MH tank on the main body.

Hummm.... I attached the subtrees on the MH tank. perhaps the problem is not on the symmetry, but on the attachment!!!

 

On 3/4/2020 at 10:58 PM, Vegetal said:

And again, my pleasure to help. I already used this mod a lot:cool:

Users like you is the foundations of this Community :) , believe me. Add'Ons without users are... "userless". :sticktongue:

 

On 3/4/2020 at 10:58 PM, Vegetal said:

EDIT: Mega weird...if you place a tank below your capsule, and alt-copies it to place it radially with symmetry, nothing wrong happens. It only goes wrong when you pick a new tank on the parts list and try to surface attach it with symmetry. No hunch from me this time, I'm gonna let the professionals figure this one out :huh:

Interesting... I will keep it in mind while I do some more testings before bedtime...

Edited by Lisias
I was wrong. But I was right too!!! o.O
Link to post
Share on other sites

Having the same issues as you mentioned although seems FSFuelswitch seems to maybe be having issues with this behind the scenes. Noticed when using the workaround that Vegetal mentioned about cloning

Quote

EDIT: Mega weird...if you place a tank below your capsule, and alt-copies it to place it radially with symmetry, nothing wrong happens. It only goes wrong when you pick a new tank on the parts list and try to surface attach it with symmetry. No hunch from me this time, I'm gonna let the professionals figure this one out :huh:

After doing that the fuel or resource is just gone from the PAW menu entirely. I can use Fuelswitch to put the fuel back but Launching the craft shows a lot of this in the log

[LOG 20:21:38.998] [PartSet]: Failed to add Resource -1154601244 to Simulation PartSet:1929 as corresponding Part Viklun-60 Liquid Fuel Tank-3747106852 SimulationResource was not found.
[LOG 20:21:39.017] [TweakScale] WARNING: No valid member found for diameter in Part for <unk>
[ERR 20:21:39.048] Error: FSFuelSwitch Mass Discrepancy detected in part 'bluedog.thorShortTank'.

Additionally, and I dont know if this will help any but I was trawling the forum looking for updates of various mods I've added to my game and noticed the following old post in Snacks! from a user by the name of GraczNet they posted a very interesting picture that looks to have a similar problem to the image posted by Vegetal.

0aS89HC.png

Original Posted is here

If that is the case that then maybe the same preexisting bug from as far back as 1.8.1 that is being teased out by this mod as well. <shrugs>

 

My solution to the issue was to place a single radial item then using the PAW tweakable and turning off KSP Recall and the grabbing that item and using symmetry on it.

Moddings so much fun huh :D Think I'm going to have to burrow down into ksp and figure out whats interacting with what far to much kraken bait is installed right now to debug anything lol.

Anyway, back to lurking per usual. I'll be keeping an eye on this thread though.

Link to post
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...