Howdy Everyone.
I'm glad to see that everyone's been made slightly more lively by my code, or sorry that you've lost so much sleep over a few lines of code. In that respect I'd like to start off by saying that I try to read as much of everyone's feedback as I can, and I take as much of it as I can manage to heart to make sure that the projects I work on are things that people enjoy and make the game more interesting.
If I was trying to kill /tg/station, I'd probably have gotten gitbanned by now, anyway.
Also you're going to have to do some reading. I don't apologize.
So, let me try and clear the air about the content of the current economy PR that I wrote, and break it down as best as I mechanically can, while communicating intent, and I'll follow it up with some Frequently Screamed Questions that I've heard people discuss and my thoughts/answers to the subjects.
What is the Purpose of the Cash Economy in SS13?
For the purposes of this discussion, an economy is basically a controls problem. It assumes that resources go into a system actively, and that resources leave that system periodically. In practical terms most of these systems become easier to work with when you have less inputs, and less outputs, because you can account for where more resources wind up and how to handle that. The Power Economy is all the power generated by the Engine/Turbine/Solars/Hampsters on Wheels less the power used by the station and the crew. The material economy is all the resources round start on the station and mined by cargo minus how often those resources get expended/used up/thrown away. Pretty much anything can be described as an economy, and if you look back at any of those examples you'll see that we've fucked up just about every single one of those from a balance perspective, since we have too many materials, chronically produce too much power if it's been set up at all, and in the original version of the cash economy crewmates had obscene amounts of cash to the point that you could buy multiple bikes in a single round. Hell, when we added the cash economy, we had a LITERAL money tree.
It grew money. I digress.
The cash economy was rather arbitrarily designed the first time around, heavily based around the cargo department's cargo points, which was similarly a mess in 2016, and even then it wasn't designed to be fair or to have any kind of interaction with the rest of the station outside of buying cans of soda every once in awhile. Since about 2018 I've been whittling away economy to try to make it a system that players not only engage with but have to make choices about in a single given round. The vison here is that economy would be a system that emphasizes a player's choices throughout the round, either periodically throughout with smaller purchases or inter-player interactions, and for major mid to late-game purchases of supplies and useful or unique items. You could be the type of player that just uses economy for buying candy bars to satiate hunger when you're away from service, or you could be the type of player that hordes money away to get those 1200 credit insulated gloves. In that respect, economy is integrated into several other systems in the game, but serves more as a booster than it is a full on replacement in any category. You can break into the armory to get a collection of weapons, or craft ghetto weaponry, but economy give you a personal supply of cash to invest into buying cargo weaponry instead. Want to build the nicest shuttle known to man? You could use credits to buy nicer furniture or hire crew to help you make it look good, and those credits can go to other crew's personal projects, and so on.
It was not originally designed as a primary system and without tearing out literally everything it is hard to implement it as such, so that's never been my intent. It is a supplementary resource that crew can use to solve problems on the station, and occasionally to create problems when nobody has any of it.
What changes were included in PR#65795?
Link to the PR.
https://github.com/tgstation/tgstation/pull/65795
A good majority of it is covered in the PR body but I'm being through here so that I don't have to do this again.
Price Normalization
For all items in vendors, as well as goodie items in cargo, I normalized the values of nearly every price in the game. In-game, all items that can be purchased with credits are done so using something called Defines. Basically it's like code-wide variables that make it easier to copy-paste certain information across the code. In past work of mine I made it so that every job in the game had the prices of the items that they buy written in terms of these defines, with each define described in terms of each paycheck in the game. So, if I as a bartender want to buy a bottle of champagne, I know that it's worth 2 of my paychecks within the code, making it easier to assign new costs to new items by scaling it to when and where in a round it's going to be available. As a result, it became clear to me that this tied in with a very specific issue with economy that has always existed. Most crew on the station winds up in just about 2 mindsets: Players who have so much money that they could ever realistically run out based on what they need for that shift (Heads of staff, high pay-grade jobs), and players who have so little money to afford anything on-station, and completely disregard anything to do with economy considering how much work they'd need to do to get "caught up".
The largest, and most sweeping change whether you believe it or not is that I have replaced pay-grades with a much smaller and closer packed pay-grade system to prevent that from happening and put players on level footing, as well as drastically decrease the difficulty in making decisions about economy integrated choices. Most crew have had their paygrades shifted to the same levels, so instead of there being 7 different paygrades between 25 credits and 200 credits each, there are 3 paygrades each between 25 credits and 100 credits, with the low-paygrade covering just high-population jobs that don't cater well to the economy (25 credit tier), the crew-paygrade tier for most jobs previously between assistant and security (50 credits tier), and command-tier for heads of staff (100 credit tier). Intended benefits of this would mean that you create more common ground about the singular value of credits within the round. Now every job looks at something like 50 credits the same way, as job items are all scaled the same way, and crew are going to have roughly the same money to begin with. This also means that job changes aren't going to put you drastically far behind someone who started in that job initially. If you changed from a botanist to a security officer, for example you previously would have several hundreds of credits behind the job your changing into, BEFORE you got supplied with resources that you would need to purchase anyway. If nothing else, I'd like to get this change into the game with this PR.
Briefcase of Cash Change
The briefcase of cash can be used aggressively to destroy the economy as it stands, and has
literally not been changed since it was added in 2012. It costs 1 TC, It gives the player 5000 credits, and can be purchased an unlimited number of times. Before the shift to progression traitors, you could drop all your TC and get a grand total of 100k credits at shift start. Now, with progression traitors, you can make something like 25k credits per paycheck if you're efficient and able to complete objectives without being caught out too quickly. With the price of everything on station dropping as a result of these changes, even with very, VERY few of these total you can effectively buy everything on station, as well as just about everything worth buying as a traitor with cash (Medkits, Guns, Plasma Tanks, maybe an ATV). A common misconception that people have been throwing at me is that the briefcase of cash is intended to be a powerful item, to which I have to completely shut that down and disagree. It was added originally to the pointless fun category of traitor items over 10 years ago before the economy even existed. In an ass backwards way, it's been one of the few consistent things about economy before it even existed, getting overlooked when crates were dropped from 500 credits to 200 credits each (Which resulted in a major rebalance of all existing prices the first time), when passive income was removed initially, all of these changes were made with this getting largely looked over and I thought it was time that we decreased the power level of a literal meme item that make the balancing of everything else a joke.
And yes, I've been told about the mining points -> cash conversion. I didn't make a change to that yet because I have no fucking clue how many points miners get nowadays because I don't play very much miner, and so I didn't attempt to make a change to that before I can make an educated decision.
Passive Income
This is the part of the change that predicated the addition of the lathe tax. Sit tight.
So, passive income is stupid. But, it solves a very real problem from a design standpoint that economy has run into since my original PR, being that money lost it's correlation to time, in a game heavily based around the lengths of rounds. By having passive income added back, you get an idea of how much time something is worth every time you make a purchase. If you're 100 credits off from buying something round start, assuming you're playing without
any inter-player interaction, you can expect to have enough credits for that thing in 10 minutes. This is a conclusion that I came to through one of the few discussions with maintainers I have ever managed to eek out in the past few months, because of discussions with maintainers. But I still hold that my original assessment was correct, that if players keep making money over time, while having literally zero expenses and not enough things worth buying between all the vendors on station, they will end up making colossal amounts of money and at a certain point exchanging money will become useless. If everyone on station has 1000 credits and full gamer gear, when the only things left to buy are 15 credit candy bars and the occasional cable coil from a tool vendor, than they won't have any attachment to the system and there's no real consequences attached to the system. If you don't have money, you don't buy things. You don't need to buy things. So what's the fucking point?
So I mused on this for a few months from about December to mid February. I decided to turn the situation into a control problem, as I showed on the original Hack.md.

So, taking a few liberties on the cost of individual items as well as knowing that certain items were going to vary wildly in cost, and that players spending couldn't be easily handled every round, I started by making a simulation in MATLAB to model how much players were going to be making on average every round, that could be adjusted for the now 3 different paygrade levels, combined with the benefits of bounties and potential secondary income flows like tourist bots. Using the codebase model average of 90 minute expected rounds, and a player count of about 60, here's roughly what this looks like:

This models a total of 1000 simulated rounds of player spending, assuming they're making average crew level income, that only 5% of all players do a single bounty, and not accounting for secondary income, which can be enabled. Adjusting and improving this model is what made me come to the conclusion that passive income was going to be simply far, FAR too high to leave in without some kind of mechanical stopgap to prevent players from using this system without some kind of dampening. We want this system to be underdamped, but not to the point where the only costs we can add to the system are so little that they player doesn't wind up having to make choices. After all, it's a game-wide player resource, and if you're not having to make choices then it's not a mechanic.
For those who'd like to check my work, I can upload my MATLAB file somewhere for the income simulation if anyone would like.
The Lathe Tax.
If you just scrolled down here without reading the other sections of this post, go back, read it. It'll be obvious you skipped to this part.
A minor but persistent cost into the new passive income system was going to be required to keep the system in check, and I have had a lot of time to consider different avenues to go about something like this. I'd been collecting log data from rounds for economy testing every few months since about mid 2020(
Here), and tweaking that logging when necessary as I need new information. Just adding new things to buy with credits as well is something I'd been doing since I started seriously coding in about 2019. But nearly everything added to the game is added to the techweb, or the lathe. You can't charge people for things that you can get for free. Why would you buy a wrench from a vendor if you can break into cargo for 3 seconds, print a wrench for a negligible amount of metal, and then
never need a new wrench again?
Before I went ahead with this I looked into a downstream PR that I'd known about for quite some time now that did something similar:
Credit to Mudzbe. I believe it's also been tried a few times on a few other downstreams, too, but I cannot find those PRs as quickly. The meat of it is that several other servers have tried to implement a basic cost to offset passive income to the lathe (Remember, most of our downstreams still have passive income). On one of these PRs they similarly also scaled the credit cost of printing things to it's material cost. I considered doing so as well, but reconsidered after remembering that material cost on most items is 100% redundant. If a printing cost was scaled to the amount of materials used, a wrench would probably cost you 1 credit, and a circular saw would cost you about 67 credits, if not more. This would be fine for preventing assistants from breaking into cargo and printing items form their lathe, but you have to recall that circular saws are
still job critical items for the medical department. Having to work around and with material balance of
EVERY SINGLE MATERIAL ITEM is not only tedious, but untenable with the amount of printable items being added to the game every day. Besides, I personally have already
tried and
failed to work around the batshit insanity that materials and their potential value have already. It's not an avenue worth going down without a considerable more work to the material economy.
So what I settled on was a flat, consistent rate for printing items from lathes. 10 credits maximum, 2 credits if printing something from your own lathe. The discount was implemented after the consideration that building projects were going to be too expensive to be able to do in a regular length round, and at 10 credits I could certainly agree. I also quickly tried implementing inflation on printing numbers but
Wow holy shit that was awful. This means that people printing items for use on-station is still perfectly available, but unless you are printing hundreds of items from a different departments lathe, or about
500 items from your own lathe, you will still have a rather substantial amount of credits left over. And besides, if you are in a situation where you're printing items in critical excess like that, then there are additional ways to make credits to do so, or you can... do things for other players that they will pay you for. See, this whole system breaks down when you realize that SS13 is still a multiplayer game, and if you want more money you can always work together with other players if it's overwhelming to do singlehandedly.
The codebase doesn't support arcade-style gameplay. Most players aren't going and printing more than 10 items in a given round, and more often then not it's from their own lathes if it's necessary.
I want to break this out into an FAQ below because I've noticed a lot of similar comments and some of them I've already touched on so that I can hit as many of them as possible, but I'll do that in a separate post so that I can get this information out as fast as possible.