severedsolo

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

Recommended Posts

On 12/23/2019 at 12:51 AM, severedsolo said:

Do you mean if you revert? - the reliability won't change if you revert because it's like the flight never happened.

If you mean "did a successful rescue/recovery" then the reliability will change. Oh Scrap doesn't care how far the parts got, only that they flew.

I've been running into issues with this lately, specifically for STTOs/spaceplanes.

I fly a complete SSTO mission from the runway, all the way to orbit, deploy the payload, land back at the runway... and get no generation increase. At first I thought it was KCT conflicting, with it's "recover to SPH" function, but specific testing by using only the stock recovery function gives the same behavior. I can't get it to reliably upgrade gens. Any chance you could define how/when the generation increase code is called @severedsolo? Would help with further troubleshooting.

Additionally, we've run into the old issue where Oh Scrap is spamming fail tests as fast as it can for a craft that spawns on the runway. Even at overall reliability 9, a craft sitting on the runway for about 60s had almost every non-reliability-10 part fail. Only way to mitigate is to spawn to the runway and immediately light a stage, which flips the fail check spam down to a more reasonable level.

Is there anything we can check there? Under what circumstances would the mod attempt to spam a check per second? It may be a conflict with World Stabilizer, which spawns the craft off the ground and "eases" it down... so perhaps the game is thinking a newly spawned craft starts at a state of flying and then becomes landed? Still not sure why a landed craft would spam a fail check per second, though...

Currently on Oh Scrap 2.0.1

Share this post


Link to post
Share on other sites
16 minutes ago, DasValdez said:

Any chance you could define how/when the generation increase code is called @severedsolo? Would help with further troubleshooting.

Well the generation won't increase if you are fully recovering and re-using the parts. OhScrap stores the PartID and recalls it when the PartModule loads. It's a fairly complex bit of code but it starts here: https://github.com/severedsolo/OhScrap/blob/c4028fa93ee707fd250250bd250b20a78d3812e9/OhScrap/BaseFailureModule.cs#L162 - if the safety rate isn't changing that's a definite bug.

27 minutes ago, DasValdez said:

Is there anything we can check there? Under what circumstances would the mod attempt to spam a check per second? It may be a conflict with World Stabilizer, which spawns the craft off the ground and "eases" it down... so perhaps the game is thinking a newly spawned craft starts at a state of flying and then becomes landed? Still not sure why a landed craft would spam a fail check per second, though...

You are probably onto something with WorldStabiliser actually. When the situation changes, it immediately rolls. I bet the situation is changing really quickly. That's the only thing I can think of that would cause this - the fallback option is "deep space" which is about every 30 days or something stupid like that.

Test build for you: https://1drv.ms/u/s!AtG2PODa0fmwisQTp1nEgy1d20HKDg?e=67sTLV

Won't fix the issue, but should log enough to tell me what's going on. Reproduce and provide the log please.

Share this post


Link to post
Share on other sites

@severedsolo Understood, and will attempt to replicate with that build. Thanks as always!

Share this post


Link to post
Share on other sites

I've not been able to figure out, is there a way to test parts and improve reliability without physically putting a craft on the pad? Like, a button you can push that has the same in-game time and money penalties as rolling out the part but without making the player switch contexts to and from the pad multiple times?

I absolutely love the idea of this mod, but I'm finding I don't have much time to play and wish I could have the invest-in-testing-or-risk-vessel-failure experience without the real-world time commitment of rolling all these ships out to the pad.

Share this post


Link to post
Share on other sites
1 minute ago, billybob579 said:

I've not been able to figure out, is there a way to test parts and improve reliability without physically putting a craft on the pad? Like, a button you can push that has the same in-game time and money penalties as rolling out the part but without making the player switch contexts to and from the pad multiple times?

There is not I'm afraid, and it's not a planned feature.

Share this post


Link to post
Share on other sites

I've been having issues with the "trash part" button not working, however many times I press it. I thought that it might be an issue with the most recent update of KCT, so I reverted that and nothing happened. I can discard parts perfectly fine within the VAB or SPH, it's just that the in-flight button isn't functional. Mods are mostly up-to-date with the exception of a few that shouldn't interact with Oh Scrap or KCT. Otherwise, the mod works fine and your work, is, as always amazing. 

output log

I don't honestly expect you to dig through that, as potentially any of 115+ mods could be messing with it, but if you have a place to start looking it would be much appreciated.

Versions:

Spoiler

KCT - 1.4.7.12

Oh Scrap! - 2.0.1

ScrapYard - 2.0

Edit: Parts are still kept even when they "cannot be saved"

Edited by crowsnose

Share this post


Link to post
Share on other sites

Okay, I just skimmed the last four or five pages of posts, and I didn't spot anything like this -- is there any known problem in using Oh Scrap! alongside Test Flight?  As I understand it, they use very different methods of computing failure probability, but do they then independently determine failures, effectively (on a naive level) doubling my chance of a failure?

If it makes a difference, I'm referring specifically to a 1.6.1 RSS/RO/RP-1 install, with both Test Flight (original to the install, a couple months ago) and Scrapyard/Oh Scrap! installed (last couple days), both via CKAN.  I started a new save after installing Scrapyard and Oh Scrap!, generation counts and "flown" figures seem to be incrementing correctly, and I have seen "safety rating" and "worst part" changing from launch to launch (I also have Stage Recover and installed parachutes on the booster, so the same Tiny Tim has flown three times) -- but in the WAC Corporal generation (i.e. first engines available) sounding rockets, I haven't experienced any failures -- and Test Flight alone usually generates one or two WAC Corporal engine failures before I can upgrade to the next version (XASR-1).  I made no ground tests, and even (likely because I reused a craft file from another save) forgot to order R&D on the WAC Corporal engine before first launch.

Not complaining about lack of failures -- when you're trying to get from WAC Corporal/Tiny Tim to orbit in under ten years, failures are very, very frustrating and prone to bankrupting your program.  Just checking if I've introduced a conflict that might cause one or the other or both failure mods to malfunction.

Share this post


Link to post
Share on other sites
11 hours ago, Zeiss Ikon said:

I haven't experienced any failures -- and Test Flight alone usually generates one or two WAC Corporal engine failures before I can upgrade to the next version (XASR-1).  I made no ground tests, and even (likely because I reused a craft file from another save) forgot to order R&D on the WAC Corporal engine before first launch.

Can you zip up your Severedsolo/OhScrap/Logs folder and send it to me please (there will be alot of files, just send me the whole thing)?

On 2/9/2020 at 12:56 AM, crowsnose said:

I've been having issues with the "trash part" button not working, however many times I press it. I thought that it might be an issue with the most recent update of KCT, so I reverted that and nothing happened. I can discard parts perfectly fine within the VAB or SPH, it's just that the in-flight button isn't functional.

I've had a suspicion that hasn't been working for a while... leave it with me.

Share this post


Link to post
Share on other sites
On 2/11/2020 at 2:02 AM, severedsolo said:

Can you zip up your Severedsolo/OhScrap/Logs folder and send it to me please (there will be alot of files, just send me the whole thing.

I'll try to remember to do that, next time I have time to play.  Been busy this week with a GURPS character build.

Share this post


Link to post
Share on other sites
6 hours ago, Zeiss Ikon said:

I'll try to remember to do that, next time I have time to play.  Been busy this week with a GURPS character build.

Do it BEFORE you start your game. OhScrap! deletes all logs that are older than 24 hours old.

Share this post


Link to post
Share on other sites
17 hours ago, severedsolo said:

Do it BEFORE you start your game. OhScrap! deletes all logs that are older than 24 hours old.

Thanks!  I'll have time to play tonight or tomorrow, I'll try to remember to get the logs zipped up tonight, first thing.

Share this post


Link to post
Share on other sites
On 2/10/2020 at 10:13 PM, Zeiss Ikon said:

Okay, I just skimmed the last four or five pages of posts, and I didn't spot anything like this -- is there any known problem in using Oh Scrap! alongside Test Flight?  As I understand it, they use very different methods of computing failure probability, but do they then independently determine failures, effectively (on a naive level) doubling my chance of a failure?

If it makes a difference, I'm referring specifically to a 1.6.1 RSS/RO/RP-1 install, with both Test Flight (original to the install, a couple months ago) and Scrapyard/Oh Scrap! installed (last couple days), both via CKAN.  I started a new save after installing Scrapyard and Oh Scrap!, generation counts and "flown" figures seem to be incrementing correctly, and I have seen "safety rating" and "worst part" changing from launch to launch (I also have Stage Recover and installed parachutes on the booster, so the same Tiny Tim has flown three times) -- but in the WAC Corporal generation (i.e. first engines available) sounding rockets, I haven't experienced any failures -- and Test Flight alone usually generates one or two WAC Corporal engine failures before I can upgrade to the next version (XASR-1).  I made no ground tests, and even (likely because I reused a craft file from another save) forgot to order R&D on the WAC Corporal engine before first launch.

Not complaining about lack of failures -- when you're trying to get from WAC Corporal/Tiny Tim to orbit in under ten years, failures are very, very frustrating and prone to bankrupting your program.  Just checking if I've introduced a conflict that might cause one or the other or both failure mods to malfunction.

IIRC, RP-1 wiki says that it is incompatible with Oh Scrap.

Share this post


Link to post
Share on other sites
12 hours ago, garwel said:

IIRC, RP-1 wiki says that it is incompatible with Oh Scrap.

Hmm.  Perhaps in the sense of making Oh Scrap! partially not work.  I never see anything in the inventory panel, for instance, but I do see generations and flight count increment correctly, and a rocket that's been flown and recovered successfully both increases safety rating and changes "least reliable part" designation (instead of WAC Corporal engine, for instance, it'll become Mercury Mini Parachute).  As far as I can tell, aside from no failures (which might be Oh Scrap! making Test Flight not work), Oh Scrap! is working.  And I just checked the RP-1 wiki page, I don't see any mention of Oh Scrap! or Scrapyard, either as recommendation or warning.  They point to Test Flight and TestLite (one or the other, not both) for engine reliability mods.

@severedsolo Well, that's interesting.  I haven't started the game in several days, and the ~/Downloads/KSP-RO_1.6.1/GameData/Severedsolo/OhScrap/Logs is empty.  I'm reasonably sure this indicates something isn't quite right.

Going to start the game now, and I'll check that Logs folder again after launching something.

Aaaand after launching a Tiny Tim/XASR-1/XASR-1 to suborbital height and recovering most of it, the Logs folder is still empty.

Given RP-1 is really designed to work with Test Flight or TestLite, I'll just take Oh Scrap! off.  Scrapyard might, possibly be useful for later in a career -- being able to recover and reuse your Shuttle SRB analogs would save significant money, but with what sounding rockets cost in the early game, it's barely worth bothering to put parachutes on them, even if you can get them to land intact -- and if anything goes wrong, the cost of the parachute wipes out everything you might have otherwise saved.

Edited by Zeiss Ikon

Share this post


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

Aaaand after launching a Tiny Tim/XASR-1/XASR-1 to suborbital height and recovering most of it, the Logs folder is still empty.

Definitely something odd going on there then, there is a bug atm where it creates logs even if it doesn't need to, so you should definitely have some files in there.

If you do happen to fire it up again, shoot me a KSP.log to look at instead.

Share this post


Link to post
Share on other sites

I've pulled it from that install, and since it appears RO is specific to TestFlight or TestLite, I doubt I'll get to test OhScrap! any further -- aside from RO, I normally don't use a bunch of mods; ran a career for a couple years with only Better Burn Time, and most of that capability is now built into 1.8.1, but tied to pilot skill (new pilots don't see any of the extra stuff, experienced ones gradually gain things like when to start a burn for a node, presumably eventually when to start for an intercept or suicide burn as well).

Share this post


Link to post
Share on other sites
Posted (edited)

I have been asked by @severedsolo to adopt this wonderful mod for curation.

I am hoping @severedsolo continues to assist when needed. :D

Now I do not have the skill @magico13 of @severedsolo have; but I will do my best.

With that said, what is currently not supported will probably remain not supported; unless someone more skilled than I does a PR through github. I also have to say that I normally don't have this installed due to my super-grand-potato giving me an evil cam any time I mention installing it. :o

More will be posted here when it is time.

 

68747470733a2f2f696d672e736869656c64732e

Edited by zer0Kerbal

Share this post


Link to post
Share on other sites

Just to follow up with what zer0kerbal said, I'm not going anywhere - I just have alot of old projects and am looking to refocus my efforts a little.

OhScrap and ScapYard are popular mods, but I don't really get time to work on them, so I'd rather they go to someone who can give them some proper attention. Some of the less popular mods will probably be dropped, to clear some time/space for me to work on new stuff.

Share this post


Link to post
Share on other sites

@severedsolo and all users:

Am putting together CKAN/Readme and need the following:

What mods are:

conflicting/not supported

  • sounds like RP-1 ?

suggested/benefit from

  •  

supported:

  • Kerbal Change Log
  • TweakScale

 

Thank you in advance!

Share this post


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

@severedsolo and all users:

Am putting together CKAN/Readme and need the following:

What mods are:

conflicting/not supported

  • None as far as I know

suggested/benefit from

  • ScrapYard is required
  • KCT is recommended

supported:

  • Kerbal Change Log (required dependency for CKAN users)
  • RemoteTech
  • FAR
  • KRASH

 

Thank you in advance!

 

Share this post


Link to post
Share on other sites

Would it be possible to get a bonus to repair chance for engineers and (usi) mechanics?

Share this post


Link to post
Share on other sites
17 minutes ago, dlrk said:

Would it be possible to get a bonus to repair chance for engineers and (usi) mechanics?

Engineers already boost repair chance. Mechanics would be easy enough to do but you'll have to ask zer0kerbal when he's ready to take over fully.

Share this post


Link to post
Share on other sites
1 hour ago, dlrk said:

Would it be possible to get a bonus to repair chance for engineers and (usi) mechanics?

 

1 hour ago, severedsolo said:

Engineers already boost repair chance. Mechanics would be easy enough to do but you'll have to ask zer0kerbal when he's ready to take over fully.

If I am remembering the code, instead of hard coding - a simple module manager patch to add the appropriate skill would be simpler.

 

Open beta for KSP 1.9.1 coming soon.

Like now:

https://github.com/zer0Kerbal/OhScrap/releases/tag/2.1.0.0

SOURCE: GitHub
License:
68747470733a2f2f696d672e736869656c64732e

Share this post


Link to post
Share on other sites
Just now, zer0Kerbal said:

If I am remembering the code, instead of hard coding - a simple module manager patch to add the appropriate skill would be simpler.

https://github.com/severedsolo/OhScrap/blob/f57eeadd001f7ec43af88b9d1c29e952e2082164/OhScrap/ModuleUPFMEvents.cs#L194

It's hardcoded at the moment, but a skill would probably be the better way to do it yes.

Share this post


Link to post
Share on other sites
Posted (edited)
4 minutes ago, severedsolo said:

https://github.com/severedsolo/OhScrap/blob/f57eeadd001f7ec43af88b9d1c29e952e2082164/OhScrap/ModuleUPFMEvents.cs#L194

It's hardcoded at the moment, but a skill would probably be the better way to do it yes.

thought that was the way it was coded - so

Spoiler

if ((p.trait == "Engineer") || (p.trait == "Mechanic"))

 

should work (pseudo code)

Edited by zer0Kerbal

Share this post


Link to post
Share on other sites
Just now, zer0Kerbal said:

thought that was the way it was coded - so

  Hide contents


if(p.trait == "Engineer") || (p.trait == "Mechanic")

 

should work (pseudo code)

Basically, assuming that's the actual trait name.

I feel like there is a Repair skill in the game though? Can't remember the exact name, but perhaps that could be leveraged if you didn't want to hardcode.

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.