home *** CD-ROM | disk | FTP | other *** search
- _______________________________________________________________________________
- _ _ _ _
- ((___)) ((___))
- [ x x ] cDc communications [ x x ]
- \ / presents... \ /
- (` ') (` ')
- (U) (U)
-
- APPLE SHAPE TABLES
- (a short introduction)
-
- by The Dark Static
-
- >>> A CULT Publication......1988 <<<
- -cDc- CULT OF THE DEAD COW -cDc-
- _______________________________________________________________________________
-
-
- What shape tables are:
-
- Shape tables are a series of numbers in a binary location that define a
- certain shape. They can either be POKEd into memory, or can be BSAVED. You
- can program a shape table either from the monitor (call -151) or from BASIC.
- The first few addresses of that area define the table itself.
-
- Enough of that shit, let's get on to something real.
-
- The first thing you have to do, is let your computer know where this shape
- table is stored. Here's how you do this:
-
- POKE 232,X
-
- POKE 233,Y
-
- X and Y can be figured out with a little program. If it is stored at 768
- A popular location then X=0 and Y=3. Most programs (like Blazing Paddles
- and Take 1 have their shape tables stored at 24576($6000)). And if it is
- stored at 24576, then X=0, Y=96
-
- Here is the program to figure out X and Y
-
- 10 SB=INT(AD/256)
- 20 FB=AD-SB*256
-
- Before you run this, set AD equal to the memory address (remember 768 and
- 24576?)
-
- Now do this:
-
- PRINT SB
- PRINT FB
-
- X is equal to FB and Y is equal to SB.
-
-
- o Plotting shapes..
-
- Now...Just do an HGR:HCOLOR=A command and you're ready. To plot a shape, just
- XDRAW A at B,C. A is the shape number, B is the horizontal position of where
- you want the shape to be, and C is the vertical position. To erase this shape,
- just use the same command. XDRAW it over the same B and C position.
-
- Before you do all this, do a ROT=0. This is the rotation of the shape.
- Setting ROT to 0 insures that you have the original shape. Experiment with the
- rotation and change the number in ROT.
-
- If you want to make the shape larger or smaller, do a SCALE=X. In the shape's
- natural position, X is equal to 1. If the shape appears somewhat fucked up,
- then set SCALE to 1. Do not do any decimals...
- That should be it for that.
-
- [Yet another thing I forgot to mention. If you just want to do this in page 1
- graphics (HGR) then read no further, skip to next section.
- But, if you want to plot shapes on page 2 (HGR2) then POKE 230,64. To change
- it back, POKE 230,32]
-
-
- I am now going to end this beginners' introduction, but I wouldn't feel that I
- had helped anyone struggling to learn this fun thing if I didn't at least give
- an example shape to work with. Type in this program and then go back to
- plotting shapes, and see what you can do...
-
-
- o Sample program..
-
-
- 10 HGR:HCOLOR=3:POKE -16302,0:rot=0
- 50 REM vvv poking in shape table setup vvv
- 60 POKE 768,1:POKE 769,0:POKE 770,4:POKE 771,0
- 70 REM vvv poking in shape[square]
- 80 POKE 772,44:poke 773,62
- 90 POKE 232,0
- 100 POKE 233,3
- 110 SCALE=30
- 120 XDRAW 1 AT X,90
- 130 XDRAW 1 AT X,90
- 140 X=X+1:GOTO 120
-
- ===============================================================================
- (c)1988 cDc communications by The Dark Static 2/29/88-42
- All Rights Worth Shit
-
- Downloaded From P-80 International Information Systems 304-744-2253
-