Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

7dRL: GartenRL

0 views
Skip to first unread message

Required field cannot be left blank

unread,
Mar 7, 2010, 9:39:22 PM3/7/10
to
Development of GartenRL had to be delayed due to a random outcome of
leaving the house yesterday.

Started coding at around 20:00 and first included a messagehandler
from one of my other unfinished roguelikes. I gave a german message
containing the word "öde" and was confronted with the first boss-like
problem: My neat little @ started to duplicate when it came close to
the upper left corner :-( That was close to where the randomly
generated ö was. I first tried to hack it away by redrawing the whole
screen every turn, and so found out that the problem was caused by
curses! It got the string as a 2-byte value, while the terminal only
outputs one visible char, and thus moving the cursor only one char
forward. The problem was immune to UTF-conversions and locale-changes,
and i was on to delay it until the end of the challenge, when vims :h
command came up with: iconv. Now i am using latin1 encoding where öäü
and ß are one-byte, and the bug is derezzed!

Then i quickly and smoothly hacked background-color handling into my
map and now have a nice way to visually display the season we're in.
nightly-2 tarball at http://www.tuxcode.org/k/7drl-challenge-2010.html

0 new messages