Jump to content

[1.3.0] Filter Extensions 3.0.4 (Jul 11)


Crzyrndm

Recommended Posts

On 11/3/2016 at 4:35 PM, Crzyrndm said:

Several actually.


// remove the part from the stock categories using the stock categorisation method
@PART[*]:HAS[#manufacturer[xyz]]:NEEDS[FilterExtensions] // not entirely sure that's the correct syntax...
{
  @category = none
}

@SUBCATEGORY[xyz] // again, not sure if this is correct...
{
  @FILTER,* 
  {
    CHECK
    {
      type = subcategory
      value = xyz
      invert = true
    }
  }
}

@PART[*]:HAS[#manufacturer[xyz]]
{
  MODULE
  {
    name = PartModuleFilter
    subcategoriesToBlock = xyz
    //subcategoriesToAdd = 
  }
}

 

Done. Implemented sub menu for Omicron. Many thanks.

Quote

Updated to 0.1.7, implemented Filter Extensions sub menu for Omicron. You will need to install FE to this to function.

 

Edited by Climberfx
Link to comment
Share on other sites

So it seems the hide unpurchased option has been turned back on (probably from the last update) and I would like to turn it off. Unfortunately I cant find the icon at the space center to get to the options. I presume its getting stepped on by some other mod I have installed. Its not that big of a deal other then that I cant turn off said option. I was wondering if there was some other way to turn the option off or fix the app launcher? I browsed through the configs but I couldn't find anything.

Am I completely blanking on some obvious answer?

Link to comment
Share on other sites

@Crzyrndm

I've spent some time making the "duplicate part categories" bug reproducable. Could you maybe take a look investigating it please? It is very annoying, cause it updates "GameData\Squad\PartList\PartCategories.cfg" each startup, which in the end invalidates the modulemanager cache each run and the loading time difference is 3 vs 6 minutes in my installation which is suboptimal when streaming. :)

So, to reproduce it, just select via CKAN in a clean 1.22: Filter Extensions Plugin, Filter Extensions - Default Config, SpaceY Heavy Lifters. Unselect all recommended and sugested mods. Dependencies (ModuleManager) will get installed anyway.

Then start KSP, start a new Sandbox, go to the VAB. A file "GameData\Squad\PartList\PartCategories.cfg" will be created. It will only be created in this specific setup! (Or if one creates a real own custom category). Quit KSP.
Then start KSP, start a new Sandbox, go to the VAB. The file "GameData\Squad\PartList\PartCategories.cfg" will be updated and now you have TWO SpaceY custom categories. Quit KSP.
Then start KSP, start a new Sandbox, go to the VAB. The file "GameData\Squad\PartList\PartCategories.cfg" will be updated and now you have THREE SpaceY custom categories.... and so on.

I think that should explain it. It don't know why this happens but another observation is, that KSP-I and SpaceY are using Custom Categories in their setup. Without FE the custom categories will be shown, but NO "GameData\Squad\PartList\PartCategories.cfg" will be created. So I assume something in FE and a mod which uses custom categories makes KSP think that it needs to save the custom categories file.

EDIT: One more thing. FE-DefaultConfig was needed to reproduce this bug. When the FE-DefaultConfig was not installed, it did not happen.

Edited by Jebs_SY
Link to comment
Share on other sites

Well that is definitely more severe than I had originally assumed, however it also makes the root cause of the issue not of FE's making.

  • Remove FE
  • Install mod distributing a "user category" (eg. SpaceY).
  • Run game, create/delete/modify a user category
  • Restart game, observe duplicated distributed user category.

In summary: the system has not been setup to support distributed user categories very well and any modification of categories while the game is running will summon this bug. Some module manager trickery is probably going to be the surest solution to this.

Edited by Crzyrndm
Link to comment
Share on other sites

@Crzyrndm

Thx for taking time and looking into this. Did I understand this right?:

-As soon as a PartCategories.cfg exists, the way like SpaceY and KSP-I add their custom category leads to category doubles each KSP new start.
-This seems to be a problem KSP uses this file
-Without PartCategories.cfg this is no problem
-A initial PartCategories.cfg can/will be created if a user creates a own custom category manually or if Filter Extensions is installed

So FE isn't the cause but triggers a "bug". Also a user creating a custom category triggers the "bug".

Is that right? Could you maybe still change FE that it behaves the way, that no PartCategories.cfg will be created? Even it's just a workaround? Should work at least as long as a user doesn't create a custom category. (Btw, I never have)

Do you know if SpaceY/KSP could introduce their custom categories without triggering the bug? Which side must/should do the module manager trickery?

 

Link to comment
Share on other sites

The issue is that any time the game saves the part categories .cfg, any category that originated outside the stock file gets duplicated. Saving occurs for any modification of the user categories and a particular function of FE, so they all act as triggers for the duplication. The duplication occurs because when things get saved, KSP puts every catgory into a single file, but doesn't remove the original from elsewhere in GameData. On the next load, you get two of the category (one from the original distributed source, one from the category saved by KSP)

I am exploring options to prevent FE triggering this, but it would be useful if the distributed categories would only be valid when there wasn't a duplicate loaded (ie. on first load, it comes from the distributed original, but it disables itself on subsequent loads where KSP has created a copy) but I'm not sure that's possible with just MM

Link to comment
Share on other sites

@@Crzyrndm I just spotted a weird glitch with the Coatl Aerospace's ProbesPlus mod not appearing in FE's filter by manufacturer listing. I suspect this may possibly be caused by the root folder name including a space ("Coatl Aerospace") which is not the case with any of my other part mods.

After noticing this in my current heavily modded build I tested with a fresh 1.2.2 install with only FE 2.8.0.2, ProbesPlus 0.14.2 (and bundled dependencies) and MM 2.7.5. With this install only Squad appeared under the Manufacturers filter.

As far as I know this is the only mod affected and I can work around it by adding my own CATEGORY definition based on 'tag = coatl'.

 

On another note, Hooligan Labs Airships also creates a custom category that gets duplicated on each game load (like KSP-I and Space-Y discussed above).

Link to comment
Share on other sites

2 hours ago, Crzyrndm said:

Could I get some verification that this fixes the issue and doesn't blow anything else up in the process...

Looks like a partial fix.

Tested using new DLL and Hooligan Labs Airships mod. Repeated starts did not cause duplicating of HLA category in VAB.

But...  creating a custom category manually in the VAB caused a new copy of the HLA category to appear on next restart. No further copies would spawn on subsequent restarts but each time I created another custom category a restart would create another HLA duplicate each time.

Repeated test with Space-Y - same results.

Link to comment
Share on other sites

Problem with 2.8.1: I lose all parts in the editor (VAB - didn't check SPH) except for the pods category.  ALL parts - stock, modded.  Pods, modded and stock, are fine.

Problem persists either through manually installing (after direct direct download from Github), or using CKAN.

Rolling back to 2.8.0.2 is fine.  I'll stick with this for now.

No logs showed, so can't provide any.

Edited by MaxxQ
Link to comment
Share on other sites

24 minutes ago, MaxxQ said:

Problem with 2.8.1: I lose all parts in the editor (VAB - didn't check SPH) except for the pods category.  ALL parts - stock, modded.  Pods, modded and stock, are fine.

Problem persists either through manually installing (after direct direct download from Github), or using CKAN.

Rolling back to 2.8.0.2 is fine.  I'll stick with this for now.

No logs showed, so can't provide any.

Ran into the same issue. Relieved that it's not just me. 

Link to comment
Share on other sites

2 hours ago, ctbram said:

Same issue here.  I lose all parts in any section except the capsule tab all others are blank.  Rolling back to last release

 

Same problem here. Rolling back solves the issue.

Edited by Deviouz
Link to comment
Share on other sites

Oh dear, and I said "looks good to me".
I tested it in a just started career and thought it is normal, that there are no parts yet. However, no parts at engines and fuel tanks had should be alarming, but I was more focussed on the duplication issue.
Sorry all and Crzyrndm. :(

Edited by Jebs_SY
Link to comment
Share on other sites

9 hours ago, MaxxQ said:

Problem with 2.8.1: I lose all parts in the editor (VAB - didn't check SPH) except for the pods category.  ALL parts - stock, modded.  Pods, modded and stock, are fine.

Problem persists either through manually installing (after direct direct download from Github), or using CKAN.

Rolling back to 2.8.0.2 is fine.  I'll stick with this for now.

No logs showed, so can't provide any.

Same problem.

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...