Possible misbehaviour on a still unknown Add'On with KSP-Recall
Lisias opened this issue · 13 comments
Fellow Kerbonaut hugoraider is being screwed by what appears to be a misbehaviour triggered by an unholy interaction between KSP-Recall and (probably) B9PS.
The problems happens only when merging an existent craft into the current one. The misbehaviour is remarkably similar to what happens when AttachedOnEditor
is needed but it's absent:
Craft file: Vega 3.craft.zip
This craft needs:
- Bluedog DB
- Conformal Decals
- New Tantares
- Tantares
- Tantares LV
- Tantares SAF
- Tantares SP
- Gemstone LV (not sure)
Most dependencies weren't installed (on purpose). Only Shabby (and 0Harmony), due Conformal Decals, were installed while reproducing the problem as below:
What more or less matches the screen shot provided by the user.
Mission: Search and Destroy (the bug)
I think this may be related to #66 too (crafts appears to be rerooted before being merged).
It worths to be mentioned that the Attaching Nodes are completely missing on the merging craft - what apparently suggests that B9PS was the one initialising them - what suggests we have a problem similar to the one on Procedural Parts ( #41 ).
Found something weird. With all the mentioned add'ons installed (with all the dependencies), I found that the problem I detected on my rig was due this exception:
[LOG 09:32:53.539] [KSP-Recall.AttachedOnEditor] TRACE: RestoreCurrentAttachmentPoints for <NO VESSEL>-HeatShield0:FFE5DB88
[EXC 09:32:53.541] ArgumentOutOfRangeException: Index was out of range. Must be non-negative and less than the size of the collection. Parameter name: index
System.ThrowHelper.ThrowArgumentOutOfRangeException (System.ExceptionArgument argument, System.ExceptionResource resource) (at <9577ac7a62ef4317
System.ThrowHelper.ThrowArgumentOutOfRangeException () (at <9577ac7a62ef43179789031239ba8798>:0)
KSP_Recall.AttachedOnEditor.AttachedOnEditor.RestoreCurrentAttachmentNodes () (at <4fcb81485a754384981c83d6e7a0fc8d>:0)
KSP_Recall.AttachedOnEditor.AttachedOnEditor.RestoreAttachments () (at <4fcb81485a754384981c83d6e7a0fc8d>:0)
KSP_Recall.AttachedOnEditor.AttachedOnEditor.Update () (at <4fcb81485a754384981c83d6e7a0fc8d>:0)
UnityEngine.DebugLogHandler:LogException(Exception, Object)
KSPe.Util.Log.UnityLogDecorator:UnityEngine.ILogHandler.LogException(Exception, Object)
ModuleManager.UnityLogHandle.InterceptLogHandler:LogException(Exception, Object)
UnityEngine.Debug:CallOverridenDebugHandler(Exception, Object)
Happening where AttachedOnEditor
was working on the HeatShield0
. But this part is a Stock one, and once I removed all that add'ons, this part behave while merging a craft with it.
So we have someone screwing up things here. And it's not me.
It's weird and almost surely unrelated.
I edited the craft file to replace HeatShield0
with HeatShield1
(this last part doens't borks), but the problem remains. So this NRE is not causing neither affecting the problem.
So, I removed the following directories
- GameData/Tantares/parts/z_deprecated_3
- GameData/Tantares/parts/z_deprecated_4
- GameData/Tantares/parts/z_deprecated_5
- GameData/Tantares/parts/z_deprecated_6
- GameData/Tantares/parts/z_deprecated_7
- GameData/Tantares/parts/z_deprecated_8
- GameData/Tantares/parts/z_deprecated_9
as well also:
- Tantares/parts/core_pirs/_mira_crew_s1_1.cfg
- Tantares/parts/core_polyus/_rotanev_aeroshell_s2_1.cfg
- TantaresSP/parts/core_ye8/_ye8_solar_s1_1/ye8_solar_s1_1
Not all z_deprecated parts were at fault, but a huge load of them were, so I took some shortcuts in order to hush the diagnosis. I removed them all. :)
But yet, nothing changes. The problem is still there. :(
On the other hand…. A huge crapload of Exceptions are being thrown by the Part Loader:
Let's remove the affected parts and see what happens...
Oukey. So I removed SimpleAdjustableFairings and B9PartSwitch (as it complained about SAF) to see what happens.
Unsurprisingly, same problem. Whatever is happening, apparently is related to ModuleProceduralFairing
.
So, it's related somehow to ModuleProceduralFairing
, and now I need to check if it's something related to AttachedOnEditor
interacting with it, or if it's something wrong with the "Grus" parts on Tantares.
So I made this craft :
Using a Fairing as root. merge test.craft.zip
And it was merged all right:
Variations of the merge test
craft worked as well, as long all the parts involved were stock.
So, no. There's no conflict between AttachedOnEditor
and ModuleProceduralFairing
.
So whatever is happening, is on Tantares for sure.
Temporary workaround: [EDIT: DIDN'T WORKED]
GameData/__LOCAL/KSP-Recall/Tantares.cfg
@PART[grus*]:HAS[@MODULE[ModuleProceduralFairing]]:FINAL
{
-MODULE[AttachedOnEditor],* { }
-MODULE[TweakScale],* { }
}
I bluntly removed every part that was throwing an Exception on KSP.log, no matter how silly was the Exception or where.
I removed AttachedOnEditor
and TweakScale
from the affected parts (the Grus thingies with ModuleProceduralFairing
.
Tailored a simplified version of the test craft. Vega 3 kpado.craft.zip
Conclusion: The AttachedOnEditor
is needed on the affected parts, otherwise we see the parts scattered around as demonstrated by the screenshot. But something broken on some Tantares parts (and there are a lot of broken parts, as it appears) is screwing up with KSP-Recall.
Exactly what I'm unsure if I should purse, because it's not up to me to fix every single broken AddOn on the face of Kerbin.