Sunday 31 October 2021

Forest update

Previously I had a class called "Area" to create almost anything from regular caverns to forests, but it was simply too generic, because the generation was tied to a cavern. I created a new class Forest that is only creating forests. It has a new type of generation logic based on flood fill which I think works better than just placing trees in a roughly circular area.

It's quite important to avoid generic routines, because they will become too complicated and for some features may not even work in the end. However the parts should be mostly reusable, like in this context the flood fill routine itself will be reused in other routines that require filling an area.

Since cavern routine was also using the flood fill which was kind of weirdly modified flood fill it no longer works. This is why you should plan "low level" routines so that they wont break, but offer a true generic way to do something right from the beginning. The division to specific and generic is the main problem in roguelike projects I think, and probably in most projects ever.

I think a modified flood fill should be ok for a cavern routine, because that's what you want. You want to fill an area but not make it a perfect linear fill, but deviate it to generate irregular shape which still detects the proximity of other features like rooms etc. The proximity value will be a great way to create something like lakes inside a cavern.

Sunday 9 May 2021

Feature review

They often say you shouldn't have too many features in a roguelike, because they are hard to implement. It is very true, but large scale roguelikes require features and complexity that they give. I went through the source code and listed most major features that are distinctive. There are 64 features and I don't know how it even compares to other roguelikes. The startling or depressing thing is that most of the features are more or less concepts with often minimum amount of implementation. This isn't a surprise, because my inability to decide how features work in detail has been a monumental theme in this project.

I feel like this is a major problem in many roguelike projects. The design is too simple if you just decide to have some feature like fountains. It doesn't stop there, you need to decide how exactly fountains work and what sub-features they have. Do they dry when you drink from them? Do they spawn monsters? Are there hidden items in them? What happens if you kick a fountain? Is the water always healthy? Etc.

The sub-features are often linked to the engine thinking, where features either require lots of special code or they should be supported by the engine which then requires more from the engine. Everything adds to the total amount of code which can already feel overwhelming just with the core of the game.

I think the list of features is going to be my next goal where getting at least the basics working would help get the project to the next level.

Saturday 13 March 2021

Dungeon update

Or is it an update from a dungeon. The terrain rewrite was not that difficult after all, but the terrain object spawning doesn't work yet. However the engine is good enough to not care about that. I think the rewrite was worth it, because everything seems to work better just like that.

While the RPG system is still causing problems I've decided to at least finish the dungeon generation. The main problem is the unorganized complexity which I'm cleaning up. Then after that it's simply the design: what stuff to put in what level themes. You would think that roguelikes as "randomly" generated games don't need level design, but nothing could be less true than that. In a way there is more work and more design thought put into a level than in static level design.

My current day job is only three days a week so it's giving me extra two days to work on my projects. And the way I was kicked out from now-SJWarriorized roguelike "scene" has given me more motivation to show what real roguelikes are when you know exactly what you are doing. This SJW/woke thing is also happening in commercial game development scene which is causing really funny things to happen like companies hiring so crappy developers they can't even create anything. Companies end up losing tons of money and I'm just watching it and eating popcorns.