home *** CD-ROM | disk | FTP | other *** search
- u
- M O R E A B O U T S C H O T Z
-
- by Dave Moorman
-
-
- Last month, we ran out of space,
- so I did not get a chance to tell you
- much about SCHOTZ.
-
- First of all, since several asked:
- The animation is by Yours Truly. I am
- still working on a good way to do
- animation on the C-64. The results
- should be in an upcoming issue.
-
- But back to the game itself.
- Changing the game play is extremely
- easy. The relavent information for
- each level is tucked away in an Edstar
- file, and you can edit it to your
- heart's content.
-
- Use Edstar or Mr. Edstar to take a
- look at "SCHOTZ.GAM". Each section has
- a title with a "/" before the name:
-
- /IdioT
-
- Each regular round begins with an "\"
- (English Pound), followed by the
- controls for that round.
-
- \
- r2
- t500
- l3000
- m1
-
- You can include any or all of these
- controls in each round. They don't
- even have to be in order. If a control
- is used, the value is changed.
-
- "r" is for Random -- the number of
- colors the round will display.
-
- "t" is for Time -- the time between
- each new row of blocks, measured in
- jiffies (1/60th of a second).
-
- "l" is for Length -- the time the
- round lasts, again in jiffies.
-
- "m" is multiplier -- the value each
- removed block is worth, and the value
- of each empty space at the end of a
- Successful round.
-
- At the end of each round is a WALL
- -- indicated in the GAM file with "^"
- (Up Arrow). The next line gives the
- extension of the predesigned Wall
- files: ".w01" will load "SCHOTZ.W01",
- etc.
-
- What you might want to do is save
- "SCHOTZ.GAM" to another filename, then
- redesign the game to your liking. If
- you want to try all the Walls without
- clawing through the regular rounds,
- you can do this:
-
- /WallaH
- \
- r1
- t600
- l600
- m0
-
- I am not sure, but I [think] that
- one regular round must be played
- before any Walls. But after that
- initial round, the Walls can come
- right after each other.
-
- ^
- .w01
- ^
- .w02
- ^
- .w03
-
- and so forth.
-
- The Run It file is SCHOTZ.MAK,
- which I used to create the Walls. Run
- it, and press the key for the X-
- coordinate (1-9,A-C), press the key
- for the Y-coordinate (1-8), then press
- the key for the color (1-5).
-
- Each time you add a color, all the
- spaces above are pushed up if
- possible. So the trick is to create
- the Wall from the bottom. Designing a
- Wall that is possible to completely
- remove is very difficult. If you get
- some that work, send them to us. We
- will run an UP-AGAINST-THE-WALL
- special!
-
- Oh, yes -- you can Remove a
- mistake by pressing <RETURN> then
- pressing <1>. The Wall will return to
- the position before the last number
- was added. You can Remove all the way
- back to an empty wall, since every
- input is recorded and saved with the
- file.
-
- Saving and Loading are also
- accessed by pressing <RETURN>,
- followed by the associated number. To
- exit the program, just Break out.
-
- SCHOTZ.MAK is Q&D, but
- serviceable. Name your Walls
- "SCHOTZ." + a three character code.
- Use the dot-three character code in
- SCHOTZ.GAM to include your wall in the
- game.
-
-
- [TECHNO-BABBLE]
-
- The major challenge with Schotz
- was to have the computer figure out if
- three or more blocks were touching
- each other. The only way I could think
- to do this is to use a recursive
- routine.
-
- Recursive programming is different
- than our normal looping. It is
- something like the girl on the Morton
- Salt box, holding a Morton Salt box,
- which has a girl on it holding a
- Morton Salt box -- and so on to (in
- theory) infinity.
-
- What was needed for SCHOTZ was a
- routine that looked around the clicked
- block. If the same color was not
- found, the search would continue until
- all four blocks were checked. So far,
- so good, right?
-
- But when the same color block is
- found, the information about which
- block you are checking and how many of
- the four adjoining blocks have been
- checked is stuffed into a stack. You
- may remember that a stack is First
- On/Last Off, or FILO. Data is stored
- like one would stack dishes, putting a
- new one on top, then -- later --
- removing the dishes from the top down.
-
- This technique uses and reuses
- subroutines to do the same action over
- again. But the subroutines get stacked
- up in the process.
-
- Here is a Basic example of
- Recursion:
-
- 10 REM RAISE 5 TO THE POWER OF 3
- 20 N = 5:P = 3
- 30 GOSUB 100
- 40 PRINT A
- 50 END
- 100 IF P = 0 THEN A = 1:RETURN
- 110 P = P - 1
- 120 GOSUB 100
- 130 A = A * N 140 RETURN
-
- Now this is absolutely clear as mud.
- I suggest you print it out and
- carefully check it by hand.
-
- Remember, every time you GOSUB,
- the location where the program will
- return is stuffed into the stack, and
- when RETURN is encountered, those
- locations are removed from the stack
- in the opposite order they were put
- in.
-
- DMM
-
-