15 August 2018

LoSt this month: State of the art

Early GUI mockup
Surprising as it may seem, the first release of LoSt was a bit more than five years ago. I've come a short way since then. However, if LoSt is currently lacking even something as basic as a win condition, it has seen some more "rounded" releases in the past. Regarding the win condition, that's something I actually had in #4-7, when LoSt was a light crawl with the necessary features to constitute a bare bones, but complete, little game (it took place in a mostly unicursal labyrinth, as you played a mine slave ascending from the depths of the shaft).

Current state of the art
With release #8, the game was reset to alpha stage, but by widening the scope somewhat. This is where the overworld, with its randomly generated flora and fauna, was introduced, and I also started on simple animations. Speaking of the graphics engine, suffice to say it's an incomplete mess at the moment, but not top priority with the next few releases. There should come a refactoring at some point ;)

Regarding this month in LoSt, I've had the project on the backburner, tying up some loose ends for the upcoming release #12; from a change in how the message log is displayed (the last on my list of player requests in response to #11), to strengthening the "main bounty" a bit and fixing some minor AI bugs. The last big thing that remains, is still to somehow balance the acquisition of new shticks. I'm thinking I'll just count "experience points" very crudely (more from seeing new areas of the game world, than defeating enemies), and then "bumping the player up a level" at  intervals. The more I've been thinking about it, the less inclined I am to settle with something too much like good ol'e XP. But for that precise reason, I'm more eager to just get anything in place right now, so that I can put out #12 (heavy on engine-related changes, but not extremely meaty content-wise) and get on with it.

If I have any general long-term vision at the moment, it would probably be to make #13 rather quickly, adding some more content/encounters, whilst fixing issues that become apparent in #12. My personal view is currently that the game isn't very fun to play, mostly because there's not much to do in the game world. If I make some interesting bounties and places for #13, I should have a solid base to build from. After that, there are still some features I'm looking forward to adding to the engine, including riding and rope use (which will probably also be used for taking prisoners in non-lethal combat). Some other stuff will come in organic relation to the content I manage to add. For instance, if/when there are ranches, there should come systems for things like herd handling and branding; and if/when we get lumbering and floating logs down the stream to the mill, that would go hand in hand with more fleshed-out systems for water movement, as well as platform riding (carriages/boats/floating logs). A log drive down the river, getting attacked by hostile humans and animals along the way, could be fun (or leading a cattle/post ride through the outlands, which could be modeled along a similar arc). We'll see about all of that, of course. Here and now, I'm crossing my fingers that the next update on this blog will concern the release of #12.

11 July 2018

LoSt this month: Petrichor

Fame is the worst thing that could happen to your reputation.
   – Kate Tempest, «These things I know»
LoSt's loyal fanbase never lost faith.
When May turned to June, I decided to push my so-called monthly update ahead of me, just a few days, to make some progress that I could report (May had been another slow month). Well, here we are squarely in the middle of July already!

Since last, I did sink some hours into character advancement (≈leveling up). It's hard to fit it into the game at this moment, since it would rely on some more content to get the right scope. At the moment, I scrapped the original idea (described in an earlier post) of letting the player influence skill advancement by presenting them with story options (à la «choose your own adventure» books, reminiscent to how they did it in Shattered Planet). A system like this may come at a later date ;) What I did keep, was the idea of tying up character advancement with a resting mechanism, that also encompasses healing long-term wounds and amassing reputation. I got in place a very rough system, that just looks at the player's recent conduct tracker and decides how/if to modify character traits. The current design will need a lot of refinement, but the bare bones may still be deemed enough to cut it for release #12.

Goals and Achievements

A long term plan I've been having for LoSt, is to have a rather involved system for renown and faction relations. I have now added a reputation stat, which is a step in the right direction. The new mechanism builds on an existing framework of «causes», data plugins dictating critter behavior, which I've also been using to simulate a faction system, by giving each cause a list of other causes and flags that they have a particular bias towards. Favor between critters is a simple positive or negative integer that's set randomly each time a critter sees another critter for the first time, and the cause-related modifiers work by simply adjusting the (min,max) range. Thus, predatory animals attack prey more or less on sight, because the «predator mentality» cause has a (-2,-2) favor modifier to any critter tagged as «prey». Likewise, shticks like «Animal friend» and «Musky» work by flagging the player so that animals get an extra modifier of (0,+1) or (-1,0), respectively.

The main addition to this in #12 is that individual critters can now have a dynamic reputation stat. It works by listing a set of causes and assigning each cause a modifier. Reputation is modified between missions, whenever the player rests at the saloon (or other resting hubs that will appear). The game tracks and stores the player's conduct as «karma», so I have info about who @ has interacted with and how, which tools/shticks have been used, success/failure at missions, places visited, etc. Reputation is currently modified by looking up the causes of critters @ has pleased or annoyed, and making a few random checks to see if @'s reputation should be modified with one or more causes. It can be fleshed out later, especially as I'll want to flesh out a more detailed system for factions, which could be much more than just glorified AI plugins, as is currently the case.

Related, a sketchy system has cropped up for something I call «boons», tangible achievements and missions the player can fulfill. Currently, the main mission is to bring down a wanted bandit, and I'm testing with some minor boons, including collecting the bounty on any random mudfaced goon, visiting a new place, or drinking milk (perhaps the first in a series of boons related to abstinence, for careers like ascetics and abolitionists). At the moment, boons cheesily yield a kind of experience points, which at certain intervals trigger a «levelup» function that improves the player's stats upon resting. It's at least fun to test, since we now get characters that scale up and gain new shticks (skills) as time passes.

Defining boons as the source of coveted experience points may be hard to balance, in that it could easily encourage grinding to collect'em all. I might offset this by tying shtick acquisition more directly to what you do on the map: as instantaneous rewards for collecting particular boons, through books or paid tutoring, etc. Another system I've been thinking about, is to introduce a stat like decrepitude. (The term is ripped from Ars Magica, where wizards become slowly more old and gnarly and in danger of drifting away from the world). In LoSt, decrepitude, or whatchammacallit, would work to impose a soft time limit by amassing over time as new foibles and negative stats (trauma, wounds, addictions, bad reputations, etc). I think a system like that might work well, especially in conjuncture with some other long term ideas about the option to retire your character, and other ways characters' legacies can have an effect across several playthroughs.

Be that as it may, I'm trying to restrain the todo-list for the upcoming release #12. It's better to put out some crude implementations, and hopefully getting player feedback that can inform further development. It's really high time for the new version to come out, and it's going to be a meaty one, even though it may end up as a short interim before #13, if I can quickly turn around and fine tune some of the bugs that will undoubtedly become apparent upon release. There are some minor things I will definitely (hope to) fix before #12 is ready, but nothing too big, mostly just tying up loose ends.

Ugly bugly.
☞ Fix flickering text bubbles when the map scrolls. In fact, there are a bunch of graphical glitches that I'm loathe to fix one by one, simply because the whole display engine needs an overhaul; small patches now would be a waste of time in the long run, but this exact bug is so disturbing that it's probably right to label it release critical.

☞ Brush up AI: This is another topic I don't want to do too much with at the moment, but changing the combat system around did leave a few bugs. In particular, I need to fix some causes/beings that won't enter their attacking states properly.

☞ Make boon system release ready: To get some more to test with, I might define a few more minor boons. And although I am happy to leave the character advancement system as a prototype, some fine-tuning would still be in order there. I may also have to look into the UI department, for instance whether the player should receive a notification when they collect a boon. It's tempting to start adding more places and missions, of course, but I'll try to save that for later versions. Regarding the prototype boss fight/starting quest, I have it working from a technical perspective, but the actual fight/encounter is a bit uninspired, so maybe I should fire up my content editor to give that particular challenge a bit more zazz.

2 May 2018

… breeding lilacs out of the dead land

There will be another short update this month. After March, April was really the kind of month where the project went from running on the backburner to more or less coming to a pause. There have been more urgent matters to see to in my life (mostly good things), so it felt natural for LoSt to come into the background for a bit. I'm not too worried about taking a short break, it's how LoSt have always been developed, and I've found one can often benefit from leaving a project for a short while, and returning with new energy and perspectives later. Technically, LoSt is very close to a new release, so I do hope to get in the saddle again shortly to make the last few adjustments. Then again, there's no gain in rushing a release, and I would ideally also like to add a least a bit of content to go with the new engine features. Precisely when it comes to finalizing changes and coming up with new content, taking a step back to gain an overview is the kind of technique I like to employ.

Oh, and in case anyone wondered, the title of this post is only to provide context for the half-assed pun in last month's title. I'll make another update by the beginning of next month, at the latest. Let's see what I have for you then.

As always,

2 April 2018

March is the coolest month

(At least it's been pretty friggin' cold up here.) March has also been a rather slow month for LoSt. I'm chugging away at the short term todo list, and have been sinking some hours into a system for passing time and learning from your experience. I'm not too concerned about balancing character development or making any final decisions at the moment, just getting a prototype for the kind of system I have been envisioning.

The system merges current skills and perks into one pool of special abilities (shticks), mostly for simplicity's sake. I have to make some small changes to character creation to reflect this. Once that's in place, I should have all features that are necessary for the planned #12 release. I anticipate April to bring bug squashing as well as authoring content, to make use of the various additions since the last release.

3 March 2018

Making time

Last month, I wrote about reimplementing wounds, and some of the changes that prompted. This month, I've mainly been working on time systems.

Sometimes, incremental changes to a project come in a surprising order, at least to an inexperienced developer like me. For instance: LoSt is designed with a simple interface in mind, and has no separate commands to use objects in different ways, like so many genre classics, with their mappings for "q"uaffing and "z"apping and whatnot (and to be fair – these interfaces are difficult to learn, but quite snappy once you do). LoSt's interface, instead, requires you to always wield an item before you can use it. Problems arose with props like cigars and syringes (consumables, really like those "q"uaffables and "z"appables of yore). The fact that they couldn't be used directly from the backpack meant it took too long to use them to be worth it in most situations.

I try to circumvent the problem by making inventory handling not taking any time. This change ups the tempo and gives the player more options, so I'm generally happy about it. It does change the value of some skills and props, like pistolknives (whose main selling point was that they could be used for melee or ranged combat). One scummy tactic that became apparent with the new system, was to keep a stack of loaded guns in your pack and fire them in succession, to save the time of cocking between each shot. So be it. To penalize the behavior, I instead added the rule that moving a cocked gun around in your inventory has a small chance of the gun going off. I don't know how realistic this is in terms of gun engineering (as a European pacifist, my personal relation to guns is limited ;) Should it be grossly inaccurate, I guess my last defense would be that LoSt plays out in a fantasy world, where many small things are different, so there, and in any case, nothing is funnier than shooting yourself in the foot, and I do think the system retains the sense of the basic motif: the rhythm of drawing, cocking, and firing a gun.

On the topic of short time spans: One thing that has baffled some players of LoSt, is the turn order. One reason is undoubtedly that a bug caused the system to behave weirdly, which I've finally gotten around to fix. But the system itself is a bit unusual for a crpg, and not really well documented. I'm taking steps to fix this, to make it easier to understand what's going on. If I can solicit some feedback for the next release, I'll hopefully manage to finalize the rules for combat some time soon-ish ;)

Rest for the wicked

One important feature that's missing in #11, is healing. This month, I've been implementing the bare bones, by adding the option to rest for a prolonged time and going back to full health, so it's now officially in. At the time of writing, the local saloon is the only resting hub, but other options will come later. Before that, I'm facing a chunk of work just to get the basic mechanics in place.

In addition to healing, the passage of time is planned to include systems for advancing the player character, as well as story lines/world events. The basic idea is to make resting a big deal, something that affects strategy. You currently pay for healing by paying rent for your room, but I'd like to further underline the importance of time by letting (potentially) "something happen" when the player rests. The nature of the changes imposed on the game world should reflect the player's recent behavior. Character development will include modifying reputation and the opportunity to gain new shticks. Furthering the "world story" will, I think, pertain mostly to world factions and bounties/quests (this last bit not planned for #12, so I honestly try to disregard it for the time being).

Modifying reputation: The engine already has a pretty detailed conduct tracker. For instance, if you massacred everyone at the saloon, you will have a lot of hostile karma in relation to the villagers. I think I might just try to take this data and generate reputation procedurally. If I manage to do it right, it should be more flexible and unpredictable than simply stating, "doing X modifies your standing with faction Y by N points". Although there should be systems for such corner cases, as well. The "proto-bounty" I'm working on now, which involves capturing a specific, named criminal, is a good example and a testing ground for this. Resolving the conflict by collecting the bounty on said criminal's head in Arken, flags the player with a special achievement, which amongst other things should be weighed extra when reputation is calculated between missions. In short, I must start out with a simple and open ended system, that I can expand on later.

Getting shticks: My current vision of how this should be implemented, involves quite a bit of foot work, and I'm still not sure if it's going to be any good. I hope to get in a kind of prototype for the next release. What I'm envisioning is basically for the engine to pick three options for the player and let them choose one. But I had an idea to make the interface less gamey by presenting the options as flavor text. Instead of: "You rest at the saloon for two weeks. 1) Get pistol shtick, 2) Get science shtick, 3) Increase local reputation", it could say something like: "You spend two weeks recovering from your wounds at the saloon in Arken Town. You eat a lot of soup, but at the end of the stay, you start to get back on your feet. 1) Go target practicing in the wilds, 2) Read a book, 3) Hang out with the locals" The place you're resting, and special NPCs stationed as the player's neighbors, should affect the available options, as well as the pseudo-randomized outcome of choosing each option. The end-result as I'm envisioning it, would be a bit like choose-your-own-adventure books, where the outcome is not given. So you won't get to cherry pick the shtick you want, but are allowed to nudge the system. If you opt to practice gunmanship, you might get a random pistoleering shtick, or a reputation bonus related to guns, or if you've used a particular pistol a lot on your latest mission, that particular gun may turn into an "artifact" with a random prefix. Likewise, "spending time with the locals" could have many outcomes, from a simple reputation boost, to learning certain rumors/plot hooks for new quests, or maybe your plan backfires and the villagers end up lynching you (especially if their bias towards you is negative in the first place, of course). It's a system that certainly has its hurdles and slopes, but I believe it has potential.

Story advancement: As noted, this lies even further in future, since I'd rather release #12 in not too long to get a better idea of how the current changes work out on their own. Suffice to say, everything will be tangled together with world factions, their relations and current objectives. Some questlines and bounties may have time limits and random outcomes, depending on player agency. Using my protobounty with the wanted-poster in Arken Town as an example, there might be a window of opportunity to get the bandit. The actual plot could be tested by querying the game world for the bandit's status. Maybe, at the end of each week, there is a chance of the bandit making a move. World events could be almost as Markov chains, with possible continuations depending on the actor's state. For a fugitive criminal, follow-ups could include a raid on a certain place, or fleeing the game world, or switching base to a small fortress somewhere on the map. From the new situation, the options would change again – if the bandit settles in a fortress, it probably means they're not "fugitive" any longer (although they are still wanted by the law), so the option to flee the Land might go away. It will probably have to be more involved than Markov chains, maybe more like a behavior tree. The different states should be abstract enough to be applicable to differently flavored scenarios. For instance, there are many kinds of shootouts and raid scenarios, which share a lot of similarities, especially on a tactical level. You basically drop a bunch of units in a hostile place and give them a certain objective (free the prisoner, find the macguffin, kill the enemy), and if then the player comes walking along, the units will become active and havoc ensue. I think it would be possible with a system where each faction and NPC of interest can have pretty simple flags regarding their narrative status and relations to other factions. The "fugitive/persecutor" conflict is archetypical, and will have a similar narrative dynamic if the story is about a political figure in exile/hiding, or someone fleeing the wrath of a mafia boss. As I'm working now on the ramifications of capturing the bandit in the protobounty, it should be possible to leverage the same rules to make it possible for the player to do stuff like joining the bandit's side by offering them the head of someone they are out to get. How you build reputation will inform who are more likely to chat to you about their lore and objectives and even actively hire you, and who are likely to attack you on sight. And yet, reputation needn't be an end in itself, in any technical term. There could be objectives generated on the map that are better performed incognito or require other maneuvers, like finding a hidden treasure.

Oh, the dreams one has. If only I could make time.

As always,

2 February 2018

LoSt this month

“How’s it look to you?” Bill said. He was handling the reins, sitting tall and handsome, nodding at voices when somebody called to him from the street. The word of who it was in the wagon got through town before Charley and Bill made a hundred yards. 
“Like something out of the Bible,” Charley said.
“What part of the Bible?” Bill said, when they were alone again. 
“Where God got angry,” Charley said.
   —Pete Dexter, Deadwood
Full speed ahead!

Last year saw some sporadic updates under the header of "LoSt this week". They weren't exactly the most ambitious posts on this blog, but still a way to document progress, at least. I figured I'd try a model of more reliable monthly updates this year. We'll see how reliable I manage to keep'em.

Back to the Meat

January saw some slow, steady development. Most notably, perhaps, I've reimplemented wounds in accordance with some old plans. I'm now testing with a flat counter à la hit points, although I call it "grit" rather than hp. The player will probably start with about 9-12 grit (a bit more than your average neighbor, owing to the natural determination and character that sets a wannabe frontier hero apart). Grit is marked out when an actor gets wounded. Currently, there are markers for bruises and grievous wounds. Wounds are semi-permanent, and typically only heal between missions, whilst Bruises regenerate every turn that is passed without taking any action or receiving any damage.

That's the gist of it, but I'm still ironing out the details and making related changes. The idea is to make bruises "inexpensive" (in that there is no food clock), so the player can freely gambit their grit in any local situation – if they feel confident on winning the fight. Wounds, on the other hand, will force the player to touch base every now and then, and some bounties and other story related content will certainly have time limits and thresholds; the world should not stand still if the player spends two weeks at the saloon to recover from a bear attack.

Expanding on the current implementation, I'll test using grit for status ailments and buffs in addition to wounds. For instance, being temporarily blinded or confused might occupy a grit marker. Likewise, positive modifiers from skills/props could tap your grit when active. I think this can work well as "payment" for certain skills, having decided early on that I don't want skills with cooldown periods, as that may encourage techniques like pillar dancing. Instead, each effect should be designed with built-in weaknesses. For example, the "fan gun" skill allows you to cock and fire in one turn, but at the cost of reduced accuracy. Another available effect is sprinting (move at double speed for some turns), and I hadn't been able to come up with a good penalty for that. Now I'm thinking grit may offer a solution. Let's say you accumulate "out of breath" markers the longer you sprint, meaning that you must spend turns to recover, or else come into the next encounter at a disadvantage. That should cap the amount of running around it's feasible to do, without nerfing it too much as a defensive strategy. I don't mind if running away is an effective "panic button" for many situations. Knowing RL players, each and one will die by the dozen, anyway; and it bears mentioning that I'm hoping to add non-lethal combat: in particular the option to surrender – so why not an option to run away? The villain should really just stand back and shout insults then, all the while depleting the player's reputation as a valiant hero.

UI Overhauls

Testing #12: «Wanted» poster in Arken Town
Note random truism in the bandit's generated name :)   
Changing the combat system has many ripples. For one thing, the tactical menu had to be rearranged. Working with visual interface design is something I find at once painful and strangely compelling (a bit like masturbating with a branding iron). There's a lot of relative coordinates to keep track of, especially if you take into account varying resolutions and font sizes, and more often than not I'll stumble over cryptic pieces of algebra in the existing code, that my previous self sucessfully used to put things where they belong on the screen, but which my present self is utterly unable to understand.

The new UI puts some info in a top panel. I've kept the right hand menu for inventory, actions and message log, but I was thinking it might be nice to add a "wide screen" mode as well. You'll notice the new interface has flashy menu buttons. I added these since LoSt now has basic mouse support. Yay. The icons in this screenshot are place holder art, by the way. They are more or less hand made, but some are direct ripoffs of Mayan glyphs that actually mean something completely different. So I may or may not keep the visual style, but I'll want the designs used to be original, in any case.

Fonts: Before…
While I was at it, I did some font work. Earlier versions used (and embedded) a few fonts with restrictive "freeware" licenses. I've been wanting to clean up that whole mess: reduce the amount of embedded fonts and make sure everything is open software. So I went font hunting, and found 1001 Fonts quite usable, especially as the site has the option to filter for only open source fonts. I also used Fontforge for the first time, making a very basic Frankenstein font by merging some glyphs into Linux Biolinum. I pulled the glyphs from various free sources, but was especially thrilled to discover Quivira, a font with pretty good Unicode support. In fact, that's where I got the glyph ♄ for lead, arguably the most important letter in the LoSt alphabet.

Fonts: After!
I also redid the logo, using Gimp to draw the letters with filled rectangles, that I then ran over with a bunch of filters. The new menu font IM Fell was just added for being pretty great and having probably the second most fantastic license I ever read (donated to the Oxford University by its creator upon his death in 1686). It may be too old fashioned for LoSt in the long run, but here and now it's quite functional.

Questin' fer Bounties

Since I need to test out the new wounds system, as well as the basic content for defeating the bandit scourge of Arken Town, I had to zoom back in on tactical aspects of the game, which has been refreshing after mostly doing macro-level world building stuff for the last period. I had completely "turned off" encounters (houses, animals, and even plants), but now switched them back on to get a trajectory back and forth to the bandit to slay him/her and bring back the head to the sheriff in Arken. If I do that (currently not trivial, but there's always the cheat options in the main menu :) it raises a little "karma flag" that I plan to use later, to influence reputation and skill advancement, whenever the player passes time between missions at one of the game world's resting hubs (eg. saloons, oases, hospices, cloisters).

I want you kids to get ahead
The infrastructure for implementing this basic kill/fetch quest, where the parameters are ultimately written in the human readable data files, can be used to track smaller achievements as well. There will probably be other "little karma flags" for conduct like giving to beggars, (not) shooting someone in the back, flaunting your pistol in church, and just generally pleasing/offending members of this or that faction/group in one way or the other. In the long run, I hope that the life time of more accomplished characters will span several years of game time, with slowly developing reputation, skill set, as well as global faction relations and story lines. If the game should come to that point, the "original bounty" I'm working on now will probably just be folded into a repertoire of random situations, that can be repeated, omitted and randomized over many replays.

So I'm walking a bit in the desert, getting killed some on the way, trying to imagine what the game will be like a few iterations down the road…

As always,

Gif of the month looks decent, but there's a lot of
graphical glitches too, as when simultaneously
scrolling the map and fading out dialogue bubbles!