blowfishpro / B9PartSwitch

A Kerbal Space Program plugin designed to implement switching of part meshes, resources, and nodes
GNU Lesser General Public License v3.0
50 stars 33 forks source link

Q: Setting default SUBTYPE #127

Closed jsolson closed 5 years ago

jsolson commented 5 years ago

For an end user who wishes to change the default SUBTYPE to something other than the first one listed, would setting ModuleB9Partswitch currentSubtype to the desired SUBTYPE.name be work/be safe? Or is there a preferred method?

https://github.com/blowfishpro/B9PartSwitch/blob/17a67d59ae3c18f51d152da300c8c9a89b181524/B9PartSwitch/PartSwitch/ModuleB9PartSwitch.cs#L53

blowfishpro commented 5 years ago

I think it'll work. There's one feature it might interfere with but I don't think it's relevant here. Basically there's some code to "automatically" detect the correct subtype based on the part's resources if no subtype is currently assigned. This was designed to help for switching from stock or another switcher. But if the part in question has always used B9PartSwitch it shouldn't be an issue.

jsolson commented 5 years ago

Not extensively tested, but it appears to work without issue.

jsolson commented 5 years ago

No issues with this popped up over a couple weeks.