Jump to content

[1.8.x] Monthly Budgets 5.0.1 (22/12/2019) - UP FOR ADOPTION


severedsolo

Recommended Posts

I just learnt this the hard way.  I had excess budget so whacked it all into research for one month...took me another year to earn the rep back!  Might be worth making a note of that in the tooltips if/when you do another update.

Link to comment
Share on other sites

Not sure if anyone has encountered this or if its to do with a mod conflict, but last night I had a probe core on one of my upper stage boosters so that I could deorbit the booster after separation. All went well until the booster hit the atmosphere (vessel was not in focus) and the game destroyed it. When that happened I suddenly got a NullReferenceException and my reputation went down. I checked the log and as I thought, the NRE (which pointed at this mod) happened and my reputation went down 33 points.

Unfortunately I'm at work as I type this, but later this evening when I'm home I'll install this mod on a clean game and do some testing, if I cant replicate the NRE without any other mods I'll do some batch testing to check for compatibility issues with my other 133 mods. Once I have the problem narrowed down I'll return with modlist, logs, and recreation steps.

Link to comment
Share on other sites

2 minutes ago, CoriW said:

Not sure if anyone has encountered this or if its to do with a mod conflict, but last night I had a probe core on one of my upper stage boosters so that I could deorbit the booster after separation. All went well until the booster hit the atmosphere (vessel was not in focus) and the game destroyed it. When that happened I suddenly got a NullReferenceException and my reputation went down. I checked the log and as I thought, the NRE (which pointed at this mod) happened and my reputation went down 33 points.

Unfortunately I'm at work as I type this, but later this evening when I'm home I'll install this mod on a clean game and do some testing, if I cant replicate the NRE without any other mods I'll do some batch testing to check for compatibility issues with my other 133 mods. Once I have the problem narrowed down I'll return with modlist, logs, and recreation steps.

If you could provide the log with the NRE anyway, that may at least point me in the right direction while you are narrowing it down.

Link to comment
Share on other sites

5 minutes ago, severedsolo said:

If you could provide the log with the NRE anyway, that may at least point me in the right direction while you are narrowing it down.

Will do as soon as I get home.

Link to comment
Share on other sites

So .. Unfortunately I had re-launched the game since that happened last night so I don't have the log with the NRE in it.. That being said I just completely re-flew the mission from scratch trying to replicate it in my modded install (which is where it occurred the first time and it didn't seem to trigger .. Though I did discover NRE's from several other mods (Sigma Replacements, RecoveryController, Kerbal Engineer Redux, StageRecovery, Scatterer, Kopernicus, Waypoint Manager, Alternate Resource Panel, Deep Freeze, KSP-AVC) .. Looks like I'm going to have to just keep playing and hope the NRE presents itself again. The moment it does I will get the logs.

Link to comment
Share on other sites

You probably want to post a link to the log anyway... that's a large whack of mods, one of which (or another entirely) is the bad actor, but that many NRE rarely is a good sign. The root of the problem may not be here is all I'm saying, but it's surely somewhere (fixable).

Link to comment
Share on other sites

1 hour ago, komodo said:

You probably want to post a link to the log anyway... that's a large whack of mods, one of which (or another entirely) is the bad actor, but that many NRE rarely is a good sign. The root of the problem may not be here is all I'm saying, but it's surely somewhere (fixable).

Well, I'm not sure if it'd be appropriate or not to post in this thread as this particular log doesn't appear to contain any NRE's relating to this mod.. But who knows there are so many errors in there that maybe there's something useful to learn from it.

https://www.dropbox.com/s/iloz11sckhzzvfy/output_log.txt?dl=1

I do intend to eventually go through and see what all is conflicting and causing issues, but I dont really have a lot of time lately unfortunately.

Edit: Really I've learned time and time again that installing 100+ mods all at once and hoping everything will just go smoothly is a dream that rarely if ever comes true. Lol

Edited by CoriW
Link to comment
Share on other sites

37 minutes ago, CoriW said:

Well, I'm not sure if it'd be appropriate or not to post in this thread as this particular log doesn't appear to contain any NRE's relating to this mod.. But who knows there are so many errors in there that maybe there's something useful to learn from it.

https://www.dropbox.com/s/iloz11sckhzzvfy/output_log.txt?dl=1

I do intend to eventually go through and see what all is conflicting and causing issues, but I dont really have a lot of time lately unfortunately.

Edit: Really I've learned time and time again that installing 100+ mods all at once and hoping everything will just go smoothly is a dream that rarely if ever comes true. Lol

Definitely add them in sections.

Things noted, not in order perhaps:

You may have two copies of KAS, a regular one and a LEGACY one. I don't know if this is normal for KAS.
I would check if Kopernicus is up to date. The first error found is thrown during its loading, but it may be coincidence.
Scatterer can't load some shaders, calling out your video card. Running in opengl or DX11 may change, but I am unsure.
d3d is failing to create some 2D textures. I do not know how to interpret this.
Kopurnicus is throwing NREs on loading the main menu. This is perhaps a red herring: I had something similar once, and it was ultimately due to an error in for a dll that shouldn't have ever touched kopurnicus. (Praise insane KSP coding.)
AlternateResourcePanel can't load some icons and is unhappy.
You mentioned you had trouble when launching a vessel: RecoveryControler is throwing exceptions towards the end of the log. Some addons have the feature of a punishment for blowing up a craft via rep loss. Do you have any of that sort loaded? I can imagine something like: Craft is not handled correctly when changing crafts. Poof goes craft. Punishment mod slaps save file on wrist. Monthly budgets sees rep loss and takes according action.
There are a huge number of lines like this: "delta 0, target amt 200", but I have no idea where they come from or what they mean.
Deepfreeze is throwing an exception when trying to talk to Kerbal Alarm Clock. I would check that both are up to date.
Way at the end we have "[MonthlyBudgets]: Problem calculating the budget", but this is also in the final moments of shutting down. It may be normal.

What I would do is this: Back up your save first.

Then: Look at the mods that provide a plugin, and do a binary search. Move half of them out of the GameData folder and see what effect it has. I would take out non-essential ones first, particularly anything graphical as to minimize the impact on your save. If the problems go away, the bad actor was one of the ones removed. If no change, the ones removed were OK.

My guess is that you have a plugin (maybe just one) that is mucking things up. My own experience with torturing the game has shown that where an error appears to come from, and where the problem actually is located can be entirely different.

It is also worth testing a new/sandbox save to see if it's something particular to the save. (I also may suggest that you hit up the tracking station and delete any leftover debris you might have. I saw a fair bit, and the more things the game has to track, the weirder the results can be...)

My totally scientific (aka, out of my behind) guess is that either something in the DeepFreeze/KAC/AlternateResourcePanel setup is not working right, or recoverycontroller hates your craft (or both). I would check them to see if there are updates, and/or experiment with unloading them, but I do not offer any kind of guarantee or responsibility for this guess.

Link to comment
Share on other sites

4 hours ago, komodo said:

Way at the end we have "[MonthlyBudgets]: Problem calculating the budget", but this is also in the final moments of shutting down. It may be normal

Thats a catch block that happens when the mod catches an nre when a scene change is happening. Its perfectly normal and will sort itself out when the scene change is done. 

Link to comment
Share on other sites

Playing with Probes Before Crew which includes a new progression type Contract Pack but it's still giving out massive fund rewards and tiny reputation rewards which is a shame. Any idea how to fix or adjust it? It's mainly the inner rewards that fail to get adjusted, rewards that you get for completing steps that is. I assume that's why it doesn't work?

Edited by Raccoon
Link to comment
Share on other sites

24 minutes ago, Raccoon said:

Playing with Probes Before Crew which includes a new progression type Contract Pack but it's still giving out massive fund rewards and tiny reputation rewards which is a shame. Any idea how to fix or adjust it? It's mainly the inner rewards that fail to get adjusted, rewards that you get for completing steps that is. I assume that's why it doesn't work?

Yeah, mb deliberately leaves parameter rewards alone, because that's how stock tourism contracts work. 

You'd need an MM patch to move the rewards out of the parameter nodes and into the main contract node 

Link to comment
Share on other sites

  • 2 weeks later...

Any idea why the mod would not be setting a KAC alarm???  I made sure the settings were set to do so.  It had one for the first month but has since stopped making alarms??  Perhaps I'm missing something simple.  Thank you.

Link to comment
Share on other sites

4 hours ago, DSM20T said:

Any idea why the mod would not be setting a KAC alarm???  I made sure the settings were set to do so.  It had one for the first month but has since stopped making alarms??  Perhaps I'm missing something simple.  Thank you.

Known issue - you need to have 1 other alarm active in the list before it creates one.

Link to comment
Share on other sites

 

@severedsolo Hey I was finally able to get that NRE that I mentioned awhile back. Here's a link. Warning there are I lot of mods so I'm unsure if it's a conflict yet or not but I'll give you the output_log for now just in case.

https://www.dropbox.com/s/zgjygcrkhr7i5fs/output_log.txt?dl=1

EDIT: Easiest way to find the nullref is to do a find for " reputation: 'VesselLoss' ", there are 4 instances of this occurring. This appears to only be occurring when I have unmanned craft (usually separated stages with probe cores attached) are destroyed when not in focus (no testing done on if this happened when they are destroyed while in focus however)

This is the actual NRE itself.

	Added -23.0649 (-23) reputation: 'VesselLoss'.
 
(Filename: C:/buildslave/unity/build/artifacts/generated/common/runtime/DebugBindings.gen.cpp Line: 51)
	Exception handling event onKerbalStatusChange in class DeadKerbalPenaliser:System.NullReferenceException: Object reference not set to an instance of an object
  at MonthlyBudgets.DeadKerbalPenaliser.OnKerbalStatusChange (.ProtoCrewMember p, RosterStatus statusFrom, RosterStatus statusTo) [0x00000] in <filename unknown>:0 
  at EventData`3[ProtoCrewMember,ProtoCrewMember+RosterStatus,ProtoCrewMember+RosterStatus].Fire (.ProtoCrewMember data0, RosterStatus data1, RosterStatus data2) [0x00000] in <filename unknown>:0 
 
(Filename: C:/buildslave/unity/build/artifacts/generated/common/runtime/DebugBindings.gen.cpp Line: 51)
	NullReferenceException: Object reference not set to an instance of an object
  at MonthlyBudgets.DeadKerbalPenaliser.OnKerbalStatusChange (.ProtoCrewMember p, RosterStatus statusFrom, RosterStatus statusTo) [0x00000] in <filename unknown>:0 
  at EventData`3[ProtoCrewMember,ProtoCrewMember+RosterStatus,ProtoCrewMember+RosterStatus].Fire (.ProtoCrewMember data0, RosterStatus data1, RosterStatus data2) [0x00000] in <filename unknown>:0 
UnityEngine.DebugLogHandler:Internal_LogException(Exception, Object)
UnityEngine.DebugLogHandler:LogException(Exception, Object)
UnityEngine.Logger:LogException(Exception, Object)
UnityEngine.Debug:LogException(Exception)
EventData`3:Fire(ProtoCrewMember, RosterStatus, RosterStatus)
ProtoCrewMember:set_rosterStatus(RosterStatus)
ProtoCrewMember:Die()
ProtoCrewMember:CheckRespawnTimer(Double, GameParameters)
KerbalRoster:Init(Game)
Game:Load()
<Start>c__Iterator0:MoveNext()
UnityEngine.SetupCoroutine:InvokeMoveNext(IEnumerator, IntPtr)
 
(Filename:  Line: -1)
	

EDIT: I decided to try turning off reputation loss from crewed vessel loss, though it appears that it continued to occur so I'm going to try turning off Kerbal Death reputation loss and see if that was the issue. If that doesn't work then I will try turning them both off.

EDIT: Alright so I can confirm that the problem is fixed if I set "Per Kerbal Death Penalty" to 0. The NullRef still occurs but in the log it says it just takes 0 rep.

Edited by CoriW
Link to comment
Share on other sites

9 hours ago, CoriW said:

EDIT: Easiest way to find the nullref is to do a find for " reputation: 'VesselLoss' ", there are 4 instances of this occurring. This appears to only be occurring when I have unmanned craft (usually separated stages with probe cores attached) are destroyed when not in focus (no testing done on if this happened when they are destroyed while in focus however) 

Thanks, that's really helpful.

I think I've found the issue:

Quote

Crewmember Raging Gaelan has been missing for too long! Must be dead by now

At that point, MB assumes that the kerbal will be in a vessel, but when it actually tries to grab the vessel, that throws an NRE.

The line which I believe is causing the issue is this:
 

Debug.Log("[MonthlyBudgets] " + p.name + " aboard " + p.seat.vessel.vesselName +" has died. Applying penalty of "+penalty+" rep");
if (lastProcessedVessel == p.seat.vessel.id) return;

My guess is that you have "missing kerbals respawn" on? It's a simple enough fix, but I'll have to rejigger some stuff to take into account the fact that a kerbal might actually go "missing" instead of "dead" (I never play with that option on, so forgot to test it).

Question for the floor: Should "Missing" Kerbals be treated the same way as dead ones, or shall we just penalise the vessel loss as the kerbals will come back.

Edited by severedsolo
Link to comment
Share on other sites

9 hours ago, severedsolo said:

Thanks, that's really helpful.

I think I've found the issue:

At that point, MB assumes that the kerbal will be in a vessel, but when it actually tries to grab the vessel, that throws an NRE.

The line which I believe is causing the issue is this:
 


Debug.Log("[MonthlyBudgets] " + p.name + " aboard " + p.seat.vessel.vesselName +" has died. Applying penalty of "+penalty+" rep");
if (lastProcessedVessel == p.seat.vessel.id) return;

My guess is that you have "missing kerbals respawn" on? It's a simple enough fix, but I'll have to rejigger some stuff to take into account the fact that a kerbal might actually go "missing" instead of "dead" (I never play with that option on, so forgot to test it).

Question for the floor: Should "Missing" Kerbals be treated the same way as dead ones, or shall we just penalise the vessel loss as the kerbals will come back.

Hmm, that's a bit strange actually. Because in this save I use unmanned before manned and had literally just unlocked command pods, and have yet to even use a real live kerbal. I also have "missing kerbals respawn" off so I'm not really sure what would be going on there.

That being said, I'll install your update and let you know if I come across the issue again or if it is indeed fixed. Thanks for the quick update btw. :)

EDIT: Meant I use Probes Before Crew, not Unmanned Before Manned. Always get those two mixed up lol

Edited by CoriW
Link to comment
Share on other sites

3 hours ago, vardicd said:

@severedsolo I'm pretty sure this goes here. I was highly amused when this happened while I was trying to record a bug video for Angel-125

Who me? I don't know what you're talking about *whistles innocently*

Edited by severedsolo
Link to comment
Share on other sites

1 hour ago, severedsolo said:

Who me? I don't know what you're talking about *whistles innocently*

I got Nyan cat zooming across my loading screen, robbed when KSC loaded, all my saved navigation waypoint icons turned into Nyan Cat. I've been April fools pranked more today by my KSP game than anyone, or anywhere else.

Link to comment
Share on other sites

2 minutes ago, vardicd said:

I got Nyan cat zooming across my loading screen, robbed when KSC loaded, all my saved navigation waypoint icons turned into Nyan Cat. I've been April fools pranked more today by my KSP game than anyone, or anywhere else. 

Well..... I WAS going to code OhScrap! to simultaneously fail every part at once randomly, but I thought that might be going a bit far.

Link to comment
Share on other sites

3 minutes ago, severedsolo said:

Well..... I WAS going to code OhScrap! to simultaneously fail every part at once randomly, but I thought that might be going a bit far.

I think there was one year realchutes had an april fools module added to it that did something like that. I think it was meant to be optional, but it was turned on by default, with no way to turn it off, and the mod author had to realease a quick hotfix to fix it. I might be remembering wrong, but I'd swear that was it.

Link to comment
Share on other sites

I really hope your April Fool's joke is idiot proof. I spent 2 hours trying to get my KSP to work today, then it loaded for 20 minutes, then I was greeted with the prank, then I tried to close KSP quickly enough that it didn't save. Now I get to wait for another 20 minutes for it to load again and I really hope I didn't mess everything up with my panic.

EDIT: Everything is ok.

Edited by theonegalen
Link to comment
Share on other sites

This thread is quite old. Please consider starting a new thread rather than reviving this one.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...