Mantis Bug Tracker

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0000350Core InformRules and rulebookspublic2010-10-24 11:402011-01-10 11:15
Reporteralex 
Assigned Tograham 
PrioritynormalSeveritycosmeticReproducibilityalways
StatusclosedResolutionfixed 
PlatformOSMac OS XOS Version
Product Version6E59 
Target VersionFixed in Version6G60 
Summary0000350: Attempting to rearrange rules during play results in a misleading error
DescriptionThe code below prints two errors:

Problem. You wrote 'now the can't go through closed doors rule is listed in the after rulebook' , but although 'can't go through closed doors rule is listed in the after rulebook' is a condition which it is legal to test with 'if', 'when', and so forth, it is not something I can arrange to happen on request. Whether it is true or not depends on current circumstances: so to make it true, you will need to adjust those circumstances.

 See the manual: 8.11 > Now...

I was trying to match this phrase:

(can't go through closed doors rule - value) is listed in (after rulebook - list of values)

This was what I found out:

can't go through closed doors rule = a values based rule producing values

after rulebook = a rulebook



--------------------------------------------------------------------------------

Problem. You wrote 'if the can't go through closed doors rule is listed in the after rulebook begin' , but 'after rulebook' has the wrong kind of value: a rulebook rather than a list of values.

I was trying to match this phrase:

(can't go through closed doors rule - value) is listed in (after rulebook - list of values)

This was what I found out:

can't go through closed doors rule = a values based rule producing values

after rulebook = a rulebook
Minimal Source Text To Reproduce
Place is a room.

When play begins:
	now the can't go through closed doors rule is listed in the after rulebook;
	if the can't go through closed doors rule is listed in the after rulebook:
		say "text goes here"
Additional Information"What really strikes me about this isn't that the code doesn't work, but that the compiler misinterprets the condition and says it can be tested when in fact it can't. A better message would be:


Problem. You wrote 'now the can't go through closed doors rule is listed in the after rulebook', but the order of rules and the rulebooks they are listed in cannot be changed during play. If what you are trying to do is reorder something, it must be declared as 'The instant death rule is listed last in the fate rules' or similar."
TagsNo tags attached.
Effect(cosmetic) Error message is badly worded
Attached Files

- Relationships

-  Notes
(0000864)
graham (administrator)
2010-11-21 15:56

This might look confusing, but it's all quite correct. Inform understands a different sense of "listed in" from the one you think - it's reading this as finding elements in a list (and it does say this). It's true that this can't be forced with "now", and it's true that this can be tested.

- Issue History
Date Modified Username Field Change
2010-10-24 11:40 jmcgrew New Issue
2010-10-24 11:42 jmcgrew Status new => acknowledged
2010-10-24 11:43 jmcgrew Status acknowledged => confirmed
2010-10-24 12:05 jmcgrew Reporter jmcgrew => email
2010-10-29 09:01 jmcgrew Reporter email => alex
2010-11-21 15:56 graham Note Added: 0000864
2010-11-21 15:56 graham Status confirmed => resolved
2010-11-21 15:56 graham Resolution open => fixed
2010-11-21 15:56 graham Assigned To => graham
2010-12-23 17:37 jmcgrew Fixed in Version => 6G60
2011-01-10 11:15 jmcgrew Status resolved => closed


Copyright © 2000 - 2010 MantisBT Group
Powered by Mantis Bugtracker