PDA

View Full Version : Go To Previous Scene Help



Ambassador Kosh
03-20-2002, 09:11 PM
I was hoping someone would help me with this. I have a demo that will self pace by using the left and right arrow keys. I've been using jumpmarks. I have an event object that will cause the demo to go to the next scene. The problem is I cannot do the same if I wanted to go to the previous scene. Kim gave me a suggestion but did not work for me.

I want to be able to have the user go to the previous scene if the user is at the beginning of a scene and he/she presses the left arrow key. Any suggestions.

KimberlyH
03-21-2002, 01:11 PM
Would it be possible to send your demo so I can see how it is set up? If the demo is under 2 megs in size you can zip it up and attach it to a posting in this community. If the file is larger than than you can upload it to our ftp server at: ftp://ftp.installshield.com/incoming

Username: anonymous
Password: your email address

Once you have uploaded the file, post a message letting me know it is available and the filename.

I look forward to hearing from you.

All the best,

Ambassador Kosh
03-21-2002, 05:14 PM
Originally posted by KimberlyH
Would it be possible to send your demo so I can see how it is set up? If the demo is under 2 megs in size you can zip it up and attach it to a posting in this community. If the file is larger than than you can upload it to our ftp server at: ftp://ftp.installshield.com/incoming

Username: anonymous
Password: your email address

Once you have uploaded the file, post a message letting me know it is available and the filename.

I look forward to hearing from you.

All the best,

Here is the demo. I trimmed down most of the scenes so I can post here. Thanks Kim!

Ambassador Kosh
03-22-2002, 10:49 PM
Kim,

After some serious thought and hard thinking I found the answer to my Go To Previous Scene problem.

Here is what I did.

1. Created an event object that initially is DISABLED with a custom condition. (00 Variable State)
2. Created a variable with an initial value of 1 (Variable In Scene X) x = the scene number
3. Created an event object that enables the DISABLED 00 Variable State 1 second into the scene
4. The left key not only causes the scene to go to the previous jumpmark but also triggers the 00 Variable state event to see if the variable is set to 2

Here are the conditions. If the scene variable = 2 it causes a Go To Previous Scene, reset the variable and DISABLE the 00 Variable State. If not do nothing.

Then I thought, well, what if the user decides to jump forward and bypass the setting of the variables?
I inserted a Goto Next Scene Event that resets the variable and DISABLES the 00 Variable State Event). Pretty sneaky ah? Well, no one came to the rescue so I had to improvise. I hope this helps someone who may need it in the future. Thanks for your suggestions. They did help. Looking back at the suggestion it was right there except the Set the Life Properties so the Object will stay on scene only for a specific portion of time was changed to set initial state of object to disable. THANKS! Pablo.

KimberlyH
03-25-2002, 04:11 PM
I took a look at the demo you sent previously and found another way of allowing the user to go back to the previous scene if they are at the beginning of the scene.

You can create a duplicate of the HotSpot you are using to perform the Go To Previous/Go To Next Jumpmarks.

Then, assign one of them to have life properties within the start of the scene to the first jumpmark assigned. For example, the start of the scene would be 0.0 seconds and if the first jumpmark assigned starts at 8.0 seconds, you could assign the life properties to look something like this:

Start: 0.0
Hold: 2.0
End: 7.9
Exit: 7.9

Then, in the other HotSpot, have the start time begin at 8.0 seconds.

In the first HotSpot, instead of using a Go To Previous Jumpmark action for the left arrow, assign a Go To Previous Scene action.

What this will do is, if the user is in the first 8 seconds of the scene and they want to go back, they can select the left arrow and it will trigger the Go To Previous Scene action. If they let the scene go beyond the 8 seconds, the second HotSpot will now be active and then left arrow will instead trigger the Go To Previous Jumpmark.

I hope this helps.