Weekly Update – March 21, 2025

This week’s focus was on map generation refinement.

  • Refactored, fixed, improved map graph pattern matching. I spent the most time on this, and most of the time I spent on it was finding and fixing what my modifications broke. The purpose of the modifications was to fix an issue in the pattern matching logic used to populate the map with content. I wanted the pattern matcher to be able to use the required nodes within a subsection of the map and place designated content in those nodes. This is useful for populating a group of related rooms such as a bandit outpost. The required nodes represent the rooms/corridors that the player must pass to exit the subsection. The pattern matching logic was able to recognize the nodes but wasn’t using this information when placing content. In addition to making the modifications, I refactored the classes I was working in. This was out of necessity; the code was difficult to grasp.
  • Starting and ending room types. Sometimes, the start of a level is impossible to survive because it contains too many enemies to fight off or run away from. To prevent this, the map generator can now be configured to allow only certain room types for the starting and ending rooms. This capability also allows more challenging or unique scenarios for the ending room.
  • Testing individual Map Element types. Map Elements are objects that populate individual rooms and groups of rooms. It’s currently possible to exclude individual Map Elements during map generation, but if I want to test a specific Map Element, I have to exclude every Map Element except for the one being tested. I added a new list in the test configuration to only test specific Map Elements. This has been very useful.
  • Enemies can break out of webs. Previously, enemies would walk in the webs and get permanently stuck. Now enemies can use the Break Out action, which was already available to the player, to break free from webs. This required allowing enemies to perform the action, making enemy AI aware of being stuck, and adjusting the AI decision making to choose breaking free over other actions. Most of the work was configuration. The decision logic is coded.
  • The Break Out action sometimes fails. There’s now a 10% chance that the Break Out action will fail, causing an actor stuck in webs to remain stuck for the turn.
  • New room types: flooded cistern with snakes, bone-choked corridor.
  • New items. I added a Wand of Webs just to test shooting webs, but I’m going to keep it in the game because it’s fun to use.
  • Map generator bug fixes. These bugs have existed for a long time but were only discovered this week. The new capability to test individual Map Element types exposed them.
  • Bug fixes
    • Enemies can still perform attacks of opportunity when they’re unable to move.
    • Wands stopped working.

Next week will be a variety week – more map generation refinement, more new room types, GUI refinement, and further distinguishing the first three levels of the dungeon.


Posted

in

by