It's *not* the weekend

Ovid on 2005-11-03T18:37:54

Which is why I've done so little on Games::World. Connecting locations now works. Part of what was needed was to ensure that everything has a unique integer id. You can supply them yourself (handy if you've created a map and have written down room numbers) or let the software do it. So far everything works great. My tests die from time to time but in Happy Ways. Basically, I've been so anal-retentive about "die early/die often" that it's virtually impossible to create anything without everything being in place for it to work. Thus, the following blew up on me:

Room->new( {
  adjectives => 'small',
  size       => 100,
} );

It failed with:

You must first add the adjective 'small' to the vocabulary

That makes me ridiculously happy. No worries about typing "samll" or anything like that. That this pleases me so much merely shows what a geek I am.

The only annoyance I really have is that there is no real way to prove that no rooms are "hanging" (or sets of rooms) without calling a $world->finalize method at some point. I can't just specify the connections when I create the rooms because of the chicken and egg problem. Damn. I'll probably want to add a GraphViz program that diagrams rooms. That will help.

I've tried to clean up some API inconsistencies but that's not done yet. What I haven't done is start on the Games::World::Thing::Player yet. It's not the weekend so I don't have time. That, however, is my last major step (I think) before I can put a rudimentary natural language interface on it. I'm chomping at the bit to implement the grammar and see how it actually integrates with the object system.