Tuesday, October 1, 2013

Dev Log: Horror Text Adventure #22

I am in the process of creating barriers between rooms: walls, closed doors, and empty passages.  I have to recode a fair bit to accommodate them, but I think it's better to do it now before movement gets any more complicated.

Basically right now any two rooms are doubly linked, and only empty passages connect.  Of course I need to add doors, especially locked ones, but I also want to be able to connect rooms by an impassable wall, so the player can't move through them, but ghosts can, and the player can hear through it.  The system I have in place doesn't allow for it.

So I'm recoding it know so rooms will connect in a particular direction to a Barrier object, so I can make checks to see what type it is, and if it's a door, if it's unlocked.  Having a variety of barriers allows for more variety of descriptions, as well.  So if there's an impassable wall separating two rooms, the player won't get any sort of room description like "there is a bedroom to the north" because the player can't see it.

I've got some of the code for that completed, mostly in the Barrier class itself.  Now comes the implementation...

No comments:

Post a Comment