Right or wrong, I’m trying to present a room description without following it with a listing of all the things in the location I’ve just described.
The problem is that I need to modify that description to reflect if the objects are there or not. In this particular room there is a wheelbarrow and rake. This means I need to have a response for everything there, rake gone, barrow gone, both gone. This creates a bunch of code if I want the description to be responsive.
I have two questions:
-
Is this just the way it is and I’m doing it right?
-
What is the correct syntax for “If the rake and the wheelbarrow are not in the side yard:” because this is wrong?
Report going to the side yard:
If the rusty wheelbarrow is not in the side yard:
say "The path through the side-yard is badly overgrown. Dried and brittle foliage clings to your clothing as you pass, setting off the sounds of scuttling in the darkness. A worn out [rake] sits discarded by the path.";
stop the action;
otherwise:
say "The path through the side-yard is badly overgrown. Dried and brittle foliage clings to your clothing as you pass, setting off the sounds of scuttling in the darkness. A [rusty wheelbarrow] and worn out [rake] sit discarded by the path.";
Report going to the side yard:
If the rake is not in the side yard:
say "The path through the side-yard is badly overgrown. Dried and brittle foliage clings to your clothing as you pass, setting off the sounds of scuttling in the darkness. A [rusty wheelbarrow] sits discarded by the path.";
stop the action;
otherwise:
say "The path through the side-yard is badly overgrown. Dried and brittle foliage clings to your clothing as you pass, setting off the sounds of scuttling in the darkness. A [rusty wheelbarrow] and worn out [rake] sit discarded by the path.";
report going to the side yard:
If the rake and the wheelbarrow are not in the side yard:
say "The path through the side-yard is badly overgrown. Dried and brittle foliage clings to your clothing as you pass, setting off the sounds of scuttling in the darkness.";
stop the action;
otherwise:
say "The path through the side-yard is badly overgrown. Dried and brittle foliage clings to your clothing as you pass, setting off the sounds of scuttling in the darkness. ";