[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Zombie, PFile and the like



On Sat, 26 Jun 1999, Christian Reiniger wrote:

>Jan, some days ago, thinking about this and that, that statement of yours
>about networking not being one of the sexy parts of game coding came to my
>mind again. And, well, that description also perfectly fits for file
>handling. That means Zombie and PenguinFile are very much alike in that
>respect. And the other things I plan to do later, PenguinConfig and
>PenguinGUI, also fit in there.

Yeah, only gfx and sound classify as 'cool'. Which is a shame really, but
it probably has to do with (usually) the lack of understanding of what
happens 'behind the scenes' in an application. What datastructures are
used, how is data transferred between parts, and so on. I'm personally
more interested in those areas of games programming, probably as I'm
studying computer science and have at least a basic knowledge of such
issues...

As for the reason for me to write was that you mentioned PenguinConfig.
Well, depending on the type of system desired it can maybe get picked
stratight out of Zombie. Z uses simple 'ini-like' files, such as:

[Directories]
Graphics = share/gfx
Sound    = share/sound
Mape     = data/maps

# a small comment
#
[Frobnications]
Switch   = /usr/bin/app -w -x %s
UseMagic = true

And so on. Data is arranged into 'sections' and further divided by 'keys'.
The system in Z allows for automatic parsing and management of such files.
Whitespace can be used to format the config-files, as somewhat intelligen
regular expressions are used to do the dirty work of parsing it. The
developer can then use methods such as:

  bool Magic = m_Config->setting ("Directories", "UseMagic")->toBool ();

But if some entirely different scheme is to be used then this won't cut
it, but it can be worth to investigate.

>(1) It's fun. I greatly enjoy building PenguinFile and am looking forward
>to PConfig etc.

Fun keeps you going for maybe a year, maybe a little bit more.

<# 2 cut>

>That's my motivation. I want to do things properly. I want to make the best
>such system around.

Good motivations! But I've now also started to doubt the entire approach
I've had, i.e. design, protocols etc, as they seem to be really poorly
designed from the start. After _that_ it's quite hard to go on.

>PS: Writing unsexy stuff has one big advantage: you have very little
>competition ;+)

:-)

---------------------+------------------------------------------------------
 Jan 'Chakie' Ekholm |    CS at Åbo Akademi University, Turku, Finland
    Linux Inside     | I'm the blue screen of death, no-one hears you scream