Right, I’m having Problems Testing multiple conditions to bring about end of the game in Inform7.
I’ve reduced the game to Two rooms, for demonstration purposes.
1/ PHONE BOOTH
2/ STREET
The Aim of the game is simple. A taxi is going to pick you up from the STREET location after you call it.
A/ Call taxi from PHONE BOOTH.
B/ Go to STREET.
C/ Wait FIVE turns (or minutes)
D/ Get picked up by Taxi
E/ Game ends
If your not in the street at the right time you miss the taxi and have to call again. (The taxi doesn’t wait you if your not there)
So, to end the game I need to test two conditions:
That the players location is at “STREET”
AND
That so many turns (time) have elapsed since phone call. e.g right place right time.
If the player calls but is not at the “STREET” when the timer runs down then it says something like “you missed your taxi.” and the game just continues.
With more than one condition I just can’t seem to get the syntax right.
I’d be grateful if anyone could point me in the right direction.
//////////
Code:
"Taxi" by lampgetter.
When play begins:
now the right hand status line is “[time of day]”.
Phone booth is a room.
Street is a room.
[obviously there are lots more rooms in my game, but this makes it easier to show the problem]
Street is west of phone booth.
Taxi is a backdrop. Taxi is everywhere.
[this seems weird but it seems to work, because I’m verb-ing an abstract idea “the taxi”]
Phoning is an action applying to one visible thing.
Understand “Phone [something]” as Phoning.
Check phoning when the location of the player is not Phone booth: instead say “you need to be at the Phone Booth to call the taxi!”.
Carry out phoning:
Say “the taxi will arrive in 5 minutes at [5 minutes after time of day]”;
(? What next)