We are making a Horrendous Mess™, and we’re glad of it. In the grand scheme of things, we are engaged in shifting responsibility from the Cell class to DungeonLayout, or, if appropriate, to other classes known to the Layout. At the end of that process, we envision a much simpler Cell, perhaps little more than a coordinate or address. It is possible that at that point, we’ll feel that there is too much responsibility in the Layout. Even if that’s true, it’ll be better than having those responsibilities in Cell, because with those things in Cell, an individual Cell knows too much. In particular, it knows its containers, and that always feels icky, and often leads to trouble when things have more than one container. A Cell can be in a Layout, a Room, and a Suite, all at the same time. It’s a miracle that we don’t already have trouble. The question facing me this morning is what to do next. I’m guessing it’s going to be related to the neighbor concept, but what we’ll do is look at Cell…
No comments yet. Log in to reply on the Fediverse. Comments will appear here.