December 2006 Archives

What Really Was Wrong

| No Comments | No TrackBacks

Last week, I noticed what really was wrong with Hidden Horrors of Megyntia.

I knew something was wrong. People just didn't tell me that was wrong. then someone pointed at it and - oh gosh - that was so obvious.

My problem with fiction, now that I really see it, is that I have statements.

"Goblins," Gnedrnygr growled. "And not at all friendly ones either", he said as the green-skinned things swarmed to sight. There were about twenty of them.

And this is how I'd rewrite this crap today:

"Well, heck", Gnedrnygr said. "This is what we get for keeping one step ahead of the Luck Goddess." The wizard raised his staff, and readied for battle.

In the flickering torch light, they saw goblins rush out of the dark doorways to the sides. Facyr drew his sword, and looked around warily; about twenty of the foul-smelling, annoyingly screeching creatures confronted them. As the creatures closed on them, Facyr grimaced when the reeking creatures came forth and wondered, once again, that old question of his - what actually drove these creatures defend their homes so fiercely...

Okay, perhaps not exactly like that, but the points are clear:

  1. Putting adjectives and descriptors to the text as a list isn't good. Plain facts are boring. The facts need to justify their existence.
  2. Getting a little bit inside of the heads of the characters is good. Not too much, but describing things a little bit better than
  3. I heard the Good Idea that "Xxxx growled" is bad. "Xxxx said" is okay.
  4. sigh Gnedrnygr is stating the obvious, and that's not a characteristic I'd reserve for his character (even when he could conceivably do that).

The first point is the major lesson I learned, and so is the second.

Statements of facts are something I do well on boring nonfiction text. However, I realised that doesn't work at all on fiction. Stating facts is boring. Stating facts in a way that makes sense in that exact part of the story is much better.

Getting in the character's head is a bit fun too, because it's easier to convey that way how the character really is like.

Um, I have a bit of a headache. Time to write more of this stuff later!

Run Forrest Run... no, not against the wall

| No Comments | No TrackBacks

Migrating my extremely hacky Smarty-based Avarthrel website to clean, nicely working Forrest site is... progressing... weirdly.

I kind of regret the choice already. However, I'm not backing down, because Forrest appears to have a sane approach: Use whatever XML formats you want and transform them to fully skinned site. Besides, I've determined that the root cause of me not being able to write anything is that something bugs me, and in this case it's the old super-hacky Smarty site. Argh.

I only have major problems on the front end. Specifically, the skins aren't very customisable, and I can't really generate HTML from my custom XML sources - I need to generate this very limited subset of HTML. I can't say "When generating the story web pages, they need to have custom Creative Commons metadata, include comments with SSI, and add a comment form at the bottom. All of them need custom parameters."

So what did I do?

Hpricots from hell!

I call my "fix up the broken Forrest HTML" script "ccinjector", because it's main job is to inject Creative Commons metadata. I almost called it cardiacarrest.rb, as in "what you get if you eat a metric heckton of chocolate", to keep up with the Forrest Gump theme.

And what does the injector do? It requires both hpricot and xml/libxml libraries. Two libraries that basically deal with XML data. Yay. And, of course, it grabs yaml. Nope, this app doesn't store its configuration in an XML file. (I'm a pacifist and "XML is like violence: if it doesn't work, use more" doesn't seem too thrilling.)

Conclusion: Storing stuff in text files is surprisingly difficult.

Now, this file then uses libxml to fix up my Creative Commons metadata. It gets inserted in the HTML. then, the script ponders what sort of fixes I've specified in the configuration. It can insert static HTML templates, with or without variable/magic-word substitution, or mess up HTML along the lines of "replace //div[@class=lastmodified] with the contents of lastmod template". hpricot is really nice for this sort of stuff.

And it runs HTML Tidy. Twice. At the beginning and end.

All in all, this stuff is really painless - but still overly complicated considering what I really need here...