Having trouble with a raft

I’ve been trying to cop boat mechanics from Zork’s “Frigid River” section, but it’s missing something I’d like. I want the player to be able to “wait” when in the raft and automatically move to the next section of the river. Right now all I can do is make it impossible for the player go any direction but south (the direction the river flows) and have the player type “go south” or “south.” Coding for the boat and such is like this:

[code]Include Rideable Vehicles by Graham Nelson.

Check Launching:
if the player is not in the raft, say “You need to be in a boat to do that. A raft will do, though.”;
if the player is in the raft and in Underground Rivershore:
say “You push off from the shore and let the current carry you south.”;
move the raft to River1;
continue the action.

Landing is an action applying to nothing. Understand “land” as landing.

Check landing:
if the player is in River4:
say “You paddle a little with your hands into the frigid water and manage to guide the boat to shore.” instead;
move the raft to South Landing Spot instead.

Report dropping the raft in Underground Rivershore:
say “You set the raft down at the shore, half in the water, ready to push off.”.

Instead of going south in Underground Rivershore when the player is not in the raft:
say “The water is frigid. You’d die in minutes if you tried to swim in it.”

A river is a kind of room. A river is usually dark. The printed name of a river is usually “Underground River”. Check going north from a river: say “The current is too strong for you to go against it.” instead.

South of Underground Rivershore is a river called River1. The description of River1 is “The raft drifts down the silently flowing river with you aboard. The current carries you steadily to the south. All you can do is wait…”

South of River1 is a river called River2. The description of River2 is “The raft continues to travel by the southerly current with you aboard. Despite the river, everything is eerily silent. All you can do is wait…”

South of River2 is a river called River3. The Description of River3 is “The current picks up a little, and you feel a sinking feeling, not like you’re actually sinking, but that you’re going…down. River must be on a slope. Nothing you can do but wait, though.”

South of River3 is a river called River4. The description of River4 is “You aren’t going [italic type]down[roman type] anymore, at least. Thank heaven for small favours. There appears to be landable shore to your east, at last. You can’t see where the river goes beyond this point, even with your lantern.”

South Landing Spot is east of River4. “[if unvisited]The raft runs up onto a narrow strip of dry land.[otherwise]This is where you landed.[end if] The land continues east. To the north is only intraversable river.”

Instead of going north in South Landing Spot:
say “The water is frigid, and flowing against you to boot. Not a good idea.”

Instead of waiting when the player is in a river, try going south.[/code]

A couple notes: rivers are usually dark because the only river in-game is underground. The last part was my attempt at getting it to go south. It doesn’t do anything, though.

A couple other questions:

-Is there a way to make the game omit “Dropped.” when I drop the raft at a certain spot, like the launching spot? I have it say something (see “Report dropping the raft” in the above code), but it still says “dropped” after that part.

-Land is also glitching. just “land” does nothing, “land raft” says “I only understand you as far as wanting to land.” What am I doing wrong?

Thank you in advance, and sorry for all of these questions. I feel more than a little pathetic for not getting this.

Quick response to your second question before I look into your code: put “rule succeeds” at the end of your new Report, or use an After rule instead.

A-ha, thanks. Made it an After rule.

Land is glitching because you have two “insteads” in your rule. The first “instead” stops the code so the second line doesn’t get executed, and the raft doesn’t move. Also you don’t have a rule for landing that does anything when the player isn’t in River4, which is why nothing is happening. “Land raft” isn’t understood because you haven’t included an Understand line for “land [something]”, so the game doesn’t know how to understand “land” when it’s followed by a noun.

I think the problem with your waiting code might be that “the player is in a river” will only work when the river room is the immediate location of the player – that is, when the player isn’t in something else that’s in the river. In this case the player is in the raft, so it’s not firing… maybe. Try “Instead of waiting when the location is a River” and see if that works. (“The location” is short for “the location of the player” and is always the room where the player is.)

I think this is the second time you’ve helped me get out of a fix like this. Thanks a million. One last thing: Launching or landing works okay, but it won’t print the new location or a description unless I type “look” immediately after. Am I missing the obvious solution?

Huh, when the player gets moved it prints a room description (unless you tell it not to) but I guess when something that the player is in gets moved it doesn’t. Try “After launching: try looking”; or you could replace the “move the raft” phrases with “try going east” or whatever where appropriate (I’m not looking at the code right now so I’m not sure if that’s work).