10 December 2017

LoSt this week (yearning for Arken)

An easy bug fix, which I still
struggled to get just right. 
I'm still working on Arken Town (the settlement where the game is set to start), and making lots of small engine tweaks along the way. I've been refactoring the world generation routines for a while, and even if the changes don't make a huge visible difference, I spend quite some time just thinking the designs through. Organizing the data associated with the settlement, for instance, had me setting up some infrastructure to handle other important places on the map.

I've also changed to the climate map generator, so I can access more detailed info pertaining to regions and landscapes later. It's mostly stuff I need to generate bounties and story lines (ie. at the sheriff's/post office in Arken hangs a wanted poster, and the game must generate details regarding the fugitive's whereabouts).

The map generator just needs a few finishing touches before I can leave it for now, I think. So I'm zooming in again on the minutia of Arken to get this baby up in the air.

The gunsmith

Since I don't have a lot of time to muck about with LoSt these days, I'm trying to divide development into small chunks that can be handled in short, sporadic sessions. (In that light, it may be detrimental to the project that I take a few hours to write a blog post like this, but I hope it's part of the fun to some people at least who might drop by here from time to time :)

Now that I'm starting on Arken in earnest, I've decided to do it house by house. Each of the planned "places of interest" that can be generated, will demand that I fine tune the engine a bit. First out is the gunsmith, a pretty inconspicuous kid that offers some services. In addition to selling guns (and possibly special ammo), the smith can repair or enhance guns you already own (by adding a prefix, basically imbuing the gun with a special shtick).

Bittner lever action repeater, by a German gunsmith
Regarding engine tweaks needed to get this in the game, it's mostly AI-related. I have been working up to this, and already implemented the basic interface for giving items to NPCs. Now, I just need to make the gunsmith react appropriately if someone offers them a gun. It could be done by adding some states to the content database, but looking at practical solutions, it strikes me that the current AI module is very shaky. It may be a good time to go in and do some basic changes, since I'll only be facing increasingly complex NPC behavior as development continues. It's honestly something I've been mulling about in my brain for a while, so I have some ideas…

Adding the gunsmith will entail another addition to the engine, again quite moderate, but with possibly wide reaching consequences. When you offer the gunsmith a gun, I decided I'll have to pop up a window with a prompt to the player, like: <"I can fix this for 30♄." (Y/N)?> I already have <more>-prompts, so making it happen won't be a big deal (just get the confirmation, pay the bill and upgrade the gun). But it's something I might need later for popups connected to other game changing events. For instance, when resting at a saloon, the player may just see: <You rest for a week. Press Space to continue.> But the game should do a lot of things, like healing the player's longterm wounds, passing game time, and (if appropriate) grant the player new reputations and shticks, just to mention a few things. So, even this silly little popup becomes an issue to ponder on the metro after I've delivered the kids to school (whether I should compare that to a calligrapher meditating for hours before executing a simple stroke, or just admit analysis paralysis). In any case, it would be meaningless to hack my way through this to the benefit of the gunsmith, just to have to redo the whole thing when I come to the saloon a few houses down the road.

As always,

(1 hex ≈ 1 screen) A last change I must do before #12, is to make
the world larger with "bulkier" regions. The Land isn't supposed
to be huge, but the current scaling makes it feel too small.