[DGD] Some strange newbie questions.
Felix A. Croes
felix at dworkin.nl
Thu Mar 1 15:20:05 CET 2007
"Stefan Karamanov" <vonamarak at gmail.com> wrote:
>[...]
> I was very happy to see that DGD proccess cyrillic characters
> easily, reciving them from my MUSHClient, storing them and sending
> them back, all right. With minor change in the requirements for char
> name, I've even made some heroes named in Cyr charactes. But then, I
> got deeper, because I wanted (for the sake of the atmosphere and ease
> of cyrillic users) all the comands in bulgarian words too, written in
> cyrillic. Then I found that the driver have no problems with cyrillic
> strings in quotes ( "..." ), but displays them as errors (Illegal
> characters) while compiling when they are tried, let's say - for
> naming a command.
> Can you suggest me a solution for those obstructions, or maybe
> a way to "alias" the unpossible cyrillic commands - existing normal
> command and assigning another name for it?
I think you are talking about identifiers in LPC -- function and variable
names. DGD only accepts the orginary alphanumeric characters and
underscore for those. I have no plans to change this; what is a letter
in one characterset may be a non-breaking space in another. In order
to change this yourself, you would have to modify the function
tk_gettok() in dgd/src/lex/token.c to add your desired characters
to those that make up an identifier, and then recompile the driver.
An alternative would be to overlay the programming language with
another one which is compiled to LPC. In that language, you could
make identifiers anything you wish. This would be more work, but it
would not require any modifications to the driver.
Finally, for the user who does not do any programming, using Cyrillic
characters for all text is possible at the mudlib level, again without
any modifications to the driver.
Regards,
Dworkin
More information about the DGD
mailing list