Can someone please explain to me, in full, how to write out synonyms for objects??
I have written several released games, but apparently I don’t fully understand 'Understand…(synonym part)/(synonym part)/-- (synonym part)/-- (synonym part)/(synonym part)" as (object). Let me give you an example of how I have been doing it (thinking it is working).
An iron handle is here. It is scenery. The description is "The handle was hanging down from the manhole cover that I moved; [if the iron cover is open]the cover was lying partially over the manhole[otherwise]the cover was now covering the hole[end if]." Understand "manhole/iron/-- cover/lid/-- cover/lid/handle" as the iron handle.
I was thinking that if the player typed only ‘cover’ or ‘lid’, that would work. I was thinking that the parser would take any one of the first two groups of words as ‘optional’ while one of the last group of words would be required, and any one of those words would be adequate. But I get only ‘I couldn’t see any such thing.’ when I test it. Which leads me to think that many of the 500-odd other objects that I have implemented also have wrong ‘Understand’ clauses.
Now, when I type ‘manhole lid lid’, it works. Or ‘iron cover cover’. Weird. (by the way, the iron cover is a scenery item on the floor of one room, and the iron handle is another scenery item in a room directly under it, and I am making the handle synonymous with the cover that it is ‘under’)
So can someone please spell it out for me (to coin a phrase)?