Jump to content

[1.12.x] Bureaucracy - Monthly Budgets, Reimagined (1.7.2 - 30/11/2024 (Under New Management))


severedsolo

Recommended Posts

Bureaucracy 1.3 Released

  • Newly hired Kerbals will now go straight to level 1 after completing their training.
  • Fixed a bug where Bureaucracy would inform Kerbalism it was taking control of the science, even though Bureaucracy's science system was disabled.
Link to comment
Share on other sites

21 minutes ago, Nikola said:

So if I intend to disable facility maintenance costs entirely, will the auto-balancer override that?

Yes. If you want to change maintenance costs, you need to turn the auto balancer off (I should probably change that though - because quite frankly, I wrote it and forgot about that, so it's obviously not very intuitive).

Edited by severedsolo
Link to comment
Share on other sites

  • 2 weeks later...

I see that Kerbalism has fixed this mod's issue *today*. This is how I discovered the Bureaucracy mod. Bureaucracy looks fun. It would be interesting to connect crew morale with Kerbalism's mental states, lifetime radiation, etc. No idea how complicated this would be.

Can I add this on top of an existing Kerbalism career save of should it be on a new game (when I get there...). 

Link to comment
Share on other sites

16 hours ago, Bongotastic said:

Can I add this on top of an existing Kerbalism career save of should it be on a new game (when I get there...). 

Recommended to start a new save in general, because Bureaucracy pushes its hooks into lots of career stuff, it's intended to be a career playthrough in its own right.

Regarding the crew stuff, it's definitely the weakest part of bureaucracy - I can't talk much about that right now, there are things in the pipeline, but I'm not sure how it's going to work out so don't want to make promises I can't keep.

Link to comment
Share on other sites

  • 2 weeks later...

Hey guys, I've just published a pre-release of Bureaucracy 1.4 and would appreciate your help with testing it.

Changelog:

  • Kerbals can now retire and will be assigned a random retirement date on first load. They can delay their retirement date by running missions (Credit for the idea to the RP-1 team, code is my own)
  • Kerbals can now be trained using the new "Crew" option in the UI. By default this training will cost $100000*newLevel and will take newLevel months to complete.
  • UI windows will no longer lock all control
  • UI windows can be toggled by clicking the toolbar icon again
  • BaseStrikesBeforeKerbalQuits increased to 10 by default.
  • New Settings: RetirementEnabled, RetirementExtensionFactor, MinimumTerm, MaximumTerm, BaseTrainingFee - see wiki for more details.
  • Save Upgrade Pipeline updated to run from 1.1 to 1.4. Saves from a version of Bureaucracy prior to 1.1 will be reset to default. If in doubt, check the version in BureaucracySettings.cfg

The changelog says "refer to Wiki" for the new settings but I haven't actually updated the wiki yet, so I'll outline them here:

  • RetirementEnabled (bool) - whether Kerbals will be allowed to retire.
  • RetirementExtensionFactor (float) - how much of a completed missions MET is added to the retirementDate (so for example: if this was set to 0.5 and a kerbal had been gone for 10 days, their retirement would be pushed back by 5 days).
  • MinimumTerm (int) - The minimum amount of time (in years) a Kerbal will be given before they retire.
  • MaximumTerm (int) - The maximum amount of time (in years) a Kerbal will be given before they retire (note this does not include "extra time" from doing missions. This is the base value a kerbal is assigned when the retirement system runs on that Kerbal for the first time).
  • BaseTrainingFee (int) - The base cost of training. The actual cost is calculated as BaseTrainingFee*<kerbals new level>

As ever, back up your saves first. I've tested it, and it seems to basically be working, but it's not had a thorough beating yet, which is where you guys come in.

You can get the Beta here

Edited by severedsolo
Link to comment
Share on other sites

@severedsolo, Bureaucracy won't let me upgrade the R&D building. Other building upgrades work fine but trying to upgrade the R&D gives a nullreff.

link to the full log

Here's the (I think) relevant part:

Spoiler

[LOG 12:56:51.648] [Bureaucracy]: Trying to override upgrade button of menu for RnD
[LOG 12:56:51.648] [Bureaucracy]: Found upgrade button, overriding it.
[LOG 12:56:54.362] [Bureaucracy]: Upgrade of SpaceCenter/ResearchAndDevelopment requested
[EXC 12:56:54.365] NullReferenceException: Object reference not set to an instance of an object
    Bureaucracy.BureaucracyFacility.IsDestroyed () (at <1fa3720b36174dfcac4e13264736202f>:0)
    Bureaucracy.FacilityManager.StartUpgrade (Upgradeables.UpgradeableFacility facility) (at <1fa3720b36174dfcac4e13264736202f>:0)
    Bureaucracy.FacilityMenuOverride.HandleUpgrade () (at <1fa3720b36174dfcac4e13264736202f>:0)
    UnityEngine.Events.InvokableCall.Invoke () (at <5aeafee3fea24f37abd1315553f2cfa6>:0)
    UnityEngine.Events.UnityEvent.Invoke () (at <5aeafee3fea24f37abd1315553f2cfa6>:0)
    UnityEngine.UI.Button.Press () (at <22fd67f59718453e9250a6de1843ef8b>:0)
    UnityEngine.UI.Button.OnPointerClick (UnityEngine.EventSystems.PointerEventData eventData) (at <22fd67f59718453e9250a6de1843ef8b>:0)
    UnityEngine.EventSystems.ExecuteEvents.Execute (UnityEngine.EventSystems.IPointerClickHandler handler, UnityEngine.EventSystems.BaseEventData eventData) (at <22fd67f59718453e9250a6de1843ef8b>:0)
    UnityEngine.EventSystems.ExecuteEvents.Execute[T] (UnityEngine.GameObject target, UnityEngine.EventSystems.BaseEventData eventData, UnityEngine.EventSystems.ExecuteEvents+EventFunction`1[T1] functor) (at <22fd67f59718453e9250a6de1843ef8b>:0)
    UnityEngine.DebugLogHandler:LogException(Exception, Object)
    ModuleManager.UnityLogHandle.InterceptLogHandler:LogException(Exception, Object)
    UnityEngine.EventSystems.EventSystem:Update()

KSP version: 1.8.1

Bureaucracy version:  1.1.5

Edited by EchoLima
Link to comment
Share on other sites

3 minutes ago, Biggles16 said:

What are the current conflicts with KCT and additional launch locations from mods like Kerbin Side Remastered?

KCT you just need to choose whether to let Bureaucracy for KCT handle your facility upgrades, and turn it off for the one that you don't want to use.

Additional launch locations should be fine - Bureaucracy doesn't touch launch code at all, and I'm currently using it in JNSQ with Kerbal Konstructs with no issues.

Link to comment
Share on other sites

  • 2 weeks later...

Getting an error with what I presume is OPM (or Kopernicus as the dependency, whichever adds the observatory) where it won’t let me upgrade it when I click in the KSC scene.

Can’t remember the exact error message, I’ll check whenever the broadband’s back up so I can get into Steam.

Link to comment
Share on other sites

2 minutes ago, Deathninja said:

Getting an error with what I presume is OPM (or Kopernicus as the dependency, whichever adds the observatory) where it won’t let me upgrade it when I click in the KSC scene.

Can’t remember the exact error message, I’ll check whenever the broadband’s back up so I can get into Steam.

Ill need the log, so I can see exactly where is falling over

Link to comment
Share on other sites

1 hour ago, severedsolo said:

Ill need the log, so I can see exactly where is falling over

OK, got online.

When clicking "Upgrade" I get "Can't find facility SpaceCenter/Observatory"

I open the log but it's over 36K lines just from game start and that action. I manually searched for Bureaucracy and the only salient lines I found were:

On load:

[LOG 10:46:32.199] [KCL] malformed version string: 3.0 in directory FlightTracker/Changelog/KERBALCHANGELOG

On action:

[LOG 10:48:49.957] [Bureaucracy]: Trying to override upgrade button of menu for Observatory

I did notice the Facility Manager routine doesn't have a setup call for the observatory like it does for the other buildings (e.g. [Bureaucracy]: Setup Facility Runway) so I suspect it's not patched in.

Link to comment
Share on other sites

11 minutes ago, Deathninja said:

I open the log but it's over 36K lines just from game start and that action. I manually searched for Bureaucracy and the only salient lines I found were:

I don't mean to be awkward about this, but I really do need the full log. Upload it to dropbox or another file sharing site and send me the link.

What you've given me gives me a start, it tells me that at the point Bureaucracy sets up the Facilities the observatory isn't in the list. What it doesn't tell me, is what mod is causing the issue (ResearchBodies I suspect), when the Observatory is added (in relation to Bureaucracy loading) or what I can do about it.

With a log, I can dig through the load order and find the salient code in the offending mod and try to workaround it.

Link to comment
Share on other sites

12 minutes ago, severedsolo said:

I don't mean to be awkward about this, but I really do need the full log. Upload it to dropbox or another file sharing site and send me the link.

What you've given me gives me a start, it tells me that at the point Bureaucracy sets up the Facilities the observatory isn't in the list. What it doesn't tell me, is what mod is causing the issue (ResearchBodies I suspect), when the Observatory is added (in relation to Bureaucracy loading) or what I can do about it.

With a log, I can dig through the load order and find the salient code in the offending mod and try to workaround it.

Apologies, was unsure if it would help or hinder, I'll sort something out.

Link to comment
Share on other sites

Just now, Deathninja said:

Apologies, was unsure if it would help or hinder, I'll sort something out.

If in doubt always provide the full log :)

No worries though, if it was a problem just in Bureaucracy what you gave me would absolutely have been enough to diagnose it. I know the exact point my code is falling down, but my code isn't the problem (and to be clear - ResearchBodies (or whatever) isn't bugging out either from the information I have).

From the sounds of it, it's just a case of Bureaucracy doing it's setup before ResearchBodies (or whatever) has finished doing it's.

Link to comment
Share on other sites

31 minutes ago, severedsolo said:

I don't mean to be awkward about this, but I really do need the full log. Upload it to dropbox or another file sharing site and send me the link.

What you've given me gives me a start, it tells me that at the point Bureaucracy sets up the Facilities the observatory isn't in the list. What it doesn't tell me, is what mod is causing the issue (ResearchBodies I suspect), when the Observatory is added (in relation to Bureaucracy loading) or what I can do about it.

With a log, I can dig through the load order and find the salient code in the offending mod and try to workaround it.

OK, have a link now, spammed the button until I got some more related messages in there:
https://www.dropbox.com/s/7iu779c1s2k8ddn/KSP.log?dl=0

Link to comment
Share on other sites

Just now, Deathninja said:

OK, have a link now, spammed the button until I got some more related messages in there:
https://www.dropbox.com/s/7iu779c1s2k8ddn/KSP.log?dl=0

Thank you - I am about to start work, but will look at it this evening. I was going to release 1.4 today, so if I can get a fix in for this too I will do.

Link to comment
Share on other sites

10 hours ago, Deathninja said:

OK, have a link now, spammed the button until I got some more related messages in there:
https://www.dropbox.com/s/7iu779c1s2k8ddn/KSP.log?dl=0

Could you try this build and see if it fixes your issue before I release.

Bleeding edge build, back up your saves etc (should be fine, but it's late, and I've been known to balls up worse than this before XD)

Things I need testing:
1) Does it clear the "Can't find the facility" issue (my testing says yes, but I tested on a minimal install, so throw your mods at it and see what happens)

2) Does it remember your upgrade between scene switches

3) Does the upgrade actually complete.

I'm fully expecting the answer to all those questions to be yes, because the actual internal structure of how the upgrades happen hasn't changed at all.

For those of you interested in the technical details, see spoiler:
 

Spoiler

ResearchBodies is basically forcing a new Facility into the list of facilities. Unfortunately, it's doing that after Bureaucracy has done it's thing, meaning when Bureaucracy goes "get me a list of facilities!" it's not grabbing the Observatory.

Waiting for RB to do it's thing and then grabbing the list isn't feasible, because RB loads it's data really late (long after Bureaucracy does) - and we don't get a choice as to when to load data, when KSP offers up the file we have to use it.

So what to do instead? Well, actually Bureaucracy doesn't need the facilities at load time, it just needs to be aware it exists so it can generate the data for it. So, once it's done going through the list, it checks whether RB is installed. If it is, it sets itself up a new bit of data for a facility called Observatory, on the understanding that when it does need that facility, it will be there.

 

Link to comment
Share on other sites

58 minutes ago, severedsolo said:

Could you try this build and see if it fixes your issue before I release.

Bleeding edge build, back up your saves etc (should be fine, but it's late, and I've been known to balls up worse than this before XD)

Things I need testing:
1) Does it clear the "Can't find the facility" issue (my testing says yes, but I tested on a minimal install, so throw your mods at it and see what happens)

2) Does it remember your upgrade between scene switches

3) Does the upgrade actually complete.

I'm fully expecting the answer to all those questions to be yes, because the actual internal structure of how the upgrades happen hasn't changed at all.

For those of you interested in the technical details, see spoiler:
 

 

Updated log: https://www.dropbox.com/s/7iu779c1s2k8ddn/KSP.log?dl=0

 

Can enter and leave scenes with no issues, can press the button and it gets added to the queue, but seems to halt all construction (I had a few others pending, set construction to 100% and ran through about 5 or six budget cycles with no progress).

It's getting late here so can't really test any more tonight, sorry.

Link to comment
Share on other sites

15 hours ago, Deathninja said:

Can enter and leave scenes with no issues, can press the button and it gets added to the queue, but seems to halt all construction (I had a few others pending, set construction to 100% and ran through about 5 or six budget cycles with no progress).

sigh thank you - I've tested my end and can confirm it's working so must be a mod conflict (I can see it's not working from your log but it's working here).

Can you test in a new save, and make sure that it's not just your save that was messed up from the original bug.

If it's still not working in a new save (and you still want help with it), you'll need to do the 50/50 method - ie keep half your mods (and their dependencies) until you track down the minimum mods I need to install to reproduce (keep ResearchBodies and Bureaucracy in each time).

Link to comment
Share on other sites

On 6/5/2020 at 3:18 PM, severedsolo said:

sigh thank you - I've tested my end and can confirm it's working so must be a mod conflict (I can see it's not working from your log but it's working here).

Can you test in a new save, and make sure that it's not just your save that was messed up from the original bug.

If it's still not working in a new save (and you still want help with it), you'll need to do the 50/50 method - ie keep half your mods (and their dependencies) until you track down the minimum mods I need to install to reproduce (keep ResearchBodies and Bureaucracy in each time).

Sorry for going dark, been really sick the last couple of days.

On a fresh save with the same mods I cheated up 100 rep for regular funds and left it on timewarp. Everything's working as expected.

Haven't been able to replicate the issue of all construction in the queue freezing either.

Thanks so much for fixing this; I hope I didn't come across as pushy (I have trouble gauging tone) I only posted in the first place becuase I didn't know if there was already a simple fix or workaraound at the time.

Link to comment
Share on other sites

1 minute ago, Deathninja said:

Thanks so much for fixing this; I hope I didn't come across as pushy (I have trouble gauging tone) I only posted in the first place becuase I didn't know if there was already a simple fix or workaraound at the time.

No worries, you definitely didn't come off as pushy.

The frustration came from my end, as you were reporting issues that I was unable to reproduce - which makes it difficult to fix :D

Thank you for confirming the fix, I'll put it in the 1.4 release

Link to comment
Share on other sites

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...