Some coin classes act differently, can't tell why!
The group you are posting to is a
Usenet group . Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
Newsgroups: rec.arts.int-fiction
From:
Janny <kitza... @gmx.co.uk>
Date: Wed, 30 Apr 2008 14:13:45 +0200
Local: Wed, Apr 30 2008 8:13 am
Subject: [TADS 3] Some coin classes act differently, can't tell why!
Hi.
Some of my coin classes don't behave and I can't figure out what's different about those that do.
Example:
You see fifteen coins (three marks, three dollars, three pennies, three crowns, and three zorkmids) here.
]get coin Which coin do you mean, a crown, a dollar, a zorkmid, a penny, or a mark?
]penny Taken.
That's what I wanted. BUT:
]get coin Which coin do you mean, a crown, a dollar, a zorkmid, a penny, or a mark?
]dollar dollar: Taken. dollar: Taken. dollar: Taken.
The zorkmids behave like the dollars, too.
The code is a crude dumbing-down of the coins from sample.t:
class Coin: Thing vocabWords = 'coin*coins' listWith = [coinGroup] collectiveGroup = coinCollective ; coinGroup: ListGroupParen showGroupCountName(lst) { "<<spellIntBelowExt(lst.length(), 100, 0, DigitFormatGroupSep)>> coins"; } compareGroupItems(a, b) { return b.coinValue - a.coinValue; } ; coinCollective: ItemizingCollectiveGroup '*coins' 'coins' ; class Penny: Coin 'penny*pennies' 'penny' isEquivalent = true coinValue = 9 ; class Mark: Coin 'mark*marks' 'mark' isEquivalent = true coinValue = 40 ; class Crown: Coin 'crown*crowns' 'crown' isEquivalent = true coinValue = 5 ; class Dollar: Coin 'dollar*dollars' 'dollar' isEquivalent = true coinValue = 10 ; class Zorkmid: Coin 'zorkmid*zorkmids' 'zorkmid' isEquivalent = true coinValue = 1 ;
I'm confused, to say the least...
You must
Sign in before you can post messages.
You do not have the permission required to post.
Newsgroups: rec.arts.int-fiction
From:
Khelwood <Khelw... @gmail.com>
Date: Wed, 30 Apr 2008 05:57:11 -0700 (PDT)
Local: Wed, Apr 30 2008 8:57 am
Subject: Re: Some coin classes act differently, can't tell why!
On 30 Apr, 13:13, Janny <kitza
... @gmx.co.uk> wrote:
> Hi.
> Some of my coin classes don't behave and I can't figure out what's > different about those that do.
> Example:
> You see fifteen coins (three marks, three dollars, three pennies, three > crowns, and three > zorkmids) here.
> ]get coin > Which coin do you mean, a crown, a dollar, a zorkmid, a penny, or a mark?
> ]penny > Taken.
> That's what I wanted. BUT:
> ]get coin > Which coin do you mean, a crown, a dollar, a zorkmid, a penny, or a mark?
> ]dollar > dollar: Taken. > dollar: Taken. > dollar: Taken.
> The zorkmids behave like the dollars, too.
> The code is a crude dumbing-down of the coins from sample.t:
> class Coin: Thing > vocabWords = 'coin*coins' > listWith = [coinGroup] > collectiveGroup = coinCollective > ; > coinGroup: ListGroupParen > showGroupCountName(lst) > { > "<<spellIntBelowExt(lst.length(), 100, 0, DigitFormatGroupSep)>> > coins"; > } > compareGroupItems(a, b) { return b.coinValue - a.coinValue; } > ; > coinCollective: ItemizingCollectiveGroup '*coins' 'coins' > ; > class Penny: Coin 'penny*pennies' 'penny' > isEquivalent = true > coinValue = 9 > ; > class Mark: Coin 'mark*marks' 'mark' > isEquivalent = true > coinValue = 40 > ; > class Crown: Coin 'crown*crowns' 'crown' > isEquivalent = true > coinValue = 5 > ; > class Dollar: Coin 'dollar*dollars' 'dollar' > isEquivalent = true > coinValue = 10 > ; > class Zorkmid: Coin 'zorkmid*zorkmids' 'zorkmid' > isEquivalent = true > coinValue = 1 > ;
> I'm confused, to say the least...
Normal word truncation length is 6. That's probably why the coins with
longer names are behaving differently. There was a bug in some earlier
versions of TADS 3 (I believe 3.0.10 to 3.0.12 had this issue) that
resulted in nouns being parsed plurally when they were as long as the
truncation length.
http://www.tads.org/t3doc/lib/adv3/changes.htm#3013 . What release of TADS 3 are you using?
You must
Sign in before you can post messages.
You do not have the permission required to post.
Newsgroups: rec.arts.int-fiction
From:
Janny <kitza... @gmx.co.uk>
Date: Wed, 30 Apr 2008 15:06:20 +0200
Local: Wed, Apr 30 2008 9:06 am
Subject: Re: Some coin classes act differently, can't tell why!
Khelwood wrote:
> Normal word truncation length is 6. That's probably why the coins with
> longer names are behaving differently. There was a bug in some earlier
> versions of TADS 3 (I believe 3.0.10 to 3.0.12 had this issue) that
> resulted in nouns being parsed plurally when they were as long as the
> truncation length.
http://www.tads.org/t3doc/lib/adv3/changes.htm#3013 > . What release of TADS 3 are you using?
3.0.16!
My farthings weren't working either. Five letters or less, and it's fine...
You must
Sign in before you can post messages.
You do not have the permission required to post.
Newsgroups: rec.arts.int-fiction
From:
Khelwood <Khelw... @gmail.com>
Date: Wed, 30 Apr 2008 06:13:17 -0700 (PDT)
Local: Wed, Apr 30 2008 9:13 am
Subject: Re: Some coin classes act differently, can't tell why!
On 30 Apr, 13:57, Khelwood <Khelw
... @gmail.com> wrote:
> On 30 Apr, 13:13, Janny <kitza
... @gmx.co.uk> wrote:
> > Hi.
> > Some of my coin classes don't behave and I can't figure out what's > > different about those that do.
> > Example:
> > You see fifteen coins (three marks, three dollars, three pennies, three > > crowns, and three > > zorkmids) here.
> > ]get coin > > Which coin do you mean, a crown, a dollar, a zorkmid, a penny, or a mark?
> > ]penny > > Taken.
> > That's what I wanted. BUT:
> > ]get coin > > Which coin do you mean, a crown, a dollar, a zorkmid, a penny, or a mark?
> > ]dollar > > dollar: Taken. > > dollar: Taken. > > dollar: Taken.
> > The zorkmids behave like the dollars, too.
> > The code is a crude dumbing-down of the coins from sample.t:
> > class Coin: Thing > > vocabWords = 'coin*coins' > > listWith = [coinGroup] > > collectiveGroup = coinCollective > > ; > > coinGroup: ListGroupParen > > showGroupCountName(lst) > > { > > "<<spellIntBelowExt(lst.length(), 100, 0, DigitFormatGroupSep)>> > > coins"; > > } > > compareGroupItems(a, b) { return b.coinValue - a.coinValue; } > > ; > > coinCollective: ItemizingCollectiveGroup '*coins' 'coins' > > ; > > class Penny: Coin 'penny*pennies' 'penny' > > isEquivalent = true > > coinValue = 9 > > ; > > class Mark: Coin 'mark*marks' 'mark' > > isEquivalent = true > > coinValue = 40 > > ; > > class Crown: Coin 'crown*crowns' 'crown' > > isEquivalent = true > > coinValue = 5 > > ; > > class Dollar: Coin 'dollar*dollars' 'dollar' > > isEquivalent = true > > coinValue = 10 > > ; > > class Zorkmid: Coin 'zorkmid*zorkmids' 'zorkmid' > > isEquivalent = true > > coinValue = 1 > > ;
> > I'm confused, to say the least...
> Normal word truncation length is 6. That's probably why the coins with > longer names are behaving differently. There was a bug in some earlier > versions of TADS 3 (I believe 3.0.10 to 3.0.12 had this issue) that > resulted in nouns being parsed plurally when they were as long as the > truncation length.http://www.tads.org/t3doc/lib/adv3/changes.htm#3013 > . What release of TADS 3 are you using?
OK, I've just tried it in 3.0.16. It seems to be a surviving bug.
It is related to truncation length, so until someone works out a
proper fix, you can get around it by extending or disabling the
truncation length: put
parserTruncationLength = some number bigger than 6
or parserTruncationLength = nil
in your gameMain.
You must
Sign in before you can post messages.
You do not have the permission required to post.
Newsgroups: rec.arts.int-fiction
From:
Khelwood <Khelw... @gmail.com>
Date: Wed, 30 Apr 2008 06:14:58 -0700 (PDT)
Local: Wed, Apr 30 2008 9:14 am
Subject: Re: Some coin classes act differently, can't tell why!
On 30 Apr, 14:13, Khelwood <Khelw
... @gmail.com> wrote:
> On 30 Apr, 13:57, Khelwood <Khelw
... @gmail.com> wrote:
> > On 30 Apr, 13:13, Janny <kitza... @gmx.co.uk> wrote:
> > > Hi.
> > > Some of my coin classes don't behave and I can't figure out what's > > > different about those that do.
> > > Example:
> > > You see fifteen coins (three marks, three dollars, three pennies, three > > > crowns, and three > > > zorkmids) here.
> > > ]get coin > > > Which coin do you mean, a crown, a dollar, a zorkmid, a penny, or a mark?
> > > ]penny > > > Taken.
> > > That's what I wanted. BUT:
> > > ]get coin > > > Which coin do you mean, a crown, a dollar, a zorkmid, a penny, or a mark?
> > > ]dollar > > > dollar: Taken. > > > dollar: Taken. > > > dollar: Taken.
> > > The zorkmids behave like the dollars, too.
> > > The code is a crude dumbing-down of the coins from sample.t:
> > > class Coin: Thing > > > vocabWords = 'coin*coins' > > > listWith = [coinGroup] > > > collectiveGroup = coinCollective > > > ; > > > coinGroup: ListGroupParen > > > showGroupCountName(lst) > > > { > > > "<<spellIntBelowExt(lst.length(), 100, 0, DigitFormatGroupSep)>> > > > coins"; > > > } > > > compareGroupItems(a, b) { return b.coinValue - a.coinValue; } > > > ; > > > coinCollective: ItemizingCollectiveGroup '*coins' 'coins' > > > ; > > > class Penny: Coin 'penny*pennies' 'penny' > > > isEquivalent = true > > > coinValue = 9 > > > ; > > > class Mark: Coin 'mark*marks' 'mark' > > > isEquivalent = true > > > coinValue = 40 > > > ; > > > class Crown: Coin 'crown*crowns' 'crown' > > > isEquivalent = true > > > coinValue = 5 > > > ; > > > class Dollar: Coin 'dollar*dollars' 'dollar' > > > isEquivalent = true > > > coinValue = 10 > > > ; > > > class Zorkmid: Coin 'zorkmid*zorkmids' 'zorkmid' > > > isEquivalent = true > > > coinValue = 1 > > > ;
> > > I'm confused, to say the least...
> > Normal word truncation length is 6. That's probably why the coins with > > longer names are behaving differently. There was a bug in some earlier > > versions of TADS 3 (I believe 3.0.10 to 3.0.12 had this issue) that > > resulted in nouns being parsed plurally when they were as long as the > > truncation length.http://www.tads.org/t3doc/lib/adv3/changes.htm#3013 > > . What release of TADS 3 are you using?
> OK, I've just tried it in 3.0.16. It seems to be a surviving bug. > It is related to truncation length, so until someone works out a > proper fix, you can get around it by extending or disabling the > truncation length: put > parserTruncationLength = some number bigger than 6 > or parserTruncationLength = nil > in your gameMain.
Oops. It's parserTruncLength, not parserTruncationLength. Sorry.
You must
Sign in before you can post messages.
You do not have the permission required to post.
Newsgroups: rec.arts.int-fiction
From:
Janny <kitza... @gmx.co.uk>
Date: Wed, 30 Apr 2008 15:18:56 +0200
Local: Wed, Apr 30 2008 9:18 am
Subject: Re: Some coin classes act differently, can't tell why!
Khelwood wrote:
> On 30 Apr, 14:13, Khelwood <Khelw
... @gmail.com> wrote:
>> On 30 Apr, 13:57, Khelwood <Khelw
... @gmail.com> wrote:
>> > On 30 Apr, 13:13, Janny <kitza... @gmx.co.uk> wrote:
>> > > Hi.
>> > > Some of my coin classes don't behave and I can't figure out what's >> > > different about those that do.
>> > > Example:
>> > > You see fifteen coins (three marks, three dollars, three pennies, >> > > three crowns, and three >> > > zorkmids) here.
>> > > ]get coin >> > > Which coin do you mean, a crown, a dollar, a zorkmid, a penny, or a >> > > mark?
>> > > ]penny >> > > Taken.
>> > > That's what I wanted. BUT:
>> > > ]get coin >> > > Which coin do you mean, a crown, a dollar, a zorkmid, a penny, or a >> > > mark?
>> > > ]dollar >> > > dollar: Taken. >> > > dollar: Taken. >> > > dollar: Taken.
>> > > The zorkmids behave like the dollars, too.
>> > > The code is a crude dumbing-down of the coins from sample.t:
>> > > class Coin: Thing >> > > vocabWords = 'coin*coins' >> > > listWith = [coinGroup] >> > > collectiveGroup = coinCollective >> > > ; >> > > coinGroup: ListGroupParen >> > > showGroupCountName(lst) >> > > { >> > > "<<spellIntBelowExt(lst.length(), 100, 0, >> > > DigitFormatGroupSep)>> >> > > coins"; >> > > } >> > > compareGroupItems(a, b) { return b.coinValue - a.coinValue; } >> > > ; >> > > coinCollective: ItemizingCollectiveGroup '*coins' 'coins' >> > > ; >> > > class Penny: Coin 'penny*pennies' 'penny' >> > > isEquivalent = true >> > > coinValue = 9 >> > > ; >> > > class Mark: Coin 'mark*marks' 'mark' >> > > isEquivalent = true >> > > coinValue = 40 >> > > ; >> > > class Crown: Coin 'crown*crowns' 'crown' >> > > isEquivalent = true >> > > coinValue = 5 >> > > ; >> > > class Dollar: Coin 'dollar*dollars' 'dollar' >> > > isEquivalent = true >> > > coinValue = 10 >> > > ; >> > > class Zorkmid: Coin 'zorkmid*zorkmids' 'zorkmid' >> > > isEquivalent = true >> > > coinValue = 1 >> > > ;
>> > > I'm confused, to say the least...
>> > Normal word truncation length is 6. That's probably why the coins with >> > longer names are behaving differently. There was a bug in some earlier >> > versions of TADS 3 (I believe 3.0.10 to 3.0.12 had this issue) that >> > resulted in nouns being parsed plurally when they were as long as the >> > truncation length.http://www.tads.org/t3doc/lib/adv3/changes.htm#3013 >> > . What release of TADS 3 are you using?
>> OK, I've just tried it in 3.0.16. It seems to be a surviving bug. >> It is related to truncation length, so until someone works out a >> proper fix, you can get around it by extending or disabling the >> truncation length: put >> parserTruncationLength = some number bigger than 6 >> or parserTruncationLength = nil >> in your gameMain.
> Oops. It's parserTruncLength, not parserTruncationLength. Sorry.
Thanks for the help!
You must
Sign in before you can post messages.
You do not have the permission required to post.