So you may have missed it, but we launched Production Line out of Early Access almost exactly a week ago. It looks like we have had a pretty good launch. We were in various charts in various categories, sold a lot of copies, got some good word of mouth coverage, and a fairly minimal amount of bug reports. I have remained relatively calm, and relatively sane, and am still motivated to improve the game and continue to do (some) work on it for the next few months. Woohoo.

TBH this is the smoothest game launch is Positech’s history. This is the first time I’ve done early access, so its the first time I’ve had literally tens of thousands of people hammering the game code *before* I officially declare the game *done*. Frankly, these days most indie games get a way bigger EA launch than a final product launch, so its not as gentle a ramp up as it sounds, but it still resulted in a pretty bug free departure from Early Access

Something I was very happy with was that I could set the ‘final’ build live for all the EA players, not touch the game *at all* for a few days, and when I was absolutely sure everything was fine, just literally click the ‘release out of early access’ button knowing that things were pretty stable. I highly recommend this!

So far we have had ONE patch since release, which fixed a short list of things, and there is another one on the way in maybe a week or so, which will be the accumulation of a bunch of bug fixes (even some pretty rare crashes) and some UI features people have asked for like a camera speed slider, autosave interval slider, and some extra stats. It feel so good to be in a position where people are saying ‘the game needs a better UI for feature X’ instead of ‘the game needs feature X’.

I definitely have plans to do some paid content for the game (DLC) alongside regular updates. I’m obviously not in a position to even tease anything like that yet, but as I prefer content-heavy DLC to code-heavy DLC (its just optimal given that I am the only coder), such things do not take *much* time to do (although there is of course a big art budget cost).

Right now I’m pretty happy with how Production Line has gone. Even if the game makes NO MORE MONEY AT ALL, I’ll be happy (but amazed!), and I think over the long tail of the next 2+ years there is a good chance of it making at least 50% of its current earnings again, which I’d be very happy with. I’m currently minded to *not* go mad with sales and discounts, as I think this is getting a bit out of control and games are being devalued, but I may think differently about that in a years time.

Anyway, this is nothing but good news, which is a change from the usual indie ‘I sold no games and have eaten my pets’ stories, but I’m not going to pretend things went wrong when they didn’t. I always blog openly about my screw-ups (2 recent games still in the RED for me :(), so I may as well be honest when things go well.

Thanks to everyone who bought the game so far!

My super-complex spreadsheet which I use to track the spending and income for my latest game (Production Line) informs me that I have been working on it for 3.12 years, and have spent a (very roughly estimated) total of 9,115 dev hours on it. The game is leaving early access tomorrow!

In truth I have probably spent a lot more hours than that, as I tend to overwork, and spend a lot of time in evenings checking forums and reddit/facebook etc to reply to people, but anyway you look at it, 3.12 years seems to be quite a long time to work alone as the only coder and designer on a game.

Bizarrely, I am still very much enjoying the games development, and have a list of extra things I would like to tweak and improve after release. In many ways the decision that the game is ‘released’ is a purely arbitrary one. In marketing terms it encourages people who dislike the state of most EA games to try the game out, and it also signals a potential slowing down in the addition of new features.

I still have a lot of ideas for stuff that could be added to the game, and I suspect we will have some paid DLC once the dust has settled. I wont rehash my pro-DLC arguments here, but I’m in believer in it both as a developer and a gamer. Why will DICE not sell me panther tank DLC for Battlefield V? TAKE MY MONEY. (also new hats please!)

Speaking from a personal point of view.. I am TIRED. I’ve felt like it for a while, and I think I do need a brief period where I scale down my work slightly. We are currently working on Democracy 4 (I’m not coding on it), and helping to manage that is an imminent concern. I currently have NO PLANS for any other game after Production Line (as a coder), so I’m pretty free (assuming it sells ok) to relax for a bit.

While I relax (Maybe for an HOUR!), here is the new launch trailer for Production Line. I really enjoyed getting this made. I hope you like it :D

Oh and if you have suddenly decided to buy the game, you get a steam key and we get 95% of the money if you buy using the widget below!

I have a few reports of a bug in production line where people have got VERY good at the game and amassed tens of billions of dollars. Nothing actually crashes, but financial reports start filling up with gibberish like $-1,-4,-2,-0,-1,-3,-5 and so on. The cause is simple, the fix difficult(ish) and the wider implications worthy of comment.

Firstly, as most coders can already guess, its because I’ve gone outside the max limits on the data type I’m using. I use a ‘float’ for financial figures in the game (mainly because some items get percentage reductions due to global events and competition, so I need decimals) and because *somewhere* I must be casting it to an int (no idea where yet) the numbers I can represent are limited to -2,147,483,648 to 2,147,483,647 because an int is 4 bytes. If I was using only a float, things would be super different. More details here.

Anyway, although generally speaking numbers like that are big enough, in a financial sim, restricting any possible number to a max value of $2billion is not ideal. My game is not ‘realistic’ in costs, and its rare that players finances will exceed $100 million, let alone 2 billion, but obviously it happens now and then and the game kinda screws up.

The fix is easy. I just need to replace that datatype, but the actual implementation is a bit more messy, because that means old save games need converting or handling as I load those numbers in (right now the game only knows how to load ints, floats and strings and likely casts to ints somewhere). I also have to go through every place where those numbers get locally stored by any GUI code and ensure I’m not using ints there either, and of course I need to change my display code so it handles floats properly and converts them to strings properly.

TBH its likely only a days work, but assuming another day to test it, and then a few days of ‘unstable build’ roll-out to the hardcore before folding it into the main code branch, all this means that this will be a fix coming after release on Thursday, and NOT today :D

Perhaps the more interesting topic is how do you deal with edge cases and marginal cases with a sim/strategy game. I know from experience that people WILL push these games to the extreme and WILL break them. I’ve had negative reviews from people with >100 hours playtime because their extreme playtime has led to discovering exploits, and edge cases that allow them to ‘break’ the game.

Anyway, this is a real issue because making a balanced, playable, fun, reliable game that works for 99% of the playerbase takes 99% of the effort, and making it work perfectly in EVERY edge case is…another 99% of effort. Generally speaking, its way better to concentrate on fixes, features and changes which make the game better for the 99% than to fixate on the extreme edge cases, especially as a time-limited indie who can never do everything.

I’ll fix the numbers thing post-release, but I have to admit that are likely some other real edge cases that I never will. This is also true of any of my games, like Democracy 3, or Gratuitous Space Battles. There are probably obscure edge cases and tactics that you can discover in all my games that ‘break’ them, after 100+ hours of gameplay. Thats not shocking. I’m always going to make the majority of players who play in the ‘usual’ way my primary focus. Edge case fixes are something I like to do, and want to do, but you can never get them all, or fix them all. You will go mad trying to do so.

Do not forget that there are companies like EA/DICE where thousands of players will scream that ‘X’ is unbalanced or ‘Y’ breaks the game and has not been fixed!, and yet presumably those companies have 50x the manpower I do. The likelihood is that they have data that shows this is only true in 0.1% of cases, and their dev time is better spent elsewhere. I have no illusions that players will accept that as an answer, but that will not stop it being the case!

Production Line Updated to 1.68

February 28, 2019 | Filed under: production line

This is the last feature-update before we come out of Early Access. The next week is likely to just be bug fixing and usability/UI tweaks and fixes. Here is the list of new stuff:

1) [GUI] Changed vehicle renaming so it doesn’t annoyingly add (1) to a duplicate name until you leave that screen, to prevent driving people MAD.
2) [GUI] Component prices on the finance screen can now be sorted up or down by either name or price.
3) [GUI] Added remappable shortcut key (B) to toggle blueprint mode.
4) [GUI] Redesigned layout of car design screen to accommodate longer languages.
5) [Feature] Added Swedish translation and improved others.

6) [Bug] Fixed bug when adding items to a supply stockpile where some categories would occasionally not be shown.
7) [GUI] Smart junctions now retain their list of designs when switching in/out of design mode, and also add new designs to the default list.
8) [Bug] Fixed crash bug when moving existing paint drying slots.
9) [Feature] You can now move supply stockpiles, and they keep their configuration when moved.
10) [Bug] Fixed bug where if you changed floor textures under office space, then moved existing office facilities, the default office floor texture was not re-set.
11) [Feature] Added researchable make electric motor and make electric powertrain slots.
12) [GUI] Canceling a slot or facility movement action snaps the item back to its old location.
13) [Feature] You now get a brand awareness boost of up to 20% automatically if you have high number of sales over the last four hours.
14) [Bug] Moved slots now remember their import preferences.
15) [Feature] Telling a supply stockpile to copy a specific task’s requirements now links it, and it auto-updates to account for new research. Any manual change to the slot breaks the link.

16) [GUI] You can now place down conveyor belts as blueprints.

17) [GUI] The production schedules at the start of each line are now saved if you move that slot.
18) [GUI] Slight gradients on the vehicle design price slider now mark out the different price ranges.
19) [Content] Some new items have been added to various slots, to show gantrys, dashboards, shock absorbers, speedometers,automated platforms & scisssor lifts.

Hope you like the new stuff. feedback most welcome, as are bug reports, we really want a bug-free emergence from Early Access. Many thanks to all your support while the game was in EA. Suggestions for future updates also welcome. if you like the game, bought it from steam and have not yet left a steam review, it is much appreciated!

Coders talk a lot about technical debt. here is a rough definition:

“Technical debt” (also known as design debt or code debt) is a concept in software development that reflects the implied cost of additional rework caused by choosing an easy solution now instead of using a better approach that would take longer.”

It’s often used in the context of justifying redoing some work. As in… “we have a lot of technical debt. The best thing to do is rewrite all this properly from scratch”. To some extent that can be justified. The engine for your games is effectively your house foundations. Don’t start building a house without ensuring you have decent foundations, and all that sort of thing. The problem with this mindset is that people (or rather…computer programmers) often get into the situation where they want to re-code everything from scratch again, and again, and again.

The thing is, the more experienced you get, the more you realize that the big, messy, patched, complicated looking smorgasbord of code that you are working with probably HAS to look like that. it probably looks like that for a reason. Its not pretty, its not clean, it doesn’t make for nice diagrams but it WORKS and thats important.

If you think thats not true I point you towards the apache web server (literally a pun on ‘a patchy web server’) and Microsoft windows, an absolute towering pile of code mess that is the very definition of technical debt. How can I possibly view these as good things…?

The simple answer is: Practicality and commerce. Apache is not the most beuatiful work of art in terms of highly structured, elegant, perfectly designed code, and windows is literally the state of the art in horrible hacks. (Like this one, to ensure sim city still runs). To quote:

They reported this to the Windows developers, who disassembled SimCity, stepped through it in a debugger, found the bug, and added special code that checked if SimCity was running, and if it did, ran the memory allocator in a special mode in which you could still use memory after freeing it.

And it you are someone who considers code to be beautiful, who likes to describe themselves as ‘a software architect’ instead of ‘hacker’ (or code monkey), then stories like this will fill you with rage but…

…Apache sure is installed on a lot of servers, and a huge number of PCs still run windows. Why? Because accepting that your patchy, confusing, held-together-with-string piece of code is actually MORE reliable than new stuff you could code today is actually a sign of coding maturity.

I do not open source my engine, and TBH nobody would likely use it if they did, but part of my reasoning is that it would be embarrassing. I couldn’t even decide on a naming convention. At one point I didn’t care, and I had classes called things like IniLoader. Then I thought it would be cool to have a ‘G’ prefix to indicate game engine, so I have GArc GFile, GHashTable. At some crazy point I had my classes in all caps, hence DEBUGENGINE.h. Some of the code separates functions with /************/ some of it with //////////////////////////////. Pretty much the only coding standard was a member variable naming convention with FirstLetterCapped.

By far the two biggest embarrassing pieces of dodgy code in the ‘more or less part of the engine’ GUI code are the following. Please try not to laugh.

Stupidity one: I have a GUI_ButtonBase class, and a GUI_WindowBase
class . They are DIFFERENT things, with no connection, despite a button obviously being a derived class of a window in any sensible system. Thus my GUI_WindowBase class contains separate lists of buttons, and child windows. *sigh*.

Stupidity two: All my windows have a virtual function call CheckClick(int x,int y), which they process, then call on any children. You would think that this took the x,y of the current mouse position and operated on it, but for some reason I gave up bothering and use helper functions like IsMouseInside() to check such stuff, which ignores the passed-in x and y. I still go to all the bother of passing x,y, down the hierarchy, but its ignored. I’m just paranoid about it.

Sure I could fix this, I could rewrite my button code, junk that dumb x,y, thing and rename all my classes sensibly while I’m about it. I would then need to spend several days changing all the code in Production Line, AND checking it, and I *ASSURE* you, I would miss something. There would be a new crash bug. I wouldn’t spot it, and maybe after a dozen players encountered it, someone would tell me about it. I would have achieved nothing, but frustration for my players, and a smug feeling that my code was less embarrassing.

I’m not giving into that. My current code WORKS, it has less bugs than it *ever* has. My current game (Production Line) is more stable than ever, and more stable than any game I have ever shipped. Going back and changing parts of my engine because they look messy, or because modern code fashions have changed or because there is a new API or code pattern would be MADNESS.

Don’t be too hard on your old code. Sometimes age brings wisdom.