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

Another late 1kBRL: A Journey To Hell

151 views
Skip to first unread message

Jakub Wasilewski

unread,
Sep 6, 2008, 5:42:44 PM9/6/08
to
Hi everyone,

I'm not a regular here, but a colleague of mine reads r.g.r.d often,
and he told me about the 1kBRL contest. I'm a game developer and also
a roguelike fan, so it seemed like a fun challenge. I realize I am a
bit late (unfortunately), but I think my game is still at least
somewhat interesting. It's written in standard C (at least it compiles
with -ansi under GCC) and has exactly 1024 bytes to the dot.

I tried to keep as much elements from classic roguelikes as possible.
The game features:

- randomly generated, fully traversable levels of rooms and corridors
- fully functional line of sight
- collectable gold
- items: souls and gems
- chests with random contents
- monsters with semi-competent AI (won't run into walls all the time)
- character progression and levels getting progressively harder
- winning/death
- coloured graphics

I hope you all like it. The full archive can be found here:

http://wasyl.eu/storage/ajth.zip
http://wasyl.eu/storage/ajth.tar.gz

It contains Windows binaries and source code for both Linux and
Windows. Only the Linux source code is 1024 bytes, though - I ran into
some incompabilities between Windows and Linux and had to provide
different source for Windows. There is also a README explaining the
game.

Have fun! :)

na...@nate879.org

unread,
Sep 6, 2008, 6:33:34 PM9/6/08
to
On Sep 6, 5:42 pm, Jakub Wasilewski <krajz...@gmail.com> wrote:
> Hi everyone,
>
> I'm not a regular here, but a colleague of mine reads r.g.r.d often,
> and he told me about the 1kBRL contest. I'm a game developer and also
> a roguelike fan, so it seemed like a fun challenge. I realize I am a
> bit late (unfortunately), but I think my game is still at least
> somewhat interesting. It's written in standard C (at least it compiles
> with -ansi under GCC) and has exactly 1024 bytes to the dot.
>
> I tried to keep as much elements from classic roguelikes as possible.
> The game features:
>
> - randomly generated, fully traversable levels of rooms and corridors
> - fully functional line of sight
> - collectable gold
> - items: souls and gems
> - chests with random contents
> - monsters with semi-competent AI (won't run into walls all the time)
> - character progression and levels getting progressively harder
> - winning/death
> - coloured graphics
>
> I hope you all like it. The full archive can be found here:
>
> http://wasyl.eu/storage/ajth.ziphttp://wasyl.eu/storage/ajth.tar.gz

>
> It contains Windows binaries and source code for both Linux and
> Windows. Only the Linux source code is 1024 bytes, though - I ran into
> some incompabilities between Windows and Linux and had to provide
> different source for Windows. There is also a README explaining the
> game.
>
> Have fun! :)

This is the best 1kbBRL I have played so far. It's also one of the few
to provide source code that can compile on Linux. I like the way you
can "slide" past walls if you try to go diagonally into a wall.

Otto Grimwald

unread,
Sep 7, 2008, 1:37:11 PM9/7/08
to
Jakub Wasilewski wrote:

> It contains Windows binaries and source code for both Linux and

When compiling with
gcc ajth.c -o ajth -lcurses

I got :

ajth.c:9: error: array of inappropriate type initialized from string
constant

My gcc version is 4.3.2 (latest). I could compile it with an older gcc
(4.1). Since it requires so little dependencies, maybe you could provide
the linux binary as well...

When the game ends, it hangs the current console however.

It's a well done roguelike. Amazing to see the shadows and such.

Darren Grey

unread,
Sep 7, 2008, 12:40:37 PM9/7/08
to
On Sep 6, 10:42 pm, Jakub Wasilewski <krajz...@gmail.com> wrote:
> Hi everyone,
>
> I'm not a regular here, but a colleague of mine reads r.g.r.d often,
> and he told me about the 1kBRL contest. I'm a game developer and also
> a roguelike fan, so it seemed like a fun challenge. I realize I am a
> bit late (unfortunately), but I think my game is still at least
> somewhat interesting. It's written in standard C (at least it compiles
> with -ansi under GCC) and has exactly 1024 bytes to the dot.

Very nice, and quite a fun little game. The dynamic of enemies acting
first was interesting, since it led to the opposite sort of timing
you'd normally expect in roguelikes (thus leading you to get a monster
into a position where you attack when it's 2 spaces away). Pity
there's not more levels of increasing challenge - managed to beat the
game on my second attempt. Still, extremely impressive within the
size limit, especially the random levels and and LOS.

--
Darren Grey

Jakub Wasilewski

unread,
Sep 7, 2008, 12:43:52 PM9/7/08
to
> This is the best 1kbBRL I have played so far.

Thanks! :)

> When compiling with
> gcc ajth.c -o ajth -lcurses
>
> I got :
>
> ajth.c:9: error: array of inappropriate type initialized from string
> constant

I thought this only occurs on Windows. The code relies on the
assumption that wchar_t is the same as int, which turned out not to be
the case on some systems/compilers. That error is one of the reasons I
had to make a separate source for Windows.

I'll try to make a statically linked executable for Linux. I'll just
have to figure out how to convince curses to link statically.

> When the game ends, it hangs the current console however.

Are you sure it hangs? You have to exit with shift+Q after dying or
winning the game (that's the only way I could make death and winning
fit). The console is used in raw mode, so it might appear as if it's
hung (CTRL+C won't work etc.).

Jakub Wasilewski

unread,
Sep 7, 2008, 1:27:46 PM9/7/08
to
I updated the original downloads at:

http://wasyl.eu/storage/ajth.zip
http://wasyl.eu/storage/ajth.tar.gz

They now should include a statically linked Linux binary for those who
have problems compiling. I just hope I didn't mess up with the static
compile, I've always had problems making truly independent binaries
under Linux...

> Pity there's not more levels of increasing challenge - managed
> to beat the game on my second attempt.

Well, balancing is rather hard in such a small space, but I thought it
was challenging enough... Perhaps I'm just not enough of a roguelike
player ;). Anyway, you can easily make it harder. Just change the part
of the source code that says:

F(b,L*2)E(98+r%L);

If you change the *2 to something higher, there will be more monsters
on each level. If you change the 98 to something higher, the monsters
on each level will be tougher. Glad that you liked it anyway! :)

Otto Grimwald

unread,
Sep 7, 2008, 5:25:17 PM9/7/08
to
Jakub Wasilewski wrote:

> They now should include a statically linked Linux binary for those who
> have problems compiling. I just hope I didn't mess up with the static

it seems you succeded because I could run it both on a recent Archlinux
distribution, and on an "old" Debian Etch.

>Are you sure it hangs? You have to exit with shift+Q

yes you're right, it's working as expected.

what is the licence of your game? Is it possible to include it on a
linux live cd for example?

Jakub Wasilewski

unread,
Sep 7, 2008, 5:19:46 PM9/7/08
to
On 7 Wrz, 23:25, Otto Grimwald <contact_is_on_webs...@anamnese.fr.st>
wrote:

> >Are you sure it hangs? You have to exit with shift+Q
> yes you're right, it's working as expected.

Actually, it's not working as expected (from the user perspective),
because you thought it hanged ;). Still, it's working like I coded it,
and there's no easy way to change that without going over the 1kB
limit. I've added a notice to the readme explaining the need to press
Q after each game.

> what is the licence of your game? Is it possible to include it on a
> linux live cd for example?

I didn't really think about AJTH as more than a curiosity and a nice
way to flex my programming muscles, so I didn't include a license
initially. I've added one to the archives, it's explicitly zlib/libpng
now. Which basically states "do-whatever-you-want", so including it
anywhere is definitely okay :).

Jakub Debski

unread,
Sep 8, 2008, 4:26:35 AM9/8/08
to
on 2008-09-06, Jakub Wasilewski supposed :

> - randomly generated, fully traversable levels of rooms and corridors
> - fully functional line of sight
> - collectable gold
> - items: souls and gems
> - chests with random contents
> - monsters with semi-competent AI (won't run into walls all the time)
> - character progression and levels getting progressively harder
> - winning/death
> - coloured graphics

Very, very nice :)

regards,
Jakub


guesst

unread,
Oct 6, 2008, 1:26:43 PM10/6/08
to
I'm having a problem with "d" level monsters trapping my character on
the 3rd level by moving into the same space. And I'm having the same
randomization issues as mentioned in the read me, so it's very
reproducible.

Do you have a version that is slightly more than 1K to fix these
problems? Maybe limit yourself to 2K?

dominik...@gmail.com

unread,
Oct 15, 2008, 3:35:57 AM10/15/08
to
On 7 sep, 19:27, Jakub Wasilewski <krajz...@gmail.com> wrote:
> I updated the original downloads at:
>
> http://wasyl.eu/storage/ajth.zip
> http://wasyl.eu/storage/ajth.tar.gz

"You have requested a page or object that was not found on the server.
This may be the result of a typo or broken link."

Am I:
a) dumb?
b) out of luck?
c) missing something?

Mingos.

Michal Bielinski

unread,
Oct 15, 2008, 2:37:13 PM10/15/08
to
On Wed, 15 Oct 2008 09:35:57 +0200, Mingos wrote:
> On 7 sep, 19:27, Jakub Wasilewski <krajz...@gmail.com> wrote:
>> I updated the original downloads at:
>>
>> http://wasyl.eu/storage/ajth.zip
>> http://wasyl.eu/storage/ajth.tar.gz
>
> "You have requested a page or object that was not found on the server.
> This may be the result of a typo or broken link."
>
> Am I:

This one:
> c) missing something?

Error 404 Not Found (File does not exist: /storage/ajth.tar.gz)

That means that you are also:
> b) out of luck?

... because author seems to have deleted the archive.
See http://wasyl.eu/storage/
--
Michal Bielinski

Jakub Wasilewski

unread,
Oct 16, 2008, 8:05:33 PM10/16/08
to
> > "You have requested a page or object that was not found on the server.
> > This may be the result of a typo or broken link."

> ... because author seems to have deleted the archive.

Sorry about that. Should be back up now.

0 new messages