Advice on how to do something.

First off a quick bit of backstory. I have been working on something for awhile and began running into compiling errors due to the amount of figures used, the bug report is filed. Anyway I decided to break the project up into 2 pieces. The game takes place over the course of a week beginning on monday and ending on friday. I broke part 1 up from mon- weds night and part 2 picking up on thurs morning. Ok now the problem is that actions you do or do not do during the earlier days directly or indirectly affect how things play out later so to carry settings over to the second part I decided to spit out a few passwords at the end of part 1 that you will then enter at the start of part 2 and these will carry settings over. The one problem I couldnt figure how to do is to bring the amount of money you have on you across but I will fudge my way through with that,

NOW, here is the problem I am now trying to do this but im not sure how, This is what I have at the moment.

[code]pregame is a scene.
pregame begins when play begins.

starting location is a room.

when play begins:
now the player is in starting location.

when play begins:
say “[paragraph break][paragraph break]Please enter the words listed at the end of (games name) below.”

When play begins:
change the command prompt to "Please enter first word > "

First Password is an indexed text that varies. Second Password is an indexed text that varies. Third Password is an indexed text that varies. Fourth Password is an indexed text that varies. Fifth Password is an indexed text that varies.

To decide whether collecting First Password:
if the command prompt is "Please enter first word > ", yes;
no.

To decide whether collecting Second Password:
if the command prompt is "Please enter second word > ", yes;
no.

To decide whether collecting Third Password:
if the command prompt is "Please enter third word > ", yes;
no.

To decide whether collecting Fourth Password:
if the command prompt is "Please enter fourth word > ", yes;
no.

To decide whether collecting Fifth Password:
if the command prompt is "Please enter fifth word > ", yes;
no.

After reading a command when collecting first password:
if the the player’s command is “monkey”:
say “[paragraph break] Thank you.”;
change the command prompt to “Please enter second word”;
(here I would make changes that the entered password would cause).[/code]

so if theres 5 passwords and about 5 choices for each of the passwords how would I actually code that out?

Thanks alot

You want ‘if the player’s command matches “monkey”’.
See the section on ‘Reading a command’ in the chapter on activities.

(Also, the player’s command can’t match against a text or indexed text variable. The “monkey” thing above counts as neither ‘text’ nor ‘indexed text’ but as a ‘topic’ – I never really understood the topic kind.)

Another option might be to just generate one long string and chop it up, so the player only has to type or paste in one password. If you want to pass just five variables with five possible values each, a five-letter string is more than enough to contain the actual info.

There was some talk in this thread.

Of course you may have other reasons to prefer five individual passwords.

yep thats it…I was one word off “matches” was the word I needed to use. Thank you!

The 5 passwords is with piggybacking multiple variables already. lol. I stripped it down to the bare essentials and made each password cover a few variables. otherwise I would have like 15. The one thing I did that I dont like is when you start the game you have $180.00 I have it that in the start of game 2 you have a check deposited in your checking account, but in the first part it is quite likely that you can spend all of that 180 dollars, what I did was for one of the passwords I had a if the price of the money is greater than or less than 80.00. Not a great solution since you can have 81.00 or all 180 but couldnt think of anything better. so if you have greater than 80 ill give you like 120 in part 2 and if you had less 55 or so. The other variables are easy, pretty much if people are mad at you or not.

Well, one simple solution to the money problem would be to just ask the player how much money there is left over from the first part of the game. True, it would give me a chance to cheat, but then, again, I would only be cheating against myself …

Wish the bug didnt exist so I didnt have to break the game in half…soooo annoying. :imp:

This would probably be a lot more work, but could you write the data from the end of part 1 to an external file that part 2 would read at the beginning? Then you might be able to write out all the data without having to worry about cutting down the number of passwords, since they’d be read in automatically. (Disclaimer: I have never done anything with external files and don’t know how annoying this would be to program.)