Category Archives: business

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.

Only part of the ‘true cost’ of producing a game is the narrowly defined ‘development cost’, as it should also theoretically include an allowance for ongoing studio costs over the lifetime of making the game. The cost of heating my home office, the accountant, the webhosting for all my sites (including this blog) and depreciation of my PC should all play a part in calculating the *true* cost of producing Production Line. (My car factory strategy game for the PC).

With this in mind I thought I’d briefly add up some estimates of the paper-cost, the estimated cost if I was paid a regular salary, and also the true, true cost.

So the basic cost, if I break it out into categories gets me a breakdown like this:

If I assume as lead programmer I should be earning £60,000 (first result I found. Note that I’m the only coder and have 20+ years coding experience), then things change a lot to look like this:

Then I need to add in the office costs. Firstly I’d get a pension as an employee, so I should add that in over the dev period (3 years of contributions), 3 years of accountancy, 3 years of webhosting, and as I replace my PC probably every 4 years, I need to allow for 3/4 of a new desktop PC. I also have 3 years of office internet and phone bill to include. There is stationary, heating and other bullshit, but lets just call that $200 a year. New chart:

So is anything learned from this short little exercise? Well there are many ways to interpret it. Firstly, It really looks like I may be undervaluing music and SFX in my game. Surely combined they should be more than 5% of my dev budget right? And translation, although the costs scare the fuck out of me, actually seems relatively small in terms of the big picture.

It also brings home just how important personal productivity and time management is. If I messed around on twitter less, got distracted less, and maybe got up a bit earlier each day, a 10% increase in my productivity would have a massive impact on overall costs, probably saving me enough to make a huge boost to the art budget.

It also shows me that trimming the art budget if the game is not doing well is absolutely the wrong target. Its all about the code.

And finally its worth keeping an eye on the external dev costs such as webhosting etc. Each item is small, but together they are virtually the same as the art budget. Also worth noting: I deserve an absolute monster PC every 4 years, thats for sure. Even if I doubled the price I pay for a PC, the faster compile times would probably pay for themselves.

I updated the version of the game today to build 1.66, on Steam, GoG and the humble store / direct. The latest update is 1.66, a build whose major feature is the introduction of the late-game ‘world events’ feature. That was THE feature that I was determined to get in before I could describe the game as feature complete. it may need some tweaking and balancing, but now its in, i’m calling the game ‘beta’. You can read the full list of changes in this version on the forum here.

There will still be a good few weeks of tweaking, adjusting, balancing and checking before we actually take the game out of Early Access and declare it ‘released’. And even when that is done, its very likely that I will continue to spend a decent amount of time of improving and balancing the game. I don’t have any firm plans for expansions yet, but I’ll have time to think about it, and to ask people what they might like to see.

Production Line is the first game I’ve every released in early access on steam, although I’ve done low-key betas before (Big Pharma was one). I definitely have enjoyed the EA experience, but I think it could possibly be facilitated better within the steam platform…

I used my own system to gather data from players within the game to find out what the player-base thought my dev-priorities should be. I also had to use the ‘artwork’ upload part of steam a lot to share screenshots of stuff that was a work-in-progress or ideas for improvement. TBH it felt clunky, and not fleshed out.

There is also no way to tell (without collecting your own data) how many people have played a beta build on steam, making it a bit tricky to know that the ‘unstable’ branch had got enough testing before rolling out changes to everyone else.

Anyway… Its been great fun, and a lot of effort (and time!) has gone in. I even got into the habit of doing almost-every-week video blogs to document work on the game, here is the latest one:

I’ve really enjoyed doing those too, and will probably do a few more to highlight any post-release tweaks and ideas for expansions that might crop up after the game leaves early access. After that, it would theoretically be time to think about what game I would work on next (or consider ports of PL to other platforms). The thing is, we already have Democracy 4 in production, and as that gets closer to its initial Early Access (or even pre-EA), I’ll need to devote more time to producing that.

Finally its worth mentioning that the price of Production Line will go UP before release from its current $19.95 to $24.95. I’ve pencilled that in for 12th February, so if you were considering buying the game at some point, don’t wait too long :D And yup, we get the biggest cut of the money when you buy direct:

There are no comments yet

I have been selling games a LONG time now (twenty years!). My first game to ever sell a copy was called ‘asteroid miner’ (later renamed star miner). Because in 1998 selling games online was all very ‘new’ I just used the root directory of positech.co.uk to store the shareware .zip file for my game demo, together with images not even in a folder, called ‘image1.jpg’ and other such unscalable stupidity. There was a ‘hit counter’ to show how many people had visited the website. A single screenshot, I think even a banner ad for someone else?

Anyway… the site has had a bunch of redesigns over those twenty years. it now supports https and even has a mobile version of the main page! it scales how much data it displays based on your screen resolution. (omgz). It now looks way better than it ever has, and currently looks like this:

Which is fine, and I like it, but there is a definite lack of consistency from an aesthetic POV the minute you leave the front page. Each game got a website designed ‘at the time’ with whatever cool ideas I had, or whoever I had hired to do the design. They all link back to the main page, and some of them even have ‘other games by positech’ hacked manually into the bottom of the page like this:

That approach never scales, because its just showing fixed games to people regardless how many years later it is, or the genre, or anything like that. Frankly I don’t shift many copies of Planetary Defence these days, so why even mention it. The approach is static HMTL, and its dated. Theoretically what I need is some sort of database driven website that shows my games, and cross links them properly.

Its not like I’ve never done it before, showmethegames.com was a vague attempt at that (although it never gained any real traffic). I could in theory code such a system myself, but I don’t want to spend the time (I am 100% busy developing Production Line & producing Democracy 4). The only motivation I would have for doing it myself would be that I HATE working with CSS/HTML code written by others, which is normally some over-templated bloated mess with at least 50x the code required to do the job.

So the question is…should I even be considering it? No doubt there are some great off-the-shelf products to build an online web store that would make it possible without a lot of hassle, but would I be losing the ‘feel’ of each individual games web page? Some of them have cool backgrounds, or videos surrounded by excellent artwork. Do I really want to reduce them all to the bland consistency of a steam store page style layout just for the sake of my own OCD and obsession with order?

Normally I would say no, but then i can’t help but think that steam, GoG etc all have standardised store pages, and nobody cares? Is the obsession with creating some sort of tailored ‘experience’ for visitors to your gaming website something that died out in the 1990s and we just are not accepting it yet. Its not like videos and lets plays and trailers are not a thing, do people really need a ‘shadowhand’ font on one page and the ‘democracy 3 CSS’ to give a different tone on a different game page?

I think there is an argument that the ‘big AAA studios’ who do this still are only doing it because its effectively 0.1% of their PR budget anyway, and they may as well cover all bases. In the end, isn’t a game really selling based on a screenshot, a short video, a review score, and the name?

The other way of looking at it, is what would be the upside? How many people buy big pharma direct from my website who don’t know we make production line, and would otherwise buy it right then (who would not have bought it at another point). Even if the number is 1% of total big pharma customers (and vice versa of course), is that really enough money to justify the cost and time to totally revamp the website?

I suspect, sadly it is not, and this may be relegated to a ‘wishlist’ thing. My own OCD and the fact that I think the current mishmash looks ‘amateurish’ are what is really driving me here, not any sort of business case. Its not like I’m looking for outside investors who may be put off by the aesthetics of my web page, and I really don’t care what people who are not customers think anyway.

Maybe I’ll reconsider it again sometime in 2029?

The change made by steam from a simple store front to a dynamic one based on who is logged in was a huge improvement. I was extremely pleased to see them do that. I find that for me, their algorithm actually works pretty well, and other stores are definitely not as good (yet). But lets stop congratulating things that already exist and remember three really important facts here.

Its 2018 and computers are fast as fuck

Most online web stores have a LOT of money

Most online web stores have a lot of clever coders working with them.

And now lets imagine all the factors we REALLY should be able to plug into some clever neural net that decides what games to show somebody. Starting with the trivially stupidly simple ones;

SIMPLE FACTORS

The genre of the game as defined by the developer vs the players preferred genre from playtime of other games or stated preferences

The weighted-values of all the tags associated with that game against the similar weighted values of tags that apply to the games the player has played (weighted by time and tag relevance).

The current price of the game compared to the usual purchasing p[rice at which the player either buys or wishlists / follows the game. (don’t show $59.99 games from a publisher who rarely discounts to someone who never buys a game over $5).

Really dumb stuff, like if the game is a sequel (determined by a scan of the name) to a game the player liked (or opposite if sequel to ignored), or made by the same developer.

Super-super-dumb stuff, like the platform must match the platform the player usually plays, and skew towards multiplayer if they only play multiplayer stuff, language option should include those the player usually has for the store interface.

NOW LETS GET CLEVER

We need to build up a major hidden customer profile that contains as much information about the player as possible. Stuff they enter into their profile page is a cute start, but its the absolute tip of the iceberg. Does the player have a lot of friends who are playing game X, and can we weight that by how *close* those friends are (by statistical analysis of the chart frequency and posting in similar discussions). Do those players have large average play times, or better still, have thy left multiple comments, or positive reviews. If so, factor that in when showing the game to them.

Is the player a bargain hunter? what percentage of their games were bought at each price point and each discount percentage. skew the game presented to them that match this purchasing pattern.

Do we know the players birthday? if so, send discount coupons to their close friends for games that are on their wishlist, to encourage them to buy those games for them in the week before their birthday. Skew those coupons to match the calculated likely purchase level that we can get from each friend.

NOW LETS GET EXPERIMENTAL

We only know about a game what the developer tells us, and use that as the final information on that game. Asking players to tag games is great, but surely we can go further. Internally we can know if a game is viral from the amount of instances where someone buys a game, and then a close friend of theirs buys that same game within a certain window. The virality of a game should act as a positive that results in us showing it to more people.

We can also re-evaluate all of the reviews left for a game to get a more accurate picture. If a player leaves 95% negative reviews, then they are basically just a bit grumpy, and we should skew the relevance of their reviews to the score. A player leaving overwhelmingly positive reviews, probably needs analysis to see what percentage of games they review, and if they were dissatisfied with other games but never leave negatives. If analysis of their playtime/refund rate, forum-participation and chat mentions suggests that this is not the case, and they are unusually positive, maybe skew down the relevance of their reviews too?

Reviews cores for a game being the same for everyone is a joke. Maybe everyone hated the game except for the 30 players who we estimate to be young Chinese players who tend to like funny games with certain tag combinations. If I match those reviews profiles really closely, I should see a review score FOR ME, showing how much people like ME, like the game.

Computers can analyse video pretty well now. Get an algorithm to watch 100 hours of youtube videos (or uploaded player videos) of every game, and try to draw some statistical analysis from it. Is the game clearly a fast moving, high contrast particle-fest bright explodey sort of game? Make a note. Is the game a slow paced, relaxing game with subtle color scheme? make a note. Is it clearly a brown man-shooter? etc…

Its 2018. I shouldn’t have to explain to people that production line has a similar aesthetic or feel to factorio and big pharma. an algorithm can do that for me.

Maybe some of this is impossible, or even undesirable. Its certainly a challenge. But the online store market wars are heating up. If you run a games store and do NOT have a bunch of coders attempting this sort of thing…well maybe you should look into that?