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

Chinese IF

3 views
Skip to first unread message

Spencer Yu

unread,
Apr 26, 1999, 3:00:00 AM4/26/99
to
Dear IF community,

Has anyone tried to write a IF peice in Chinese or Japanese? I want to
write an IF game in Chinese, but I am not sure if there are any IF engine
that is general enough to handle it. The biggest problem is, obviously,
parsing. For example, in Chinese, there are no space between words, so any
parser that extracts tokens by looking for space probably won't cut it.
Can anyone comment on the following approaches:

a. Use Inform or TADS. Is the parser in Inform or TADS general enough
so that I can write a Chinese grammar for them, without changing
the source code?
b. Modify the source code of Inform or TADS. or
c. Write a new IF engine.

Thank you very much.


Unkle84

unread,
Apr 26, 1999, 3:00:00 AM4/26/99
to
I could only think of one feasible way, but you're restricting your game to
PCs. You could bit code the ASCII characters if you wanted to. You know,
perhaps I'll work on a Translation Set for Romaji.....

-A. Mendoza

Kristofer Osegard

unread,
Apr 26, 1999, 3:00:00 AM4/26/99
to
Spencer,

While I don't have any answers for you, I'm very pleased to see you're
interested in writing IF in Chinese. That sounds like a very interesting
challenge.

Good Luck,
-K

Dark Fiber

unread,
Apr 27, 1999, 3:00:00 AM4/27/99
to
On 26 Apr 1999 07:40:57 GMT, u822...@cc.nctu.edu.tw (Spencer Yu)
wrote:

>Dear IF community,
>
> Has anyone tried to write a IF peice in Chinese or Japanese? I want to
>write an IF game in Chinese, but I am not sure if there are any IF engine
>that is general enough to handle it. The biggest problem is, obviously,
>parsing. For example, in Chinese, there are no space between words, so any
>parser that extracts tokens by looking for space probably won't cut it.
>Can anyone comment on the following approaches:
>
> a. Use Inform or TADS. Is the parser in Inform or TADS general enough
> so that I can write a Chinese grammar for them, without changing
> the source code?

i dunno bout tads but inform is sposed to be able to handle unicode
if you want to implement one of the chinese say GB2312 or HZ
encoding. if for example it was running on chinese windows
that'd prolly handle character output for you (i guess...)
the only thing is you would have to re-write the parser
portions of the code to handle different sentence structure...

TenthStone

unread,
Apr 27, 1999, 3:00:00 AM4/27/99
to
On 26 Apr 1999 07:40:57 GMT, u822...@cc.nctu.edu.tw (Spencer Yu)
wrote:

>Dear IF community,
>
> Has anyone tried to write a IF peice in Chinese or Japanese?

No.

>I want to write an IF game in Chinese, but I am not sure if there are any IF engine
>that is general enough to handle it. The biggest problem is, obviously,
>parsing. For example, in Chinese, there are no space between words, so any
>parser that extracts tokens by looking for space probably won't cut it.

The upcoming TADS parser will allow different types of tokenization.
However, traditional tokenization itself would be well-nigh impossible
in Chinese. The best bet would be something which divided the input
into syllables.

This is, of course, assuming that commands would be entered in pin
yin. If they were entered in ideograms, tokenization would almost be
complete already, especially in Chinese.

The difficulty would be writing a grammar. Inform's parsing systems
would have to be completely rewritten (this statement is hereby
qualified), and since such a feat is possible in Inform, that might
work well. TADS 3 will include a highly adaptable grammar system, so
that might work better.

I'm not certain about Unicode support in either of these systems.
Inform, I think, supports it on a theoretical basis but hasn't really
been tested on it.

Returning to the issue of parsing: Since the Chinese language is
fundamentally syllabic, a reasonably advanced tokenizer could split
pin yin into syllables. Then again, pin yin is usually seperated by
spaces (again, t.s.i.h.q.), so that's probably not what you're talking
about.

As for writing the grammar: this shouldn't be too much of a problem.
I'm not by any means greatly experienced in Chinese, but it seems to
me that it really shouldn't be a major thorn.

If verbs are locked into a certain position (which is another thing
that I can't remember), then a grammar would be especially easy.


Ricardo Dague

unread,
Apr 27, 1999, 3:00:00 AM4/27/99
to
Kristofer Osegard wrote:
>
> Spencer,
>
> While I don't have any answers for you, I'm very pleased to see you're
> interested in writing IF in Chinese. That sounds like a very interesting
> challenge.
>
> Good Luck,
> -K
>
> Spencer Yu wrote:
>
> > Dear IF community,
> >
> > Has anyone tried to write a IF peice in Chinese or Japanese? I want to

> > write an IF game in Chinese, but I am not sure if there are any IF engine
> > that is general enough to handle it. The biggest problem is, obviously,
> > parsing. For example, in Chinese, there are no space between words, so any
> > parser that extracts tokens by looking for space probably won't cut it.
> > Can anyone comment on the following approaches:
> >
> > a. Use Inform or TADS. Is the parser in Inform or TADS general enough
> > so that I can write a Chinese grammar for them, without changing
> > the source code?
> > b. Modify the source code of Inform or TADS. or
> > c. Write a new IF engine.
> >
> > Thank you very much.

This is just a guess of how to proceed, but you might start
with small projects and work your way up to more complicated
ones.

For example, write a Chinese or Japanese version of Scott
Adams's machine which would run a C/J translation of
Adventureland. If you can make something like this, then
you've crossed the basic hurdles of player -> computer
talking (a two-word parser) and computer -> player talking
(a simple one-line report of what happened [e.g. "Your
chigger bites are now infected."] and object listings).

After you've solved those problems, tackle the harder ones
like multi-word parsing and complicated object listings.

HTH :)
-- Ricardo

0 new messages