Jump to content

[1.8.x] Oh Scrap!- A ScrapYard based Part Failure and Reliability Mod 2.0.1 (07/12/2019)


severedsolo

Recommended Posts

My first two attempts at a Munar orbiter both failed due to problems with new equipment...the first one lost all attitude control - fortunately I was already pointed on course for a Munar transfer burn, so I altered the burn length to send it onto a collision course instead of a flyby. Got some good science on the way down :)  The second had a fuel tank rupture and is currently dead in orbit around Kerbin - have to clean that up sometime. The third...well, the third actually achieved a retrograde flyby of the Mun on a free return trajectory and came back with lots of sweet sweet science.

I'm starting the think about redundancies and flying shakedown missions for various parts...it's awesome :)

Link to comment
Share on other sites

Beta 8 (0.8) Now Available

  • Added changelog to mod folder for easy reference.
  • Fixed baseChanceOfFailure not being exposed properly in EngineFailureModule
  • Fixed Trash Part Event not showing in the right click menu (for real this time).
  • Added difficulty setting to auto-trash a part if it's above the safety threshold.
  • Fixed issue where Editor Failure Rates could be cached, and therefore invalid.
  • Added option to toggle failure highlighting on a per-part basis from the right-click menu once a failure has occurred.
Link to comment
Share on other sites

Hi @severedsolo, I’m having a few issues with the mod: the right click option for trashing a part is not visible in the VAB, and the toolbar icon is not present in any scene (VAB, KSC, flight). I have the 0.8 version of the mod; am I doing something wrong? The only thing I could think of is that I don’t have Blizzy’s toolbar installed, is that required? Thanks! 

Link to comment
Share on other sites

1 hour ago, PhoenixSpaceIndustries said:

Hi @severedsolo, I’m having a few issues with the mod: the right click option for trashing a part is not visible in the VAB, and the toolbar icon is not present in any scene (VAB, KSC, flight). I have the 0.8 version of the mod; am I doing something wrong? The only thing I could think of is that I don’t have Blizzy’s toolbar installed, is that required? Thanks! 

Nope, blizzys toolbar is not needed/supported. I'll need a log please

Edited by severedsolo
Link to comment
Share on other sites

3 hours ago, PhoenixSpaceIndustries said:

the right click option for trashing a part is not visible in the VAB

This is intended behavior. In the VAB you drag the part into the SY Icon. The "Trash Part" button is just to tell SY not to recover it again, and only shows in the flight scene

Link to comment
Share on other sites

Hi @severedsolo, thanks very much for your response. The log is here: https://dsh.re/94b20

 

With regards to the VAB, if there is a certain part, say a fuel tank, with many other parts attached to it, which I would like to remove, do I have to disassemble the vehicle to drag it out? And with regards to the trashing parts, would you say the easiest way to get rid of faulty parts is to build a vessel then just remove them while sitting on the launchpad, then recovering the vessel? Just trying to work out the quickest way to use the mod! 

 

Thanks! 

Link to comment
Share on other sites

56 minutes ago, PhoenixSpaceIndustries said:

Hi @severedsolo, thanks very much for your response. The log is here: https://dsh.re/94b20

Your log seems to be corrupted. Judging by the file name, I'm guessing you tried to upload KSP.log anyway which is not very helpful. See here for the log I need (either output_log or player.log depending on your OS) -

 

59 minutes ago, PhoenixSpaceIndustries said:

With regards to the VAB, if there is a certain part, say a fuel tank, with many other parts attached to it, which I would like to remove, do I have to disassemble the vehicle to drag it out?

Unfortunately yes. Until magico gets round to implementing the ScrapYard GUI that is the case (not ideal I know, but outside my control.)

1 hour ago, PhoenixSpaceIndustries said:

And with regards to the trashing parts, would you say the easiest way to get rid of faulty parts is to build a vessel then just remove them while sitting on the launchpad, then recovering the vessel? Just trying to work out the quickest way to use the mod! 

I'd say the easiest way is to scrap them in the Editor. If you place a vessel on the pad but don't launch it, none of the parts will be recovered (UPFM adds a block to recovering unlaunched parts, so your test flights aren't just "pad and recover").

Link to comment
Share on other sites

So I tried using this along with KCT in a new career.  What is the best way to make parts more reliable?  Is it recovering and flying the same part over and over, or is it building the same part over and over?  Just trying to understand the game mechanic so I don't send Val to the Mun in an unreliable rustbucket.

Link to comment
Share on other sites

So what I’m finding is that parts become dangerously unsafe (75% chance of failure) after 3 recoveries. This hinders my aims for a fully reusable space program, where I recover every stage and reuse parts many times.

Is there any way to ‘rescale’ the failure curve, perhaps stretching it out by ten times or something so a part gets to this sort of level at 30 times, not 3?

Furthermore, upon inspection of persistent.sfs, simply deleting entries for parts recovered 3 or more times from the save file seems to be the easiest way to ensure safety. Are there likely to be any downsides to doing this? 

Thanks again, and thank you for your incredible work on this awesome mod. Do you have a Patreon, Circle or PayPal account? 

Link to comment
Share on other sites

5 hours ago, PhoenixSpaceIndustries said:

@severedsolo I did indeed, my sincere apologies for that. Here is the player.log file: https://dsh.re/0438d

Alternate link (in plain text) if the other doesn't work: https://dsh.re/ed4fe

Thank you very much! 

Sorry still not helpful, but that one is my fault, I should have been more specific: I need you to load a save and go to the Flight Scene, if the button isn't showing up, that should tell me where an exception is being thrown (if thats whats happening). The button should only be showing in the Flight Scene anyway.

17 hours ago, theonegalen said:

Any plans to integrate with the stock upgradable parts feature to allow upgrading parts to versions with a lower base failure chance?

There are now... that is an excellent idea. Added to the list.

11 hours ago, Norcalplanner said:

So I tried using this along with KCT in a new career.  What is the best way to make parts more reliable?  Is it recovering and flying the same part over and over, or is it building the same part over and over?  Just trying to understand the game mechanic so I don't send Val to the Mun in an unreliable rustbucket.

Here's a post I wrote earlier explaining how it works:

4 hours ago, PhoenixSpaceIndustries said:

So what I’m finding is that parts become dangerously unsafe (75% chance of failure) after 3 recoveries. This hinders my aims for a fully reusable space program, where I recover every stage and reuse parts many times.

Is there any way to ‘rescale’ the failure curve, perhaps stretching it out by ten times or something so a part gets to this sort of level at 30 times, not 3?

The expectedLifetime variable is exposed in the module config, so you should be able to write a MM patch (this is untested, and I tend to be terrible at first time syntax, but this should work or be close)

Note that expectedLifetime is the point where the part reaches the baseChanceOfFailure (by default 50%) on Generation 1.

The actual formula for calculating failure rates is:

(baseChanceOfFailure / generation)x(TimesRecovered/expectedLifetime)

@PART[*]:HAS[@MODULE[*FailureModule]]
{
	@MODULE[*FailureModule]
	{
		%expectedLifetime = 30
	}
}
4 hours ago, PhoenixSpaceIndustries said:

Furthermore, upon inspection of persistent.sfs, simply deleting entries for parts recovered 3 or more times from the save file seems to be the easiest way to ensure safety. Are there likely to be any downsides to doing this? 

Don't think so, I imagine ScrapYard has logic built into it to handle missing inventory parts. You'd have to ask @magico13 about that one though. However, there is an option in UPFM to change the "safety threshold" and make all parts above that threshold not be recovered. This is in the difficulty settings.

4 hours ago, PhoenixSpaceIndustries said:

Thanks again, and thank you for your incredible work on this awesome mod. Do you have a Patreon, Circle or PayPal account? 

I added a Paypal button to the first post.

Edited by severedsolo
Link to comment
Share on other sites

A question regarding UPFM parts that have suffered a failure and Scrapyard; if I recover a part that has suffered a failure, it is added to the Scrapyard inventory and then used in the next build... with the same failure it was recovered with.

But there is no way of repairing it on the VAB, or of telling Scrapyard not to use a defective part.

Am I right?

(BTW, thanks for the amazing mod that make simple missions much more interesting... basically by screwing them)

Edited by Kermanzooming
Link to comment
Share on other sites

5 minutes ago, Kermanzooming said:

But there is no way of repairing it on the VAB, or of telling Scrapyard not to use a defective part.

Am I right?

I'm pretty sure he's got a forbidden template set up so that the parts aren't added to the ScrapYard inventory if they have failed or have a failure chance that is too high, so you don't need to worry about this. Also, since you can't pick individual parts out of the inventory yet you don't need to worry since you won't be able to actually pull out the broken part.

Link to comment
Share on other sites

Maybe I edited the defective vessel instead of building a new one and that's why it had the defective part...will check and come back to you.

One last thing; the 0.8.0 version zip in GitHub has a completely different folder structure to the one in 0.7.0; in fact is missing the DLL. Os that 0.8.0 version ready to be installed as usual by dropping it on the GameData folder or am I doing something wrong?

Link to comment
Share on other sites

2 minutes ago, Kermanzooming said:

Maybe I edited the defective vessel instead of building a new one and that's why it had the defective part...will check and come back to you.

If you're using KCT and recovered a vessel to storage, it would still have the failed part. Which I would consider to be intentional since if you launched it right away without going in and replacing those parts it should still be broken. I can't say anything about the folder structure, so you'll have to wait for @severedsolo to comment.

Link to comment
Share on other sites

22 minutes ago, Kermanzooming said:

One last thing; the 0.8.0 version zip in GitHub has a completely different folder structure to the one in 0.7.0; in fact is missing the DLL. Os that 0.8.0 version ready to be installed as usual by dropping it on the GameData folder or am I doing something wrong?

Nothing wrong with the folder structure at this end. The only change is the addition of the changelog (I downloaded both from Github myself, in case I packaged it weirdly or something). Maybe it was a dodgy download.

49 minutes ago, Kermanzooming said:

A question regarding UPFM parts that have suffered a failure and Scrapyard; if I recover a part that has suffered a failure, it is added to the Scrapyard inventory and then used in the next build... with the same failure it was recovered with.

I just did a test of the one situation where I could imagine this happening (after loading a craft file) - but have not been able to reproduce. If you can figure out consistent reproduction steps (and you didn't recover to Storage as @magico13 said) - let me know.

If you did recover to storage, then yeah the broken part will stay broken. I may add an option to repair in the Editor though, if that's what's happened.

Link to comment
Share on other sites

Quote

Added option to toggle failure highlighting on a per-part basis from the right-click menu once a failure has occurred.

I have no such option in the right-click menu. KSP 1.3.0 and UPFM 0.8.

Link to comment
Share on other sites

1 hour ago, Cheesecake said:

I have no such option in the right-click menu. KSP 1.3.0 and UPFM 0.8.

It only appears if the part has failed. If the part has failed, and you still don't have the option then I will need a log and a screenshot.

Bottom option on this screenshot (ignore the funky failure rates, I'm working on something)

9ZkoiDk.jpg

Link to comment
Share on other sites

4 minutes ago, Cheesecake said:

I'm currently re-writing that code anyway, to stop it from showing up more than once where more than one failure module is attached to a part. Hopefully that will fix it in Beta 9

Edited by severedsolo
Link to comment
Share on other sites

Beta 9 (0.9) now available.

BACK UP YOUR SAVES BEFORE INSTALLING THIS UPDATE. THERE HAS BEEN A MAJOR CODE REFACTORING AND THE RELIABILITY MODEL HAS CHANGED SIGNIFICANTLY. EXISTING VESSELS MAY BE DETRIMENTALLY EFFECTED OR FAIL WHEN YOU DON'T EXPECT THEM TO

The changes to the reliability model are an experiment. I have been playing with them for a couple of days and am happy, but I want general feedback from other users.

  • Overhauled Reliability Model. It seems silly that early parts fail so easily, and then later parts hardly fail at all. expectedLifetime also had absolutely no bearing on a parts actual lifetime beyond Gen 1 and this seems silly. The new model balances this. Parts that are generally designed to be recovered (launch engines, parachutes etc) - will have higher initial failure rates but will have longer lifetimes. Parts that are designed to be sent into space and probably not come back (reaction wheels, solar panels etc) will have a lower initial failure rate but won't survive so many launches. Expected Lifetime now does what you would expect it to, and can be edited via MM (note that parts can still survive for less/more than the expected, it's just an average). The overall effect should be that overall failure rates are lower, but new builds will not reduce failure rates by as much as they used to. There is a certain amount of randomisation applied to failure rates, so every part will have it's own unique failure rate, but the actual randomisation applied will be linked to how many times you have built that part (ie failure rates should still generally trend downwards the more you use that part).
  • To compliment this change, UPFM will now track failure rates for each part from cradle to grave, rather than guessing on load as it did before.
  • In light of the above, the default Safety Threshold (the point where UPFM starts warning you that parts are unsafe) has been reduced to 25%. This will probably not affect existing saves and you'll have to change it manually.
  • Failures will no longer occur during KRASH simulations
  • Added option to EditorWarnings window to automatically replace any parts that are above the Safety Threshold (note that this will also remove the part from the SY Inventory, so be sure you want to do it before you click that button).
  • Improved Logging.
  • Events (toggle part failure, trash part, repair) will only show once on a part, rather than once per failure module. Any changes will affect all modules (so you click repair once, and if it works, everything gets repaired).

 

Link to comment
Share on other sites

Thanks for the update. Just tried 0.9 an I noted three things that I wasn't sure about:

  1. The glow for failed parts is gone, but I can't figure out how to toggle it back on. Currently there's no way that I could figure out to tell a part was broken - there's no glow and the right-click menu doesn't give any details. The new UPFM dialog box is great for giving a ship-wide readout, but it just says "XXX has failed, YY% chance to repair", but doesn't say which XXX failed or provide me any way to identify which XXX.
  2. Once I figured out which was broken I tried to repair. EVA'd got close enough to the part to bump it, but the right-click menu didn't offer a repair option. In 0.8 I was able to use a lvl 1 engineer to repair a part. I tried using the same engineer in 0.9 and he didn't get a repair option. Do I need a certain engineer level now? if so, how do I know what level I need?
  3. New failure model is confusing me
    1. Why do parts that are designed for launches have have longer lifetimes than a part that's intended to go on a 3 year mission? that seems backwards, or maybe I'm misunderstanding what you mean?
    2. I think it makes sense that lower tech parts have higher failure rates. A lot more Atlas missiles failed than SpaceX rockets because we've gotten better at avoiding issues...

Thanks!

Also just found out that if I re-load a ship, the UPFM dialog box no longer reports previous failures. Is this expected? (sorry for all the questions, I hope they are helpful)

Edited by Tyko
Link to comment
Share on other sites

26 minutes ago, Tyko said:

The glow for failed parts is gone, but I can't figure out how to toggle it back on. Currently there's no way that I could figure out to tell a part was broken - there's no glow and the right-click menu doesn't give any details. The new UPFM dialog box is great for giving a ship-wide readout, but it just says "XXX has failed, YY% chance to repair", but doesn't say which XXX failed or provide me any way to identify which XXX.

 

26 minutes ago, Tyko said:

Once I figured out which was broken I tried to repair. EVA'd got close enough to the part to bump it, but the right-click menu didn't offer a repair option. In 0.8 I was able to use a lvl 1 engineer to repair a part. I tried using the same engineer in 0.9 and he didn't get a repair option. Do I need a certain engineer level now? if so, how do I know what level I need?

Nuts. I shipped the old configs instead of the new ones. I've fixed it now. Please redownload and re-install.

26 minutes ago, Tyko said:
  • Why do parts that are designed for launches have have longer lifetimes than a part that's intended to go on a 3 year mission? that seems backwards, or maybe I'm misunderstanding what you mean?

Probably easier if I give an example - You will almost never see these figues IRL as it doesn't take into account the generational adjustments but it gives you an idea.

Engine A is meant to be a launch engine. It has a "first time use" failure rate of 10% (so the first launch has a 10% chance of failure). However, it is expected to last 100 launches (so you can reuse it 100 times). This means that after it's test flight (first launch) it will only have a 2% chance of failing on it's second launch.

Engine B is a space engine (say a Terrier, or a Poodle) - generally speaking these engines don't get recovered. So that engine only has a 5% chance of failing on it's first launch. However, it is only expected to last 25 launches (if you do recover it). So Flight 2 for that part would have a 8% chance of failure.

Remember that UPFM failure rates are "per launch" - parts don't wear out in flight. Essentially parts that don't come back will wear out quicker between launches, but will be more reliable to start with.

Again though, this is all open to feedback, I'm still tweaking it. Failures are still happening way too often, even with really low failure rates, so I need to look into that.

I've not even merged it into the main branch yet, in case I decide actually I hate it and want to go back to the old system.

Edited by severedsolo
Link to comment
Share on other sites

11 hours ago, severedsolo said:

 

Nuts. I shipped the old configs instead of the new ones. I've fixed it now. Please redownload and re-install.

I re-downloaded...Now the engineer can repair the parts, but several parts showed 100% chance to repair and the repairs failed. Also, the glow is back for some parts, but other damaged parts still don't glow. 

Edited by Tyko
Link to comment
Share on other sites

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