Thursday, 21 September 2017

streak scoring redux

Hard at work on new game! Sorry if I'm behind on other things but making new is good. It was meant to be a really quick project, under 3 months, but it grows. Now it looks like it'll take about 6 all up, that's not too bad, I'm quite determined to not let it sprawl out past that.

This is another entry in my roguelike series (YABR), I'm feeling better now about doing that and not pressuring myself to have to do something flashy and different every time (ref). But still when I encounter similar problems I try to take enough of a different path that I will be discovering different things along the way.

It's a very short and random game (what a surprise), it's quite successful at generating an entertaining variety of situations, but the luck element makes some scenarios easier than others. I already know how to solve this: give the option of increasing the difficulty by taking more risks in exchange for some kind of reward. 868-HACK's score walls that generate N enemies for N points are a very direct version of this, here it's a bit messier but the outcome is similar: getting to the exit is usually not too hard, figuring out how much treasure you can pick up along the way without dying is hard.

One problem solved, but it creates another one: how to meaningfully compare scores between games? Maybe I got 30 points because I correctly estimated that I could safely cast Duplicar on some treasure chests and still get to the exit, and you got 5 points because you correctly estimated that it wasn't safe to pick up the treasure and instead cast Teleporte to get straight to the exit - we might have both found the best solution to the scenario we faced but the first one gets a bigger number. One option would be to calculate the value of every path the player could have chosen and normalise their score appropriately - what percentage of possible points did they purloin? This is takes a lot of computation and I feel it is unintuitive, and still it's not necessarily "fair" because the distribution of difficulty can also differ - in one scenario it might be trivial to get 90% and very hard to get the last 10%, etc. My preferred solution is to take scores across multiple games and combine them into some kind of average.

I wrote at length here about how I arrived at the "streak scoring" mechanism for 868-HACK, striking a balance between the over-cautious play demanded by streaks and the over-risky play demanded by high scores. In a way it is less "perfect" than taking a simple average - it allows you to play throw-away games where you take silly risks and have them not be counted. But in exchange it creates some space for play in tuning the balance between average score and streak length to optimise the product; in HACK there have been substantial swings in opinion over time about where this balance lies. Also to me it feels more intuitive and fun; average score feels like a very technical statistic, "keep exploring caves and accumulating loot but try not to die!" fits naturally into game world. So my thought was that maybe I could simply slot this same mechanism into a new game? Basic survival is a bit more difficult than in HACK so maybe it could work without needing difficulty escalation (which HACK had with "bonus powerups" becoming more numerous across a streak), it could be a minimal proof-of-concept to explore how it worked to just tack this system on to any game without extra supporting infrastructure.

But once it was structured as a connected series of games, the natural thing to do was to use that connection. I had given up on a spell effect that affected the next level because it was undefined on the final level but now it could simply apply to the first level of the next game. There was one treasure effect that had turned out to be much too powerful, now I could balance it by making it require accumulating several before you can use it - possibly across multiple games. This became a resource you could save up to use in an emergency to save your streak, it made some bad luck feel more fair. This was a neat possibility for streaks that I hadn't really explored with HACK (there is just .SAVE in the PLAN.B expansion). But even with these small connections I realised it didn't feel right; even though each individual game could be very different to the last, each streak was a similar soup blended from the same random ingredients. Something changes in the first level of the next game but then you move on, you save something up but then you spend it all and you're back where you started, there's no sense of getting anywhere. It'd be better if each streak could somehow have its own distinctive flavour at a macro level, some sense of permanence or progress to your actions.

Thought about somehow leveling up the hero character. The resource that you accumulate across multiple games: instead of being spent for a one-off effect, maybe it's spent towards permanent upgrades. But it's not so interesting if you just get stronger and then the game is easier and it just snowballs - hence HACK's "bonus powerups" powering up the enemies and obstacles rather than the player, so in the end I've found myself going down much more of a similar path than I'd hoped to. I can still veer off in a different direction! The enemy powerups stay for the whole streak instead of changing each game (thanks Droqen for helpful discussion); one streak the lizards will level up and now all the time you're fighting LIZARD WIZARDS, another streak it might be QUICKENED CHICKENS instead, and then you'd make different choices in how you level up your character to deal with them.

So now I have two separate progression systems that span multiple plays of the game and I'm wondering how my simple quick project managed to increase in scope.