<

LESSON 4 - Part 2:  Randomizing Events

Wrapping Things Up (continued)

The line you added (#11) should look like this:


Fig. 2.42

Go to Line #7 and change the returns to 11/Error, and then rewrite. Your behavior should look exactly like mine:


Fig. 2.43

We are now completely done with our object, so once again …

Time To Test

When testing, try the object out in as many different houses as you can, having each family member take a turn at the object. Make sure that all events are randomizing at some point. Sometimes you will get the same event 2 times in a row, and it is also possible (but should not happen) to get the same event several times in a row. The more events we have to randomize, the better the object will behave.

After testing, if the object works like it is supposed to, save a copy to your holding folder. Do not forget to do this, because once we begin our assignment and class project, your object will be overridden.