Minimum Safe Distance

I'm Riff. I'm a writer for a popular online game called Kingdom of Loathing. This is my blog. There are many like it, but this one is mine.

Sites I frequent:
Comics:
Cyanide and Happiness
Scary Go Round
Overcompensating
Achewood
Starslip Crisis
A Softer World
Wondermark
Dresden Codak
Questionable Content
Penny Arcade
Dr. McNinja
White Ninja
Dinosaur Comics
Boy On a Stick
Cat and Girl
XKCD
Order of the Stick
AppleGeeks
Goats
Zebragirl
Gunnerkrigg Court
Buttersafe
Kate Beaton
Bear & Kitten
Wigu
Wonderella
FreakAngels
Lucid TV
A. Charles Christopher
MS Paint Adventures

Blogs &c.:
My Blog Loves Me
Boing Boing
MetaFilter
Slashdot
Rock, Paper, Shotgun
Tobold
The Comics Curmudgeon
Warren Ellis
Slumbering Lungfish
X-Entertainment
Defective Yeti
Play This Thing
Jay Is Games
Ectoplasmosis
TokyoMango

Tags under construction
Pics

Tue Oct 27

On Programming

Yeah, sorry guys, still no new IF reviews from me — I’ve been using my spare time to work on my own IF project.

About which, here’s something interesting that happened: I’ve implemented this cat, named Frobozz, who wanders randomly around the house that the game largely takes place in. The problem I was having was that my pathfinding code doesn’t take closed doors into account (I tried, but doing so caused him to not want to travel through open doors either).

So, for example, if Frobozz tried to go east and the door in that direction was closed, he’d bounce off, and you’d see:

Frobozz saunters off to the east.
You hear a jingle, and look down to see that Frobozz has wandered into the room.

Less than ideal.

The solution I arrived at, with my limited knowledge of Inform 7? I implemented a second, invisible cat, named Shadow. When Frobozz wants to go somewhere, Shadow tries it first, and if he ends up still in the same room then Frobozz doesn’t bother trying.

My point basically is that for me, the most satisfying part of programming is when an utterly insane solution to a problem totally works.

Comments (View)
blog comments powered by Disqus