Jump to content

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


severedsolo

Recommended Posts

8 hours ago, loki130 said:

First, it would be nice to have a mechanic to retire old satellites, when they have no more function or when they fall out of contact, in order to reduce costs.

Just mark them as debris and the mod will ignore them.

8 hours ago, loki130 said:

It might make sense to make multiple deaths in a single crash have a lower impact than the same number of deaths in consecutive crashes

I agree, but sadly the "onCrewKilled" event doesn't actually pass through the crew member who died (or the vessel they were on). I tried implementing "onVesselDestroy" or "onVesselWillDestroy" instead, but the crew die before that event fires, so I can't differentiate between unmanned and manned vessels (and destroying probes is fine... I don't want to punish you for that). TL:DR - the second one isn't possible.

Link to comment
Share on other sites

2 hours ago, severedsolo said:

I agree, but sadly the "onCrewKilled" event doesn't actually pass through the crew member who died (or the vessel they were on). I tried implementing "onVesselDestroy" or "onVesselWillDestroy" instead, but the crew die before that event fires, so I can't differentiate between unmanned and manned vessels (and destroying probes is fine... I don't want to punish you for that). TL:DR - the second one isn't possible.

Is it possible to count up the number of crew deaths and then penalize on a scene change, or when the vessel is destroyed (though the latter wouldn't work for life support mods)?

Link to comment
Share on other sites

Are tourists supposed to still be giving straight cash and rep rewards?  Tried searching this thread, and it definitely sounds like something that shouldn't happen. 

The 'Disable Contract Funding' option in the difficulty setup is turned on and green.

Link to comment
Share on other sites

15 minutes ago, IonMage said:

Are tourists supposed to still be giving straight cash and rep rewards?  Tried searching this thread, and it definitely sounds like something that shouldn't happen. 

The 'Disable Contract Funding' option in the difficulty setup is turned on and green.

Contracts that have rewards attached to the individual parameters (rather than for the whole contract) - such as the tourism ones will still pay out for that parameter.

The basic reason for this is that I can't make that payout disappear without just pulling it away when it's awarded (which would suck, because the game would tell you that you got paid, but then you didn't)

Edited by severedsolo
Link to comment
Share on other sites

On 9/4/2016 at 10:53 PM, Daelkyr said:

An odd question. Does this mod support a fraction of a day? I want to add


Budget Interval (Kerbin Days) = 47.3

because my Kerbin calendar is based on Minmus orbit and that gives me 9 47~48 day months.

... wat?

I've seen a lot of different things in my years around KSP forums and subreddit... But someone with the calendar being based on a minmus orbit? That's a new one for me!

Link to comment
Share on other sites

Hey, I love the concept of the mod so far — it really changes how I play my career game. Especially this third RnD upgrade is driving me nuts :D

I've found a weird behavior however where sometimes when I load the persistence for the first time the mod will award me my budget even though it's not payday. . . any idea what might be causing that ? (1.2 x64) 

I'll catch the log if it happens the next time . 

Link to comment
Share on other sites

4 hours ago, Amnesy said:

I've found a weird behavior however where sometimes when I load the persistence for the first time the mod will award me my budget even though it's not payday. . . any idea what might be causing that ? (1.2 x64) 

You definitely running the latest version? There was a bug where the first time check was being done before the save had loaded, but I fixed that. If it's still happening I may need to revisit it.

Edit: You specifically said "loading the persistence for the first time" rather than "Loading the game for the first time" - does that mean that it's happening when you load a second save? Cause I can see that happening.

Edited by severedsolo
Link to comment
Share on other sites

5 hours ago, severedsolo said:

You definitely running the latest version? There was a bug where the first time check was being done before the save had loaded, but I fixed that. If it's still happening I may need to revisit it.

Edit: You specifically said "loading the persistence for the first time" rather than "Loading the game for the first time" - does that mean that it's happening when you load a second save? Cause I can see that happening.

I'm using the latest version off github (2.1) and it just happened again when starting the game and just loading up my career save.

Here is the log from startup till loading the save and realizing I have too much money.

This is how my budget should look and this is how it really is. Also this is my gamedata in case you can make out any problem causing mod combination.

Thanks for your effort creating the mod nonetheless!

Edit: Also just reloading the persistence from inside the game prevents the budget from being distributed and everything stays the way it should be.

Edited by Amnesy
Link to comment
Share on other sites

Dunno about all others, i always have a lot of credits earned. This brings me to the idea - could  you add costly rescue action, depending of how far has landed your spacecraft to KSC. I mean if player did "recover vessel" - this should cost credits. 

Or may be someone already did such mod?

Link to comment
Share on other sites

7 hours ago, Amnesy said:

I'm using the latest version off github (2.1) and it just happened again when starting the game and just loading up my career save.

Here is the log from startup till loading the save and realizing I have too much money.

This is how my budget should look and this is how it really is. Also this is my gamedata in case you can make out any problem causing mod combination.

Thanks for your effort creating the mod nonetheless!

Edit: Also just reloading the persistence from inside the game prevents the budget from being distributed and everything stays the way it should be.

Looking at your log it does seem that it's running a couple of cycles before the save is loaded. However, you also have a TON of exceptions which may be contributing - namely, RPM is not working properly at all, and a bunch of Contract Configurator stuff about broken contracts (some of that is my fault as I need to update Bases & Stations to work with USI LS again). - I'd recommend working through those.

Having said all that, I do suspect the problem is at my end - Can you try this dll (just copy/replace the old one after taking a backup) and see if it helps (make sure you back up your save). If not, a copy of your save would be useful.

Edited by severedsolo
Link to comment
Share on other sites

Thanks for the quick response and the catch with rpm ! I'll check your dll tonight when I get home and report back.

 

Edit: 

10 hours ago, severedsolo said:

Looking at your log it does seem that it's running a couple of cycles before the save is loaded. However, you also have a TON of exceptions which may be contributing - namely, RPM is not working properly at all, and a bunch of Contract Configurator stuff about broken contracts (some of that is my fault as I need to update Bases & Stations to work with USI LS again). - I'd recommend working through those.

Having said all that, I do suspect the problem is at my end - Can you try this dll (just copy/replace the old one after taking a backup) and see if it helps (make sure you back up your save). If not, a copy of your save would be useful.

I just tested your dll and the error seems to persist. I've also fixed the issues you mentioned in the log so I'm confident to say that it shouldnt be anything else's fault. The weird thing is that it just happens when I load the game from the main menu. If after finding myself with too many funds I go in the F9 menu and reload the persistence, everything will be as expected.

In case you can use my save - here you go. 

 

Edited by Amnesy
update
Link to comment
Share on other sites

8 hours ago, Amnesy said:

The weird thing is that it just happens when I load the game from the main menu. If after finding myself with too many funds I go in the F9 menu and reload the persistence, everything will be as expected.

It's not that weird. The mod loads itself the first time you go to the Space Centre, unlike most other mods, it doesn't destroy itself on each scene change (because of issues like the one you describe), it just goes dormant if you aren't in the right environment (like say a Sandbox game). It's frustrating because I can't reproduce it, but I suspect that for some reason, your copy of KSP is firing Update() before it's ready (but I have no idea why! it's supposed to not do anything until the "ready" flag gets flipped).

Hopefully, I can fix this by starting the mod when you reach the main menu. Try this build. if that doesn't work, I'll write some debug lines, and get you to provide another log.

Edited by severedsolo
Link to comment
Share on other sites

48 minutes ago, severedsolo said:

It's not that weird. The mod loads itself the first time you go to the Space Centre, unlike most other mods, it doesn't destroy itself on each scene change (because of issues like the one you describe), it just goes dormant if you aren't in the right environment (like say a Sandbox game). It's frustrating because I can't reproduce it, but I suspect that for some reason, your copy of KSP is firing Update() before it's ready (but I have no idea why! it's supposed to not do anything until the "ready" flag gets flipped).

Hopefully, I can fix this by starting the mod when you reach the main menu. Try this build. if that doesn't work, I'll write some debug lines, and get you to provide another log.

Still happening :( Another log would be here.

Things I see inside are two NREs for monthly budget. The other one is from Bases and Stations but happen at an entirely different time in the log. I also have this weird 'Updating delegates' expression being spammed in the log as soon as I launch any vessel. Can't narrow down that one either. I probably should do a clean install with all my mods and see if the bug persists.

Link to comment
Share on other sites

19 hours ago, bird19 said:

Dunno about all others, i always have a lot of credits earned. This brings me to the idea - could  you add costly rescue action, depending of how far has landed your spacecraft to KSC. I mean if player did "recover vessel" - this should cost credits. 

Or may be someone already did such mod?

Stock already does this, you recover a percentage of the ship's build cost, which depends on how close to the KSC you landed

Link to comment
Share on other sites

45 minutes ago, Amnesy said:

Things I see inside are two NREs for monthly budget.

Nothing to worry about, that's just because the Toolbar isn't up yet.

Looks like one of your mods is forcing the game to save itself when you load a save. Because MB isn't ready yet, lastUpdate gets saved as 0, and it then forces a budget update. I'm gonna recommend the 50/50 method to eliminate the culprit, because it is not happening on my build (go back to the official release build, as the debug ones I sent you are probably a bit hacky).

 

Edited by severedsolo
Link to comment
Share on other sites

14 hours ago, Amnesy said:

Still happening :( Another log would be here.

Your log was actually really helpful, I've got a handle on what the problem is now, and to be fair it's a situation I should be handling.

I've got a fix in mind, but before I give you another test build, if I fixed it so it wouldn't occur until you got to 64 years (in kerbal time - assuming default months) would that be enough?

Link to comment
Share on other sites

4 hours ago, severedsolo said:

Your log was actually really helpful, I've got a handle on what the problem is now, and to be fair it's a situation I should be handling.

I've got a fix in mind, but before I give you another test build, if I fixed it so it wouldn't occur until you got to 64 years (in kerbal time - assuming default months) would that be enough?

Sounds great ! 

64 years should be plenty, but I won't be able to test your build till Sunday ^^ thanks for making an effort tho 

Link to comment
Share on other sites

7 hours ago, Amnesy said:

Sounds great ! 

64 years should be plenty, but I won't be able to test your build till Sunday ^^ thanks for making an effort tho 

No problem mate, now I know what the problem is I can reproduce myself.

Alright, this one should fix it. I'll hold off releasing until I get your confirmation, but I'm confident this will do it.

Link to comment
Share on other sites

On 28.10.2016 at 8:52 PM, severedsolo said:

No problem mate, now I know what the problem is I can reproduce myself.

Alright, this one should fix it. I'll hold off releasing until I get your confirmation, but I'm confident this will do it.

Alright, finally can confirm that the issue is fixed :)  Good Job!

Link to comment
Share on other sites

Just now, Hrv123 said:

Most likely dumb question, is MB compatible with RO/RSS mod bundles?

Should be. The only thing to take into account is that the budget interval assumes Kerbal days. So you need to multiply however many days you want in a month by 4.

Link to comment
Share on other sites

Great mod.  Now I'm messing with Contract Configurator to see if there's a way to gain reputation in an automatic, reasonable manor just by playing the game.  Something like the world firsts, but repeatable.  That way the player can do the missions they want and still be rewarded rep for their effort.

Link to comment
Share on other sites

I see smome strange numbers in my game, maybe i miss something?

 i have 4 unassigned Kerbals, and 2 active vessels

Vessel Maintenance cost, and unassigned kerbal wages are set to 1000, so i would expect montly cost of 6000 at this point, yet the budegets window states montly cost of 24000.

 

 

Edit: Setting one of the Satelites as depracted (change its type to scrap) the monthly cost drops to 14000, so monthly budgets calculates 10000 per active vessel, despite the fact that i changed this in the options to 1000

Edited by Filigan
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...