If you define a class like so: you would expect Inform to set the plural bit for 'elephants', but it
doesn't. As far as I can see, the problem is in dictionary_prepare()
in text.c. Its main loop will terminate before it reaches the // part
of the word. The simplest -- though probably not the most efficient -- bug fix would
be to simply make the // test separate from the main loop. I've
included a patch, but unfortunately it turned out pretty unreadable to
humans. On second thought, this patch may not be ideal either. What if I change
the name property to 'taxidermist' 'taxidermists//p'? Anyway, the main problem is that with an unpatched Inform compiler, you
apparently can't set the plural flag on nine-letter words. Although this really is a bug in the compiler,
a quick way to address this problem (without patching and recompiling the compiler)
is to modify the word table directly in the game source: Of course that sort of code can look a little cryptic.
It makes for far more readable source to wrap it in a function: So various nine-character words can legibly be made plural in Initialise():
About Patches
Issue C62103
Plural bit not set on long dictionary words
Submitted by: Torbjörn Andersson
Appeared in: Compiler 6.21 or before
Fixed in: Compiler 6.30
Problem
Class Elephant
with name 'elephant' 'elephants//p'
has animate;
Solution
Workaround (by Jim Fisher)
'batteries'-->#dict_par1 = 'batteries'->#dict_par1 | 4;
[ MakePlural wrd; wrd-->#dict_par1 = wrd->#dict_par1 | 4; ];
MakePlural('batteries');
MakePlural('elephants');
MakePlural('ostriches');
MakePlural('creatures');
MakePlural('gargoyles');
MakePlural('loopholes');
MakePlural('limericks');
Last updated 17 April 2013.
This site is no longer supported; information may be out of date.
Maintained as a historical archive by the Interactive Fiction Technology Foundation.
Copyright 1993-2018 IFTF, CC-BY-SA unless otherwise noted.
This page was originally managed by Roger Firth.