Board logo

标题: [资源分享] SS极密第三方厂商内部展示游戏:3维弹珠球---(附ISO及技术讲解笔记-下载) [打印本页]

作者: 三井    时间: 2013-9-9 22:50     标题: SS极密第三方厂商内部展示游戏:3维弹珠球---(附ISO及技术讲解笔记-下载)

http://115.com/lb/5lbdpkfcddl#
SS Astrocade.zip
115网盘礼包码:5lbdpkfcddl

[ 本帖最后由 三井 于 2013-9-10 11:10 编辑 ]
作者: 三井    时间: 2013-9-9 22:53


Astrocade Demo CD

Programming Document





The following document and the accompanying demo product are released by SEGA to its’ game developers as an example of game programming code.  This document and all of the accompanying product are considered the property of SEGA Enterprises, Ltd. (Sega of America, Inc.).  Only those individuals or companies who have signed the proper Non-Disclosure Agreement(s)  with SEGA Enterprises, Ltd. have the right to view its’ contents.  Use or viewing of these documents by any who do not have the proper Non-Disclosure Agreement(s) signed with SEGA Enterprises, Ltd. is strictly forbidden.

The files which are meant to accompany this document may be used and distributed freely by any developers who have the proper documentation signed by SEGA as mentioned above.  These files contain program code which may be used as part of the development process by SEGA game developers provided that the disclaimer information in ALL of the files remain intact.  These files must not be assumed to be error free, as they have not been properly tested by SEGA.  If any of these files are used by a developer, that developer assumes full responsibility for their accuracy and correctness.  The concept of the Astrocade game, being separate from the program code, may not be used by any other developer without the expressed written consent of SEGA Enterprises, Ltd.  All files and demos contained herein are copyright Sega Enterprises, Ltd., © 1995.













I.   INTRODUCTION

A.  Overview of Astrocade

Astrocade is a demo game created for the SEGA Saturn game platform by our in-house team of programmers, artists, and sound engineers.  It was created in order to better facilitate the game design and coding process.  It is our intent with this demo game to significantly lower the learning curve faced by programmers new to the SEGA Saturn game platform.  To those ends, we have attempted to make this demo as complete and whole as possible.  It provides examples of SEGA Saturn game graphics, sound, and program code which initializes the system, including all chips, then jumps into the main game code.
Also included with Astrocade are the Makefiles necessary for rebuilding the demo.  These Makefiles are intended for use with GNU make.  At present, they will produce a .SRE file and .COF file as output.  However, this file is not downloadable to a Development system through the Hitachi E7000 ICE or EVA, or CartDev without a CD emulator.  This is due to the fact that Astrocade is set up for disk access (for various graphics and sound files) and requires the use of a CD emulator, such as VCD.
Even if you do not have a CD emulator, the Astrocade code should be of great use to any new developer starting out on Saturn.  Instructions for rebuilding the .SRE file  and .COF file are included in a later section of this document.  Also included with Astrocade, are the necessary files for using VCD, or “Virtual CD”.  VCD is a hardware CD emulator which will allow your PC to emulate the CD through the use of your hard drive or to produce a disk image that can be used to burn a playable Saturn CD of the Astrocade demo game.

B.  Portions of the Saturn System Utilized by Astrocade

There are many areas of the Saturn system that are utilized by Astrocade, conversely, there are many areas that are either not utilized, or are not fully utilized.  All of the code is executed by the master SH2 CPU.  It initializes a majority of the system, including both VDP’s, the CD subsystem, the SCU, and the sound subsystem.  Most of the graphics on the screen are produced by VDP1.  Polygons were used for the drawing of the polyhedron that defines the game world (a rhombicuboctahedron).  VDP2 is initialized, but used very little.  It is used to the extent that one background screen displays the score and the number of balls. and one background screen is used to display a bit mapped picture of space.  However, this is the tip of the VDP2 iceberg.  None of VDP2’s special features are used, such as translucency, rotational backgrounds, etc.
The SCU in the system is also initialized, but again, is not completely used.  The Digital Signal Processor (DSP) in the SCU, by far its’ greatest feature, does not execute code - it remains idle.  The slave SH2 also remains idle.  In fact, many games so far have not used the slave SH2 for two basic reasons.  First, the extra CPU is unnecessary for many games.  Second, using the slave SH2 means dealing with bus contention.  Bus contention is not a great obstacle, but if the CPU is not necessary for a game, why deal with it?  The SMPC is set to direct mode, whereby the SH2 CPU can access peripheral data directly by polling the ports.  The SMPC control mode, whereby the SH2 simply gets the data from the SMPC when the data is ready, would save the CPU some extra time, and in future versions of Astrocade, we will be incorporating the Saturn Universal Driver which utilizes the SMPC control mode.  The Saturn Universal Driver is not required to be in every game, but is an example of how to implement an SMPC driver.  Please be aware, however, that SEGA will NOT accept games that use SH2 direct mode.  The SH2 direct mode is meant to be used as a means of making the development process easier when beginning to develop a game.














































II.  Producing a Playable File

A.  How to Build a Downloadable File

After copying the contents of the directory ASTRO from the CD to your hard drive, you should have a directory structure as laid out in Appendix A of this document.  Before going any further, install the GNU compiler and tools to your hard drive.  Make sure to install it exactly as laid out in the read.me file contained in the main GNU directory.  Once this is done, make sure that the machine.h header file is placed in the directory GNU\INCLUDE\MACHINE. and that the GNU\INCLUDE directory is pathed in your AUTOEXEC.BAT file.  The file machine.h has been included with the Astrocade demo, in the ASTRO\INCLUDE directory, so place it with your copy of GNU.
Once GNU and Astrocade are copied to your hard drive, all that should need to be done in order to build the demo is to type MAKENEW from the main directory of Astrocade.  Makenew is a batch file that will perform a “make clean” in each directory to delete all of the object files, then perform a “make” in that directory to recompile each of the files.  Each of the directories making up Astrocade is built into a library and placed in the ASTRO\LIB directory.  After all of the libraries have been built, they are linked with the main routine code to form the main executable code.  When a “make clean” is performed, all of the old libraries are removed using RM.EXE.  If you do not have a copy of RM.EXE, then go into each of the directories and edit the makefiles so that they are using DELETE instead.
The output from running MAKENEW will be PBALL.SRE and PBALL.COF.  As mentioned before, this file will not properly download to your Development System through a Hitachi E7000 ICE or EVA.  Because it is designed to work with a CD emulator, the .SRE file must be converted to a binary file.  The DOS utility SRETOBIN.EXE (including the source code for that tool) has been provided in the tools directory.  Other necessary .BIN files are IP.BIN in the BUILD directory and several sound and graphic binary files that have been placed in the SG\BIN directory.
If you are using a CartDev development system, the .COF file must be downloaded through the CartDev system when emulating the CD.  For information on how to properly emulate the CD using CartDev, refer to the file VCDGuide.Doc in the file VCDTOOLS.ZIP.  This zip file can be found either on the DTS BBS or on the latest DTS CD.
















III.  ASTROCADE CODE

A.  Where to Look to Get Started

The ASTRO directory is divided into several subdirectories.  The GLOBAL directory contains several global makefiles that all of the other makefiles depend on when making.  The include directory contains all of the header files used by Astrocade, except for machine.h and other header files that are more specific to GNU.  If you don’t have machine.h, or have a version that is earlier than that provided with the Astrocade demo, then copy the machine.h file from ASTRO\INCLUDE to your GNU\INCLUDE\MACHINE directory.  To ensure that you don’t run into any unnecessary problems, make sure that you only have one version of machine.h on your hard drive.  The LIB directory is where all of the libraries used by Astrocade are placed, including  libraries from Sega of Japan, found in the subdirectory SOJLIBS.  The SCDATA directory contains all of the background art files, including fonts, and SOUNDATA contains all of the sound files.  VCD is used to house all of the necessary files for and the files output by Virtual CD, the CD emulator.
The remainder of the directories are for various components of Astrocade.  Each of them are individually compiled into libraries, then linked with the main routine to form the executible.  The main code routine is in the PMAIN directory.  This directory contains all of the code for the game mechanics, such as routines for movement of the ball, updating of score, collision detection, etc.  PMAIN.C holds the main program loop that is jumped to after the main( ) routine (in BUILD directory) is finished initializing the system.

B.  Components Making Up Astrocade

Astrocade is made up several different components which, in effect, manage a particular function or area of code.  This is by no means a complete list of all components.  Rather, it is a list of those components which would probably be robust and suitable enough to be used as actual code in game development.  The areas which fit this description are the memory manager, low level math routines, 3D rendering code, the texture and palette manager, and the gouraud shading table manager.  These components can be used freely within games being developed, as long as the developer complies with the above disclaimer notice.  Each of the components will be described  in the section that follows.  If any files in this demo are deemed suitable for purposes required by your project, please feel free to use them, provided that the disclaimer information contained at the top of each file is maintained.  Astrocade was designed in such a way that much of the code can easily be redesigned to fit the task that you have in mind.
Astrocade's memory manager is rather sophisticated for a gaming environment.  The memory manager essentially divides the Saturn's RAM into a number of heaps (VDP1 VRAM, VDP2 VRAM, WRAM, etc.), and provides basic memory allocation and deallocation services.  Since the memory manager returns handles (pointers to pointers) instead of single layer pointers, the memory manager can also defragment its heaps (you have to ask it to perform the defragmenting function).  The routine for defragmenting the memory is StMemDefrag ( ) in MEM\stmem.c.  How the memory manager works will be described in a later section of this document.
When Astrocade isn't using integers, it is using 16.16 fixed-point numbers.  This format is attractive, since the SH2 can multiply such numbers quite efficiently, and the format is sufficient (barely) for Astrocade, but it may come up short on both range and precision for projects that wish to live in a larger world than is required to house a rhombicubeoctahedron.  At any rate, we have efficient assembly language routines for multiplying, dividing, and taking dot products using such numbers.  We also have some table-driven trig functions and an integer square root routine which, with a little shifting, can be used with fixed-point numbers.
Astrocade uses a reasonably general-purpose 3D engine which supports a proprietary format for representing 3D models in a Saturn-friendly manner.  As yet, we have no working 3D modeling tools that support this format.  The code allows models to be translated, rotated, and scaled, and transformations may be composed with one another.  Either back-face or front-face culling may be performed.  Each face can be either textured or non-textured, and paletted textures may be freely mixed with RGB textures.  Shading is supported using a simple lighting model, and each surface can individually select either Gouraud shading or flat shading.  The data structures were designed with heirarchical modeling in mind, but hierarchical modeling is not currently supported.
Astrocade also has facilities for keeping track of textures and palettes, and for getting them into and out of VRAM and color RAM.  Using the memory manager, it is fairly easy to construct a scheme in which textures are automatically copied to VRAM as they are needed, and purged when they are no longer being used.  The palette manager supports color cycling, and it can dynamically create extra copies of palettes, which can be useful when you want to shade a model that's covered with paletted textures, in which case each face of the model needs to have its own private copy of the palette.  The palette manager can also apply RGB offsets to the palette of your choice, which is useful for both shading and highlighting of paletted textures.  There are also facilities to support palette animation, which can be tricky, since the VDP1 frame buffer is double-buffered, but color RAM isn't.  The data structures support both 15-bit and 24-bit palettes, but the current code only supports 15-bit palettes.  In theory, the code also supports VDP1 CLUT’s (Color Look Up Tables), but this feature has never been tested.
The Gouraud shading table manager uses the memory manager in order to allocate enough space in VDP1 VRAM for Gouraud shading tables, and to make it easier to link those tables to the VDP1 command tables that use them.  This module is used by the 3D rendering code to keep track of any Gouraud shading tables used by the faces of a 3D model.

C.  Overview of Main Code

The main( ) routine is in BUILD\main.c.  This routine calls all of the routines necessary for initializing all of the other chips in the system.  First, it calls SCUInit( ) to initialize and set up the SCU chip.  It then calls the two routines VDP1Init( ) and VDP2Init( ).  These routines initialize the VDP chips in the system, and set up the various modes of the system;  For instance, the resolution, NTSC vs. PAL, interlace settings, etc.  Main( ) then calls SpritePriorInit( ) and ScrollPriorInit( ), which set the sprite priority registers and scroll priority registers, respectively.  If the box it is being run on is a Small Graphics Box, it will then call the routine SCSPInit( ) to initialize the sound chip.  InitTimer( ) is called to jump start the SH2’s chip resident Free Running Timer and set_imask( ) is called to enable the interrupts with an interrupt level of 0.  Main( ) then calls PMain( ) to begin the game loop.
The SCUInit( ) code is pretty straight forward.  It simply clears the SCU System Register data structure that will be loaded into the SCU registers after dumping the necessary initialization values into it.  The routine then masks the Sprite Draw End, Vblank In, and Vblank Out interrupts in the SCU System Register data structure.  This data structure is then copied into the addresses of the true SCU System registers through the LoadSCUSysReg( ) function. Control is then returned to main( ), where VDP1Init( ) is called.
The VDP1Init( ) routine is in the file VDP1\VDP1Init.c.  This routine begins by disabling the interrupts through a call to the function set_imask( )  (defined in machine.h).  A register structure is then filled with VDP1’s settings, and setVDP1Reg( ) is called to empty the contents of the register structure into the first six registers within the VDP1.  The registers being set are the TV Mode, Frame Buffer Change Mode, Plot Trigger, Erase\Write Data, Erase\Write Left Coordinate, and the Erase\Write Right Coordinate registers.  The TV Mode register is set to 0, which sets the system to NTSC, non rotation, and a bit depth of 16 bits per pixel (Page 36, VDP1 User’s Manual).  The Frame Buffer Change Mode register is set to single interlace, and the FCM and FCT bits set the frame buffer change mode to manual change (Page 38, VDP1 User’s Manual).   The Draw Trigger Mode register is set to 01b, which activates the drawing of the VDP1 command table (Page 44, VDP1 User’s Manual).  The remaining three registers (EWDR, EWLR, EWRR) are all initialized to zero (Pages 45 & 46, VDP1 User’s Manual).
The next routine called by VDP1Init is a call to InitVDP1VRAM( ).  This routine begins by setting the END bit in the VDP1 command table (Page 68, VDP1 User’s Manual).  After this, the InitVDP1VRAM( ) routine initializes both frame buffers to all zero’s and returns.  VDP1Init( ) then sets up clipping and reenables the interrupts.  Control is then returned to main( ), where VDP2Init( ) is called.
The VDP2 chip is much more complex than VDP1, so quite a bit more is involved in initializing VDP2.  VDP2Init( ) begins by initializing the TV screen mode,  setting the TVMD register to enable the display, initializing the display to black, and setting the resolution to 320 x 224 (Page 16, VDP2 User’s Manual).  The routine then enables two background screens, NBG0 and NBG1, by setting the least significant bits of the BGON register (Page 48, VDP2 User’s Manual).  SetScreenFunc( ) sets the background screen NBG0 to 256 color palette, using a character size of 2 x 2 cells, and sets the remainder of the scroll screens (including the rotational scroll screens) to zero (Page 60, VDP2 User’s Manual).  For both scroll screens, the pattern name data size is set to 1 word and character numbers are set to 12 bits, disallowing the use of the special flip function bit (Page 76, VDP2 User’s Manual).  The scroll screen plane size control register is then set to 1 page x 1 page.  The Map Offset Register is initialized to a value of three.  This number is added to the highest six bits of the NBG0 and NBG1 Map registers, which are set to 2020H.  All other Map Offset registers and Map registers (for the remaining scroll and rotation screens) are set to zero (Pages 85 - 90, VDP2 User’s Manual).  The SetScreenFnc( ) routine ends by initializing the Bit Map Palette Number registers to zero (since we’re using cells),  the Screen Over Pattern Name registers to zero (since we’re not using rotational scroll screens), and the Mosaic Control register to zero, disabling mosaic effects.
SetCRAMMode( ) sets the Color RAM to 5 bits for each of RGB for a total of 15 bit color, and 2048 total colors(Page 45, VDP2 User’s Manual)..  Color RAM is then initialized to all zero’s.  SelectWindows( ) is then called and windows W0 and W1 are set to 0.  The functions SetVRAMUsage( ) and ClearVRAM( ) are then called to set the VRAM access and intialize the VRAM.  The VRAM access is set to:

Access Timing
        T0        T1        T2        T3        T4        T5        T6        T7
For VRAM A0        2        3        2        3        1        1        1        1
For VRAM A1        3        3        3        3        1        1        1        1
For VRAM B0        4        5        4        5        1        1        1        1
For VRAM B1        5        5        1        1        1        1        1        1




Where entries are defined as:        1:  No Access
                                        2:  NBG0 Character Pattern Data Read
                                        3:  NBG1 Character Pattern Data Read
                                        4:  NBG0 Pattern Name Data Read
                                        5:  NBG1 Pattern Name Data Read

BackScreenInit( ) sets the back screen to single color 0 (Page 176, VDP2 User’s Manual), then ScrollZoomInit( ) sets the increment control registers to 1 (normal display) and sets the Screen Scroll Value registers to 0 (Pages 123 and 127, VDP2 User’s Manual).
The function SpritePriorInit( ) sets the Sprite Priority Number registers to 0505H.  We give all of the sprites the same priority, leaving the priority roughly in the middle to allow the setting of some backgrounds to be a higher priority (Page 209, VDP2 User’s Manual).  ScrollPriorInit( ) is called next, setting the priority of NBG0 and NBG1.  We have set NBG0 to three so that it will show up behind the sprites (the polyhedron) and NBG1 to seven, since this screen will display the score and other stats over the top of the polyhedron.  The remainder of these Priority Number registers are set to zero, so that they will be treated as transparent, and will not be displayed.
The last two items to be called before entering the meat of the code are InitTimer( ) and set_imask( ).  InitTimer( ) sets up the INTC and loads the _timerHandler into the vector table.  It then clears the counter and status, and enables the overflow interrupt.  The function set_imask( ) is called again to reenable the interrupts.
At this point, PMain( ) is finally entered.  There is still a great deal of initialization that needs doing.  First, STMemReset( ) is called to initialize the memory manager.  Next, the Global File System (or GFS library component) is initialized.  The GFS library is a layer which the programmer can interact with, that lays on top of and uses the CDC layer (or the CDC library).  The documentation for the specifics of the GFS library is contained in the document titled Program Library User’s Guide 1 - CD Library (Document #ST-136-R2-093094). The documentation for the specifics of the CDC library is contained in the document titled System Library Userís Guide (document #ST-162-062094).  Both of these documents should be in your Saturn Programmer’s Guide binder.  After the file system is initialized, SCSPInit( ) loads and initializes various sound effects data, while GouraudInit( ) initializes the Gouraud shading table heap and downloads the default, color neutral shading tables.
Init3D( ) then resets the global properties of the three dimensional environment.  The function InitLighting( ) is called to initialize the global lighting model, which is made up of a single infinitely distant light source.  The source has a direction and an intensity.  There is also a source of ambient light with only intensity.  Because intensities are really RGB offsets, these sources also have color.  Next PMain( ) installs Astrocades’ library of target types by calling the function InitTargets( ).  Once done, the various texture maps and fonts are loaded.
Beyond this point, the programmer is left to get his hands dirty.  By now, the system has been initialized, most of the Astrocade structures have been set up, fonts have been loaded, etc.  We’re now into the more Astrocade-specific code that will set up the polyhedrons, shooter mechanics, and so forth.  From there, the main game loop is entered and the game begins.

D.  Overview of Astrocade’s Memory Manager

The memory manager provides basic memory management services for all of the RAM and VRAM that is mapped into the SH2’s address space.  Separate heaps are allocated for VDP1 VRAM, VDP2 VRAM, WRAM, etc.  The memory manager assumes that the Gouraud shading tables are placed at the top of VRAM, rather than being placed in Color RAM (an option of VDP1).  Because they are assumed to be at the top of VRAM, Gouraud shading tables are given their very own heap at the top of VDP1 VRAM.  Placing the tables in VRAM avoids much of the fragmentation that could occur if large textures and the small Gouraud shading tables are allocated and deallocated throughout VRAM.
Within these heaps, blocks of any size can be allocated and deallocated, and, since the memory manager returns handles (pointers to pointers) instead of single layer pointers, it can transparently relocate memory blocks in order to defragment its’ heaps.  In order for it to do this, though, it must be requested.  Blocks may also be flagged as non-movable, a feature useful when different blocks contain pointers to each other, as is the case with various VRAM tables.
One warning that should be noted about the memory manager used in Astrocade is that it is assumed that the global symbol “stack” refers to the first unused location after the end of your program.  In order to prevent the memory manager from allocating the memory that your program already occupies, you must either link your code so as to follow this convention, or figure out for yourself how much WRAM your code is using, and allocate it immediately after resetting the memory manager.
The memory manager uses a few data structures to track the use of memory.  An array is declared to be of size MAXBLOCKS, which is a constant set to the number of total blocks in the system (to include the blocks from each of the heaps).  Each position in the array is a structure with fields for its’ address, size, next and previous blocks, next and previous free blocks, etc.  There are then three more arrays declared to be of size NUMHEAPS.  This constant is set to four in Astrocade’s case, because it sees VDP1 VRAM, VDP2 VRAM, WRAM, and the special area designated for the Gouraud shading tables as the various heaps of the system.  The three arrays point to the first block (or base address), first free block, and last free block, of each of the heaps.  Allocation and deallocation of memory requires the incrementing or decrementing of the proper array fields, and a resetting of a blocks’ pointers to the next free block.
























IV.  HOW TO GET SUPPORT

If you have any questions or comments about this code, or any other support issues, please contact SEGA Developer Technical Support.  To contact us please use our internet EMail address if possible:  dts@segaoa.com.  If EMail is impossible, our phone number is (415) 802 - 1719, or to fax use (415) 802 - 1717.  When contacting us, please specify the platform, your name, company’s name, phone and fax numbers, and a description of the problem or question.  The dispatcher who receives your message will pass it along to one of the support engineers who will contact you for further information if necessary.  Developer Technical Support can be contacted between the hours of 9:00 a.m. and 6:00 p.m., West Coast time.  If you are requesting documents, please E-mail your requests to DTS at the above Email address.  Please include the Manual name (or Document name and number), first and last Name of the person to receive the manual, project name (game name) and company Name, full shipping address and a phone contact at your company.






































APPENDIX A

DIRECTORY AND FILE STRUCTURE OF ASTRO


ASTRO                                                               
                                                                       
                                                                       
                 Makefile                                                -- Makefile for building Astrocade demo
                 MakeNew.Bat                                        -- Batch file for making entire demo
                                                                       
                  DOCS                                               
                                 Astro.Doc                                -- Microsoft Word for PC v6.0 version of this document
                                 Astro.Txt                                -- Ascii text file of this document
                                 Astro.Mac                                -- Microsoft Word for Mac v6.0 version of this document
                                 AstroArt.Doc                        -- MS Word for PC document describing art development for Astrocade
                                 AstroArt.Txt                        -- Ascii text file of AstroArt.Doc document
                                 AstroArt.Mac                        -- MS Word for Mac document describing art development for Astrocade
                                                                       
                  3DMODEL                                               
                                 Makefile                                -- Makefile for building 3DMODEL directory of Astrocade
                                 3DModel.C                                -- 3D modeling engine
                                                                       
                  BUILD                                               
                                 Makefile                                -- Makefile for building Astrocade
                                 MK.Bat                                -- Creates map file for Astrocade
                                 PBall.Bin                                -- binary file of Astrocade code
                                 Main.C                                -- Main program code.  Initializes system, then jumps to pmain (main loop).
                                 PBall.Map                               
                                 Entry.S                               
                                 Header.S                               
                                 Stack.S                                -- Sets up program stack
                                 PBall.Sre                                -- File produced when demo is "Made".  This file downloads to Hitachi ICE.
                                 PBall_S.X                               
                                 Cart_Sre.X                               
                                                                       
                  GLOBAL                                               
                                 Global.Mk                                -- Makefile with global variables.  This is included in all the other makefiles.
                                 Global.Pat                                -- Makefile Pattern Rules
                                 Global.Sfx                                -- Makefile Suffix Rules
                                                                       
                  INCLUDE                                                -- INCLUDE FILES FOR ASTRO.  DESCRIPTS ARE LISTED FOR NON-OBVIOUS ONES.
                                 Astro.Def                               
                                 Global.Equ                                -- Global equates.  Settings for target box type, etc.
                                 SPCMD.Equ                                -- Global Sprite Command table equates
                                 Stack.Equ                                -- Header file for BUILD \ Stack.S
                                 SysInt.Equ                                -- Equates for various interrupt levels
                                 TQueue.Equ                        -- Equate file for Task Queue support
                                 VDP1.Equ                                -- Equate file for VDP1 IC
                                 3DModel.H                                -- Definitions for 3d Models
                                 DBugVars.H                        -- Global Variables Used for Debugging
                                 Font.H                                -- Font Declarations
                                 GeoUtil.H                                -- Geometric Utilities Header File
                                 GFS_Buf.H                                -- Supporting Header Files for GFS Library
                                 GFS_CDB.H                                               |
                                 GFS_CDC.H                                               |
                                 GFS_CDF.H                                               |
                                 GFS_DEF.H                                               |
                                 GFS_DIR.H                                               |
                                 GFS_MMB.H                                       |
                                 GFS_MMC.H                                       |
                                 GFS_MMF.H                                       |
                                GFS_SCSI.H                                               |
                                 GFS_SF.H                                               |
                                 GFS_TRN.H                                              V
                                 Gouraud.H                                -- Definitions for Gouraud Shading
                                Pad.H                                        -- Definitions for Direct and Indirect Mode on SMPC
                                 PalClut.H                                -- Header File for Palettes and CLUT's
                                 PTex.H                                -- Constants used for various texture ID's
                                 Sat2.H                                -- SAT2 related definitions
                                 SCSP.H                                -- Header file for Saturn Custom Sound Processor
                                 SCU.H                                -- Definitions required for System Control Unit
                                 Sega_CDC.H                        -- Main header files for SOJLIB's
                                 Sega_DMA.H                                       |
                                 Sega_GFS.H                                       |
                                 Sega_Int.H                                               |
                                 Sega_Per.H                                               |
                                 Sega_Sys.H                                       |
                                 Sega_XPT.H                                      V
                                 SHMath.H                                -- Macros and definitions for math functions
                                 SHTypes.H                                -- Platform specific definitions and typedefs
                                 SMPC.H                                -- Header file for System Manager & Peripheral Controller
                                 Snd_Main.H                        --
                                 Sp.H                                        -- Sprite Command Table declarations
                                 SPCMD.H                                -- Sprite Command Table definitions
                                 Stack.H                                -- Definitions for size of stack
                                 StMem.H                                -- Header file for Saturn memory manager
                                 SysInt.H                                -- Definitions for various interrupt levels
                                 Texture.H                                -- Definitions and typedefs for Texture.C
                                 Thread.H                               
                                 Timer.H                                -- Allows access to Timer.S
                                 TQueue.H                                -- Header file for simple task queues
                                 Util.H                                        -- Declarations for various utility routines
                                 VBlank.H                                -- VBlank header file
                                 VDP1.H                                -- Header file for VDP1 IC
                                 VDP2.H                                -- Header file for VDP2 IC
                                 VectUtil.H                                -- Vector utilities header file
                                     SH2                                -- SH2 specific files
                                                 Except.Equ                -- Equate file for SH2 Exception Processing
                                                 Frt.Equ                -- Equate file for SH2 Free Running Timer
                                                 IntC.Equ                -- Equate file for SH2 Interrupt Controller
                                                 DMA.H                -- Header file for DMA Controller (DMAC)
                                                 Except.H                -- Header file for SH2 Exception Processing
                                                                       
                   LIB                                                       
                                 Lib3D.A                                -- Libraries created by respective directories
                                 LibMem.A                                               |
                                 LibPBall.A                                               |
                                 LibSCU.A                                               |
                                 LibSND.A                                               |
                                 LibTEX.A                                               |
                                 LibTEXT.A                                               |
                                 LibTQ.A                                               |
                                 LibUTIL.A                                               |
                                 LibVDP1.A                                               |
                                 LibVDP2.A                                              V
                                  SOJLIBS                               
                                                 LibCDC.A                -- CD library interface
                                                 LibCSH.A               
                                                 LibDMA.A                -- DMA library for performing CPU or SCU DMA
                                                 LibGFS.A                -- File System Library
                                                                       
                   MEM                                               
                                 Makefile                                -- Makes this directory into a library called "LibMem.A"
                                 STMem.C                                -- Saturn Memory Manager
                                                                       
                  PMAIN                                               
                                 Makefile                                -- Makes this directory into a library called "PBall.A"
                                 Ball.C                                        -- Routines for ball movement and collision
                                 Bkg.C                                -- Global background functions
                                 Grabber.C                                -- Controls ball Grabber
                                 Icos.C                                -- Routines for building and managing icosahedrons
                                 Levels.C                                -- Transitions and differences between levels
                                 Options.C                                -- Controls options screen
                                 PMain.C                                -- Main game routine that is jumped to after inits
                                 Score.C                                -- Code and data for displaying score through VDP2
                                 Shot.C                                -- Controls shooter mechanics
                                 Target.C                                -- Controls transitions of changing targets after being hit
                                 Ball.H                                        -- Definitions having to do with the ball
                                 Bkg.H                                -- Header file for BKG.C
                                 Grabber.H                                -- Definitions for ball grabber
                                 Icos.H                                -- Structs for hedrons, ball and shooter
                                 Levels.H                                -- Header file for Levels.C
                                 OpFont.H                                -- Font declarations for options screen
                                 Options.H                                -- Header for options driver
                                 PMain.H                                -- Header file for PMain.C
                                 Score.H                                -- Header file for Score.C
                                 ScorFont.H                                -- Score font declarations
                                 Sfx.H                                        -- Definitions for sound effects
                                 Shot.H                                -- Definitions for shooter mechanics
                                 Target.H                                -- Definitions and structs for targets
                                 TARGETS                                -- Definitions for the various targets
                                                 Bumpers.H                               |
                                                 Drains.H                               |
                                                 Kickers.H                               |
                                                 Tetra.H                               |
                                                 Wire.H                              V
                                                                       
                                 MODELS                                -- Model definitions
                                                 Rhombi.H                               |
                                                 Tetra.H                              V
                                                                       
                  SCDATA                                                -- Astrocade artwork
                                 Credits1.All                       
                                 Credits2.All                       
                                 OpFont1.All                               
                                 OpFont2.All                               
                                 Options.All                               
                                 ScorFont.All                       
                                 SegaLogo.All                       
                                 Star1.All                               
                                 Title.All                               
                                 Brip.Log                               
                                 8Fnt_00.Pcx                        -- Options font (smaller)
                                 8Pal_00.Pcx                               
                                 Cred_00.Pcx                        -- Credits screen 1
                                 Cred_01.Pcx                        -- Credits screen 2
                                 GFnt_00.Pcx                        -- Score font (in gold)
                                 OpBk_00.Pcx                        -- Options background 1
                                 OpBk_01.Pcx                        -- Options background 2
                                 SegaLogo.Pcx                        -- Sega's Logo screen
                                 Star1.Pcx                               
                                 Titl2_00.Pcx                        -- Astrocade title screen
                                                                       
                  SCU                                                       
                                 Makefile                                -- Makes this directory into a library called "LibSCU.A"
                                 SCU.C                                -- Routines for configuring System Control Unit
                                 SCUDMA.C                                -- Routines for using SCU's DMA
                                 SCUDSP.C                                -- Routines for using SCU's DSP
                                                                       
                 SOUNDATA                                               
                                 Makefile                                -- Makes this directory into a library called "LibSnd.A"
                                 Snd_Main.C                        -- Routines for playing of sounds
                                 AstroTon.S                               
                                 SData.S                               
                                 PINBALLS                               
                                                 Makefile               
                                                 AstroTon.Bin       
                                                 ClickTra.Bin       
                                                 DSPBank1.Bin       
                                                 AstroMap.S       
                                                 AstroTon.S               
                                                 ClickTra.S               
                                                 DSPBank1.S       
                                                 NewMap.S               
                                                 SdDrv.S               
                                                 Bin.X                       
                                                                       
                 TEXDATA                                               
                                 Makefile                                -- Makes this directory into a library called "LibTex.A"
                                 PTex.C                                -- Installs some textures permanently into VRAM
                                 Astro.Def                                -- Various definitions creating levels and fonts
                                 Level1.Def                                               |
                                 Level2.Def                                               |
                                 Level3.Def                                               |
                                 Level4.Def                                               |
                                 Master.Def                                               |
                                 Level1.H                                               |
                                 Level2.H                                               |
                                 Level3.H                                               |
                                 Level4.H                                               |
                                 Master.H                                               |
                                 Astro.Sct                                               |
                                 Level1.Sct                                               |
                                 Level2.Sct                                               |
                                 Level3.Sct                                               |
                                 Level4.Sct                                               |
                                 Master.Sct                                               |
                                 BALLSHOT                                               |
                                                 GBall.H                               |
                                                                                       |
                                  FONTS                                               |
                                                RGBFont.H                              V
                                                                       
                 TEXTURE                                               
                                 Makefile                                -- Makes this directory into a library called "LibText.A"
                                 PalClut.C                                -- Maintains global list of palettes
                                 Texture.C                                -- Routines for handling textures
                                                                       
                  TOOLS                                               
                                 SreToBin.C                                -- Tool for converting .SRE file to .BIN file
                                 SreToBin.Exe                                       |
                                 SreToBin.Obj                                      V
                                                                       
                  TQUEUE                                               
                                 Makefile                                -- Makes this directory into a library called "LibTQ.A"
                                 TQueue.C                                -- Initializes task queue list
                                 TQEntry.S                                -- Routines for handling simple interrupt task queue list
                                                                       
                   UTIL                                                       
                                 Makefile                                -- Makes this directory into a library called "LibUtil.A"
                                 Font.C                                -- Utilities to load font files
                                 GeoUtil.C                                -- Utilities for performing geometric calculations
                                 GetPad.C                                -- Routines for actually reading the pads
                                 Trig.C                                -- Fixed32 calculations of Sin and Cos
                                 VectUtil.C                                -- Utilities for basic matrix manipulations
                                 Div.S                                        -- Performs 16.16 / 16.16 resulting in 16.16 output
                                 DotP.S                                -- Computes dot product of two vectors
                                 Mem.S                                -- Performs large memory transfers
                                 Mul.S                                        -- 16.16 precision multiplication
                                 Sinc.S                                -- Fixed sine and cosine table searching routines
                                 SqRt.S                                -- Performs square root calculation using square root tables
                                 Timer.S                                -- Initializes and reads Free Running Timer
                                 Vect.S                                -- Sets and retrieves exception handlers
                                                                       
                   VCD                                                       
                                   BUILD                               
                                                 VCD.Bat                -- Batch file for using VCD to create disk image
                                                 IP.Bin                        -- IP file for building or emulating disk;  This is first file loaded from CD.
                                                 PBall.Dsk                -- Astrocade disk image
                                                 PBall.Pre                -- Defines the Script and .RTI files to use for VCD
                                                 PBall.Pvd               
                                                 VCD0000.Qsb       
                                                 Warning.Red        -- Redbook audio track
                                                 PBall.Rti                -- .RTI file produced by VCD tools. This is necessary for the burning process
                                                 PBall.Scr                -- Script file for building Astrocade disk image
                                                                       
                                    SG                                       
                                                 AstroTon.Bin        -- Binary files fo art, sound, etc.
                                                 ClickTra.Bin                       |
                                                 DSPBank1.Bin                       |
                                                 Lev01GFX.Bin                       |
                                                 Lev02GFX.Bin                       |
                                                 Lev03GFX.Bin                       |
                                                 Lev04GFX.Bin                      V
                                                 PBall.Bin                -- binary file of Astrocade code
                                                                       
                   VDP1                                               
                                 Makefile                                -- Makes this directory into a library called "LibVDP1.A"
                                 Gouraud.C                                -- Routines for creating and destroying gouraud shading tables
                                 SP.C                                        -- Sprite management routines
                                 VDP1Init.C                                -- Initializes VDP1 and contains routine for setting up VBlank Interrupt.
                                 VDP1Reg.C                                -- Routines for setting\retrieving VDP1 registers
                                 ClipDat.S                               
                                 Sprite.S                               
                                 VBlank.S                               
                                                                       
                   VDP2                                               
                                 Makefile                                -- Makes this directory into a library called "LibVDP2.A"
                                VDP2Init.C                                -- Initializes VDP2










APPENDIX B

DIRECTORY OF FUNCTIONS


AddMovingTarget (MovingTarget  *mTg, Hedron  *hedron, UInt16  faceLink, UInt16 z);        In PMAIN\target.c
AddRGB (UInt16  base, UInt16  offset);        In TEXTURE\palclut.c; Returns UInt16.
AddRings (Ball *pBall, Int  ringCount, Int  ringPhase);        In PMAIN\grabber.c
AddTarget (Hedron  *hedron, Int16  face, Int16  tgDefIndex);        In PMAIN\target.c; Returns Int16.
AddTaskToQ (TQueue  *q, Function  fnc);        In TQUEUE\tqueue.c
AddTransform (Transform  *trans, TransMatrix  tMat, RotMatrix  rMat);        In 3DMODEL\3DModel.c
AddXRotation (RotMatrix  *ctm, Fixed32  angle);        In 3DMODEL\3DModel.c
AddYRotation (RotMatrix  *ctm, Fixed32  angle);        In 3DMODEL\3DModel.c
AddZRotation (RotMatrix  *ctm, Fixed32  angle);        In 3DMODEL\3DModel.c
AirFriction (Ball  *pBall);        In PMAIN\ball.c
AllocCopyPalette (UInt16  pIndex);        In TEXTURE\palclut.c; Returns Palette *.
AllocModelCopy (Model  *mod);        In 3DMODEL\3DModel.c; Returns Model *;
AllocPalette (UInt16  pIndex);        In TEXTURE\palclut.c
AnimFace (Face  *face, Int16  targ,UInt8  *script, UInt32  *timer, UInt16 tar        In PMAIN\target.c; Returns UInt8 *.
BackFaceCull (Model  *mod);        In 3DMODEL\3DModel.c
BackScreenInit ( );        In VDP2\vdp2init.c
BallDraw (Hedron  *outerHedron, Hedron  *innerHedra, Ball  *pBall, UInt16  level);        In PMAIN\ball.c; Returns UInt16.
BallFaceInit (UInt16  level, Ball  *pBall, Hedron  *outerhedron, Hedron  *innerHedra);        In PMAIN\ball.c
BallGouraudInit (Ball  *pBall);        In PMAIN\ball.c
BallHit (Int16  targ);        In PMAIN\target.c
BallHitHedron (Hedron  *hedron);        In PMAIN\icos.c
BallInit (Ball  *pBall);        In PMAIN\ball.c
BallInitLauncher (Ball  *pBall);        In PMAIN\ball.c
BallInRange (Ball  *pBall, Hedron  *outerHedron);        In PMAIN\ball.c
bg11by1 ( );        In VDP2\vdp2init.c
bg12by2 ( );        In VDP2\vdp2init.c
BkgLoadScroll (Background  *bkg);        In PMAIN\bkg.c
BkgLoadScrollMapTable (Background  *bkg);        In PMAIN\bkg.c
BumpScore (long  amount);        In PMAIN\score.c
CalcFaceNormal (XYZ  *v0, XYZ  *v1, XYZ  *v2, XYZ  *faceNormal);        In UTIL\vectutil.c
CalcHedra ( );        In PMAIN\pmain.c
CheckTetraStates (Hedron  *outer, Hedron  *inner);        In PMAIN\levels.c
CheckVolumeIn (Hedron  *hedron, XYZ  *xformENormals, UInt16  numberFEdges,        In PMAIN\ball.c; Returns Boolean.
               XYZ  point3D, UInt16  faceNum);       
CheckVolumeOut (Hedron  *hedron, XYZ  *xformENormals, UInt16  numberFEdges,        In PMAIN\ball.c; Returns Boolean.
               XYZ  point3D, UInt16  faceNum);       
ChgPan (SndPan  pan);        In SOUNDATA\snd_main.c; Returns UInt16;
ClearScoreBG (UInt16  val);        In PMAIN\score.c
ClearSCUSysReg (SCUSysReg  *SCUReg);        In SCU\scu.c
ClearVRAM ( );        In VDP2\vdp2init.c; Of type static void.
CollisionCheckIn (Hedron  *hedron, XYZ  *o3DPt, XYZ  new3DPt, XYZ  point3DVec);        In PMAIN\ball.c; Returns Boolean.
CollisionCheckOut (Hedron  *hedron, XYZ  *o3DPt, XYZ  new3DPt, XYZ  point3DVec,        In PMAIN\ball.c; Returns Boolean.
               Fixed32  ballRad);       
CompareVectors (XYZ  vector1, XYZ  vector2);        In UTIL\vectutil.c; Returns Boolean;
ConvertScore (long  score, UInt16  *string);        In PMAIN\score.c
CopyColorRAM ( );        In TEXTURE\palclut.c
CopyFace (Face  *srcFace, Face  *dstFace);        In 3DMODEL\3DModel.c
CopyFaceVerts (Face  *srcFace, Face  *dstFace);        In 3DMODEL\3DModel.c
CopyMem (void  *dst, void  *src, UInt32  cnt);        In SOUNDATA\snd_main.c; Returns static void;
CopyModel (Model  *m1, Model  *m2);        In 3DMODEL\3DModel.c
CopyPalette ( UInt16  srcIndex, UInt16  dstIndex);        In TEXTURE\palclut.c
CopyProjVerts (Model  *mod, UInt16  j);        In 3DMODEL\3DModel.c
CopyRotMatrix (RotMatrix  rm1, RotMatrix  rm2);        In 3DMODEL\3DModel.c
CopyTrans (Transform  *t1, Transform  *t2);        In 3DMODEL\3DModel.c
CycleBackward (PalRecord  *palRec, UInt32  palWidth, CycleRange  *cRng);        In TEXTURE\palclut.c
CycleForward (PalRecord  *palRec, UInt32  palWidth, CycleRange  *cRng);        In TEXTURE\palclut.c
DehighlightSetting (UInt16  op, UInt16  setting);        In PMAIN\options.c
DeleteTarget (UInt16 t);        In PMAIN\target.c
DisableGrabber ( );        In PMAIN\grabber.c
Display ( );        In PMAIN\pmain.c
DisplayOptions ( );        In PMAIN\options.c
DistancePtPlane (XYZ  v, XYZ  n, XYZ  p);        In UTIL\geoutil.c; Returns Fixed32;
Div_Fixed (Fixed32  dividend, Fixed32  divisor);        In UTIL\div.s; Returns Fixed32;
DMAClearZero (UInt8  *dst, UInt32  cnt);        In SOUNDATA\snd_main.c; Returns static void;
DoColorCycling ( );        In TEXTURE\palclut.c
DoGlow (Ball  *pBall);        In PMAIN\grabber.c
DoOptionsScreen ( );        In PMAIN\options.c
DoQueue (TQueue  *q);        In TQUEUE\tqueue.c
DoVRAMLoad ( );        In PMAIN\pmain.c
dprintf (Char  *str, FontDesc  *font, UInt16  x, UInt16  y);        In VDP1\sp.c
EnableGrabber ( );        In PMAIN\grabber.c
Entry ( );        BUILD \ entry.s
EvalMoveTargRules (Int16  mTarg);        In PMAIN\target.c
EvalRules (Int16  targ);        In PMAIN\target.c
ExtraBall ( );        In PMAIN\score.c
FaceBallEffect (Ball  *pBall, Int16  targ);        In PMAIN\target.c; Returns Boolean.
FadeIn (UInt32  t);        In PMAIN\pmain.c
FadeOut (UInt32  t);        In PMAIN\pmain.c
FCos (Fixed32  a);        In UTIL\trig.c; Returns Fixed32;
FCos (Fixed32  a);        In UTIL\sinc.s; Returns Fixed32;
FindModCenter (Hedron  *hedron);        In PMAIN\ball.c
FindVert (Model  *mod, XYZ  point3D);        In PMAIN\ball.c; Returns UInt16.
FindVolume (Hedron  *hedron, UInt16  nearVert, XYZ  point3D);        In PMAIN\ball.c
FontInit ( );        In UTIL\font.c
FontInstall (void  *fontAddr, UInt32  fontSize, UInt16  charSize);        In UTIL\font.c
FontLoad (UInt16  fontNum);        In UTIL\font.c; Returns SInt32;
FreePalette (UInt16  pIndex);        In TEXTURE\palclut.c
FrontFaceCull (Model  *mod);        In 3DMODEL\3DModel.c
FSin (Fixed32  a);        In UTIL\trig.c; Returns Fixed32;
FSin (Fixed32  a);        In UTIL\sinc.s; Returns Fixed32;
FSqrt (Fixed32  num);        In UTIL\sqrt.s; Returns Fixed32;
ftoa (Fixed32  n, Char  s[ ]);        In VDP1\sp.c; Returns Int.
GameControl (Ball  *pBall, Shot  *pShotL, Shot  *pShotR, Hedron  *innerHedron,        In PMAIN\pmain.c
               Hedron  *outerHedron);       
GameOptionsSelect ( );        In PMAIN\pmain.c
GameStart (UInt32  t);        In PMAIN\pmain.c
GetAndSetMTState (Int16  mTarg, UInt8  *stream);        In PMAIN\target.c
GetAndSetState (Int16  targ, UInt8  *stream);        In PMAIN\target.c
GetComBlockAdr ( );        In SOUNDATA\snd_main.c; Returns UInt8;
GetEvent (Int  pn);        In UTIL\getpad.c; Returns UInt32;
GetGouraudAddr (Int  index);        In VDP1\gouraud.c; Returns UInt16.
GetRGBOffset (Model  *modXYZ  *normal, XYZ  *light);        In 3DMODEL\3DModel.c; Returns UInt16;
GetSndMapInfo (void  **adr, UInt32  **ladr, UInt16  data_kind, UInt16  data_no);        In SOUNDATA\snd_main.c; Returns static void;
GouraudAvgPart (UInt16  index, SpCmd  *part);        In VDP1\gouraud.c
GouraudFreeTable (UInt16  index);        In VDP1\gouraud.c
GouraudGetTable (Int index, UInt16 *val1, UInt16  *val2, UInt16  *val3, UInt16  *val4);        In VDP1\gouraud.c
GouraudInit ( );        In VDP1\gouraud.c
GouraudNewTable (UInt16  val1, UInt16  val2, UInt16  val3, UInt16  val4);        In VDP1\gouraud.c; Returns Int.
GouraudSetTable (Int  index, UInt16  val1, UInt16  val2, UInt16  val3, UInt16  val4);        In VDP1\gouraud.c
GouraudShadePart (UInt16  index, SpCmd  *part);        In VDP1\gouraud.c
GrabberState ( );        In PMAIN\grabber.c; Returns Int.
GravitateToPoint (Ball  *pBall);        In PMAIN\ball.c
HandleToIndex (Handle  hdl);        In MEM\STMem.c; Returns UInt16;
HedronAddRotation (Hedron  *hedron);        In PMAIN\icos.c
HedronAppear (Hedron  *hedron);        In PMAIN\icos.c
HedronCopy (Hedron  *h1, Hedron  *h2);        In PMAIN\icos.c
HedronCreate (Model  *mod, Hedron  *poly, Fixed32  faceLength, Int16 type,        In PMAIN\icos.c
               Fixed32  *elasArray, Int16  *targArray, FaceEdgeNorm  *edgeNormArray,       
               CloseVertFaces  *nearVertFaces, UInt16  *nextFace, UInt16  *moveOrient);       
HideCursor ( );        In PMAIN\options.c
HighlightSetting (UInt16  op, UInt16  setting);        In PMAIN\options.c
Homogenize (Transform  *trans, TransMatrix  tMat);        In 3DMODEL\3DModel.c
Init3D (Int16  projX, Int16  projY);        In 3DMODEL\3DModel.c
InitADrain (Int16  newTargDrain);        In PMAIN\target.c
InitBalls ( );        In PMAIN\score.c
InitBigTargets (Uint16  level, Hedron  *outer, Hedron  *inner, Fixed32  scaler);        In PMAIN\levels.c
InitBlock (UInt16  i);        In MEM\STMem.c
InitClip ( );        In VDP1\vdp1init.c
InitEdgeNormals (Hedron  *hedron);        In PMAIN\icos.c
InitFaceAttributes (Model  *mod, UInt16  attr1, UInt16  attr2);        In 3DMODEL\3DModel.c
InitFaceColors (Model  *mod, UInt16  rgb);        In 3DMODEL\3DModel.c
InitFaceNormals (Model  *mod);        In 3DMODEL\3DModel.c
InitGrabber (Fixed32  maxZ);        In PMAIN\grabber.c
InitHedra ( );        In PMAIN\icos.c
InitHedronSize ( );        In PMAIN\pmain.c
InitHighScores ( );        In PMAIN\score.c
InitLighting (Fixed32  ltX, Fixed32  ltY, Fixed32  ltZ, UInt16  intensity,        In 3DMODEL\3DModel.c
               UInt16  ambience);       
InitModel (Model  *mod);        In 3DMODEL\3DModel.c
InitModelShading (Model  *mod);        In 3DMODEL\3DModel.c
InitOpFont ( );        In PMAIN\score.c
InitPalettes ( );        In TEXTURE\palclut.c
InitPreTargets (Uint16  level, Hedron  *hedron);        In PMAIN\levels.c
InitQueue (TQueue  *q, Function  *fList, UInt32  num);        In TQUEUE\tqueue.c
InitRot (RotMatrix  rot);        In 3DMODEL\3DModel.c
InitScoreFont ( );        In PMAIN\score.c
InitSmallTargets (Uint16  level, Hedron  *hedron);        In PMAIN\levels.c
InitTargets ( );        In PMAIN\target.c
InitTimer ( );        In UTIL\timer.s
InitTrans (Transform  *trans);        In 3DMODEL\3DModel.c
InitVBlankInt ( );        In VDP1\vdp1init.c
InitVDP1VRAM ( );        In VDP1\vdp1init.c
InitVertexNormals (Model  *mod);        In 3DMODEL\3DModel.c
InstallPalette (Palette  *pal);        In TEXTURE\palclut.c
itoa (Int  n, Char s[ ]);        In VDP1\sp.c; Returns Int.
KillBigTargets (Uint16  level, Hedron  *hedron, Fixed32  scaler);        In PMAIN\levels.c
KillSmallTargets (Hedron  *hedron);        In PMAIN\levels.c
LoadFile (UInt8  *fName, UInt8  *buf);        In PMAIN\pmain.c
LoadSCUSysReg (SCUSysReg  *SCUReg);        In SCU\scu.c
LongMemCopy (        In UTIL\mem.s
LongMemCopy (        In UTIL\memsav.s
LoseBall ( );        In PMAIN\score.c
main ( );        In BUILD\main.c
MaintainGrabber (Ball  *pBall);        In PMAIN\grabber.c
MaintainHedronAnim (Hedron  *hedron);        In PMAIN\icos.c
MaintainTargets ( );        In PMAIN\target.c
MemCopyLower (UInt32  dest, UInt32  src, UInt32  count);        In MEM\STMem.c
MergeFreeBlocks (UInt16  b1, UInt16  b2, UInt16  heapIndex);        In MEM\STMem.c
MoveBall (Hedron  *innerHedra, Hedron  *world, Ball  *pBall, Shot  *pShotL,        In PMAIN\ball.c; Returns Boolean.
               Shot  *pShotR, UInt16  level);       
MoveBallForward (Ball  *pBall);        In PMAIN\ball.c
MovePts (XYZ  *delta, XYZ  *ptsIn, XYZ  *ptsOut, UInt16  count);        In 3DMODEL\3DModel.c
mprintf (FontDesc  *font, Int  x, Int  y, Char  *fmt, );        In VDP1\sp.c
Mul_Fixed (Fixed32  num1, Fixed32  num2);        In UTIL\mul.s; Returns Fixed32;
NextLevel (Uint16  level);        In PMAIN\levels.c
Normalize (RotMatrix  *ctm);        In 3DMODEL\3DModel.c
PaddleDisplayVertInit (Polygon  *pPaddle);        In PMAIN\paddle.c
PaddleInit (Polygon *(pPaddle, SpCmd  *sprite, ViewPoint  *camera);        In PMAIN\paddle.c
PaddleVertInit (Polygon  *pPaddle);        In PMAIN\paddle.c
PadInit ( );        In UTIL\getpad.c;
PadReadTask ( );        In UTIL\getpad.c;
PadValRead (Int  port);        In UTIL\getpad.c; Returns UInt32;
PartAdd (SpCmd  *poly);        In VDP1\sp.c
PartBegin ( );        In VDP1\sp.c
PartBeginJump (Int16  linkAddress);        In VDP1\sp.c
PartBLoad (SpCmd  *block, UInt32  size);        In VDP1\sp.c
PartEnd ( );        In VDP1\sp.c
PartLoad (SpCmd  *poly);        In VDP1\sp.c
PartLoadA (void  *vramAddr, SpCmd  *poly);        In VDP1\sp.c
PauseGame ( );        In PMAIN\pmain.c
PlaySFX (UInt16  sound);        In PMAIN\sfx.c
PlaySound ( );        In PMAIN\pmain.c
PLoadFonts ( );        In TEXDATA\ptex.c
PLoadTextures ( );        In TEXDATA\ptex.c
PMain ( );        In PMAIN\pmain.c
PointOnPlane (XYZ  point3D, XYZ  pointOnPlane, XYZ  planeNormal, Int  side);        In UTIL\geoutil.c; Returns Boolean;
ProjectPts (XYZ  *ptsIn, Point2D  *ptsOut, UInt16  count, Fixed32  ppd);        In 3DMODEL\3DModel.c
putchr (Char  ch, FontDesc  *font);        In VDP1\sp.c
RadiusInit (Hedron  *hedron);        In PMAIN\icos.c
RayReflection (XYZ  *vect, XYZ  normals, Int  side);        In UTIL\geoutil.c;
RayWithPlane (XYZ  *p, XYZ  *q, XYZ  v,  XYZ  w);        In UTIL\geoutil.c; Returns Fixed32;
RayWithSphere (XYZ  sphereCenter, Fixed32  scaleRadius, Fixed32  scaler,        In UTIL\geoutil.c; Returns Boolean;
                XYZ  rayPoint, XYZ  rayDirection, XYZ  *entryPoint, Fixed32  *t);       
RemovePalette (UInt16  pIndex);        In TEXTURE\palclut.c
RenderFace (Model  *mod, Face  *face, SPCMD  *cmdTbl);        In 3DMODEL\3DModel.c
RenderModel (Model  *mod);        In 3DMODEL\3DModel.c
RenderMoveTarg (MovingTarget  *mTg);        In PMAIN\target.c
RenderMovingTargets ( );        In PMAIN\target.c
reverse (Char  s[ ]);        In VDP1\sp.c
RotatePts (RotMatrix  *mat, XYZ  *ptsIn, XYZ  *ptsOut, UInt16  count);        In 3DMODEL\3DModel.c
ScalePts (Fixed32  factor, XYZ  *ptsIn, XYZ  *ptsOut, UInt16  count);        In 3DMODEL\3DModel.c
ScrollPriorInit ( );        In VDP2\vdp2init.c
ScrollZoomInit ( );        In VDP2\vdp2init.c
SCSPInit ( );        In PMAIN\pmain.c
SCUDMA0 (SCUDMASetRegisters  *dma);        In SCU\scudma.c; Returns ErrorCode;
SCUDMA1 (SCUDMASetRegisters  *dma);        In SCU\scudma.c; Returns ErrorCode;
SCUDMA2 (SCUDMASetRegisters  *dma);        In SCU\scudma.c; Returns ErrorCode;
SCUDMADSPProgram (MemAddr  src, MemAddr  dst, UInt16  length);        In SCU\scudsp.c
SCUInit ( );        In SCU\scu.c
SCULoadDSPProgram (MemAddr  dst, MemAddr  src, UInt16  length);        In SCU\scudsp.c
SelectScreen ( );        In VDP2\vdp2init.c; Of type static void.
SelectWindows ( );        In VDP2\vdp2init.c; Of type static void.
SemaphoreClear ( );        In PMAIN\pmain.c
SetCRAMMode ( );        In VDP2\vdp2init.c; Of type static void.
SetEraseData (UInt16  data);        In VDP1\vdp1reg.c
SetEraseRect (UInt16  ul, UInt16  lr);        In VDP1\vdp1reg.c
SetFaceRGBOffset (Model  *mod, UInt16  fc, UInt16  rgb);        In 3DMODEL\3DModel.c
SetFBSwitchMode (UInt16  fbmode);        In VDP1\vdp1reg.c
SetHedronCenter (Hedron  *hedron, Fixed32  x, Fixed32  y, Fixed32  z);        In PMAIN\icos.c
SetLREraseCoor (UInt16  point);        In VDP1\vdp1reg.c
SetMoveTargState (MovingTarget  *mTg, Int16  state, Boolean  hiliteFlag);        In PMAIN\target.c
SetPlotTrig (UInt16  pt);        In VDP1\vdp1reg.c
SetRGBOffset (UInt16  index, UInt16  rgb);        In TEXTURE\palclut.c
SetScreenFnc ( );        In VDP2\vdp2init.c; Of type static void.
SetState (Int16  targ, Int16  state, Boolean  hiliteFlag);        In PMAIN\target.c
SetTVM (UInt16  tvm);        In VDP1\vdp1reg.c
SetULEraseCoor (UInt16  point);        In VDP1\vdp1reg.c
SetUpQueues ( );        In TQUEUE\tqueue.c
SetVDP1Reg (VDP1SysReg  *reg);        In VDP1\vdp1reg.c
SetVRAMUsage ( );        In VDP2\vdp2init.c; Of type static void.
SetWorldCenter (Fixed32  x,Fixed32  y,Fixed32  z);        In 3DMODEL\3DModel.c
ShadeFace (Model  *mod, Face  *face);        In 3DMODEL\3DModel.c
ShadeModel (Model  *mod);        In 3DMODEL\3DModel.c
ShotBallReflection (Hedron  *outerHedron, Ball  *pBall, Shot  *pShot, Boolean  shot);        In PMAIN\ball.c
ShotDraw (Hedron  *outerHedron, Ball  *pBall, Shot  *pShot, Uint16  ballZ,        In PMAIN\shot.c
               Boolean  shotType);       
ShotStartL (Shot  *pshot, Fixed32  radius);        In PMAIN\shot.c
ShotStartR (Shot  *pshot, Fixed32  radius);        In PMAIN\shot.c
ShowBalls ( );        In PMAIN\score.c
ShowCursor ( );        In PMAIN\options.c
ShowData ( );        In PMAIN\pmain.c
ShowHighScores ( );        In PMAIN\score.c
ShowOptionsScreen ( );        In PMAIN\options.c
ShowScore ( );        In PMAIN\score.c
SkipCond (UInt8  *p);        In PMAIN\target.c; Returns UInt8 *.
SkipCons (UInt8  *p);        In PMAIN\target.c; Returns UInt8 *.
SkipState (UInt8  *p);        In PMAIN\target.c; Returns UInt8 *.
SMPA_SwInit ( );        In UTIL\getpad.c;
SND_AnlTlVl (SndCDVlAnl  *left, SndCDVlAnl  *right);        In SOUNDATA\snd_main.c
Snd_ChgEfct (SndEfctBnkNum  efct_no);        In SOUNDATA\snd_main.c; Returns SndRet;
Snd_ChgMap (SndAreaMap  area_no);        In SOUNDATA\snd_main.c; Returns SndRet;
Snd_ChgMix (SndToneBnkNum  tone_no, SndMixBnkNum  mix_no);        In SOUNDATA\snd_main.c; Returns SndRet;
Snd_ChgMixPrm (SndEfctOut  efct_out, SndLev  level, SndPan  pan);        In SOUNDATA\snd_main.c; Returns SndRet;
Snd_ChgPCM (SndPCMChgPrm  *cprm);        In SOUNDATA\snd_main.c; Returns SndRet;
Snd_ChgTempo (SndSeqNum  seq_no, SndTempo  tempo);        In SOUNDATA\snd_main.c; Returns SndRet;
Snd_ChkHard (SndHardStat  *stat, SndHardPrm  prm);        In SOUNDATA\snd_main.c; Returns SndRet;
Snd_ContSeq (SndSeqNum  seq_no);        In SOUNDATA\snd_main.c; Returns SndRet;
Snd_CtrlDirMidi (SndSeqNum  seq_no, SndSeqPri  seq_pri, UInt8  md_com,        In SOUNDATA\snd_main.c; Returns SndRet;
               UInt8  ch, UInt8  dt1, UInt8  dt2);       
Snd_GetAnlHzVl (SndCDHzSrVl  *hz_vl);        In SOUNDATA\snd_main.c
Snd_GetPCMPlayAdr (SndPCMPlayAdr  *pcm_adr, SndPCMNum  num);        In SOUNDATA\snd_main.c
Snd_GetSeqPlayPos (SndSeqPlayPos  *pos, SndSeqNum  seq_no);        In SOUNDATA\snd_main.c
Snd_GetSeqStat (SndSeqStat  *status, SndSeqNum  seq_no);        In SOUNDATA\snd_main.c
Snd_Init (SndInidt  *sys_ini);        In SOUNDATA\snd_main.c
Snd_MoveData (UInt16  *source, UInt32  size, UInt16  data_kind,        In SOUNDATA\snd_main.c
               UInt16  data_no);       
Snd_PauseSeq (SndSeqNum  seq_no);        In SOUNDATA\snd_main.c; Returns SndRet;
Snd_SetCDDALev (SndLev  left, SndLev  right);        In SOUNDATA\snd_main.c; Returns SndRet;
Snd_SetCDDAPan (SndLev  left, SndLev  right);        In SOUNDATA\snd_main.c; Returns SndRet;
Snd_SetSeqVl (SndSeqNum  seq_no, SndSeqVl  seq_vl, SndFade  fade);        In SOUNDATA\snd_main.c; Returns SndRet;
Snd_SetTlVl (SndTlVl  vol);        In SOUNDATA\snd_main.c; Returns SndRet;
Snd_StartSeq (SndSeqNum  Seq_no, SndSeqBnkNum  seq_bnk_no,        In SOUNDATA\snd_main.c; Returns SndRet;
               SndSeqSngNum  song_no, SndSeqPri  pri_lev);       
Snd_StartVlAnl ( );        In SOUNDATA\snd_main.c; Returns SndRet;
Snd_StopPCM (SndPCMNum  pcm_num);        In SOUNDATA\snd_main.c; Returns SndRet;
Snd_StopSeq (SndSeqNum  seq_no);        In SOUNDATA\snd_main.c; Returns SndRet;
Snd_StopVlAnl ( );        In SOUNDATA\snd_main.c; Returns SndRet;
SndStartPCM (SndPCMStartPrm  *sprm, SndPCMChgPrm  *cprm);        In SOUNDATA\snd_main.c; Returns SndRet;
SortCmdTables ( );        In PMAIN\pmain.c
SpDSprite (SpCmd  *sprite);        In VDP1\sp.c
SpPolygon (SpCmd  *sprite);        In VDP1\sp.c
SpPolyline (SpCmd  *sprite);        In VDP1\sp.c
SpritePriorInit ( );        In VDP2\vdp2init.c
SpSetColor (SpCmd  *sprite, UInt16  color);        In VDP1\sp.c
SpSetCoord (SpCmd  *sprite, UInt16  ax, UInt16  ay, UInt16  bx, UInt16  by,        In VDP1\sp.c
               UInt16  cx, UInt16  cy, UInt16  dx, UInt16  dy);       
SpSetTexture (SpCmd  *sprite, TextureRec  *texture);        In TEXTURE\texture.c
STMemAlloc (UInt32  blockSize, Uint16  heapIndex,UInt16  initialFlags);        In MEM\STMem.c; Returns Handle;
STMemBytesFree (UInt16  heapIndex);        In MEM\STMem.c; Returns SInt32;
STMemDefrag (UInt16  heapIndex);        In MEM\STMem.c; Returns SInt32;
STMemFree (Handle  hdl);        In MEM\STMem.c; Returns SInt32;
STMemFreePtr (Ptr  p);        In MEM\STMem.c; Returns SInt32;
STMemHandleSize (Handle  hdl);        In MEM\STMem.c; Returns SInt32;
STMemLock (Handle  hdl);        In MEM\STMem.c; Returns SInt32;
STMemMaxBlock (UInt16  heapIndex);        In MEM\STMem.c; Returns SInt32;
STMemReset ( );        In MEM\STMem.c
STMemReset1 (UInt16  heapIndex);        In MEM\STMem.c; Returns SInt32;
STMemUnlock (Handle  hdl);        In MEM\STMem.c; Returns SInt32;
SwapBuf ( );        In PMAIN\pmain.c
SwitchTargToDrain (Int16  newTargDrain);        In PMAIN\target.c
SwitchVRAM0 ( );        In VDP1\vdp1reg.c
SwitchVRAM1 ( );        In VDP1\vdp1reg.c
TexInit ( );        In TEXTURE\texture.c
TexInstall (SAT2Header  *hdr, UInt8  txType);        In TEXTURE\texture.c
TexLoad (TextureRec  *texture);        In TEXTURE\texture.c; Returns SInt32.
TexMarkUnused ( );        In TEXTURE\texture.c
TexUnInstall (SAT2Header  *hdr);        In TEXTURE\texture.c
TexUnload (TextureRec  *texture);        In TEXTURE\texture.c
TexUnloadUnused ( );        In TEXTURE\texture.c
TransformModel (Model  *mod);        In 3DMODEL\3DModel.c
TransformVerts (Model  *mod);        In 3DMODEL\3DModel.c
TurnGrabberOff ( );        In PMAIN\grabber.c
TurnGrabberOn ( );        In PMAIN\grabber.c
TVModeInit ( );        In VDP2\vdp2init.c; Of type static void.
UndoOptions ( );        In PMAIN\options.c
UnPauseGame ( );        In PMAIN\pmain.c
UpdateColorRAM ( );        In TEXTURE\palclut.c
UpdateCursor ( );        In PMAIN\options.c
UpdateGrabber (Ball  *pBall);        In PMAIN\grabber.c
UpdateHighScores ( );        In PMAIN\score.c
UpdateNewDrain (Hedron  *outerHedron);        In PMAIN\pmain.c; Returns UInt16.
vblank_end ( );        In VDP1\vblank.s
VDP1Clear ( );        In PMAIN\pmain.c
VDP1Init ( );        In VDP1\vdp1init.c
VDP2Init ( );        In VDP2\vdp2init.c
VectorLength (XYZ  *v);        In UTIL\vectutil.c; Returns Fixed32;
VectorLengthNorm (XYZ  *v);        In UTIL\vectutil.c; Returns Fixed32;
VectorNormLength (XYZ  *v, Fixed32  normLen);        In UTIL\vectutil.c
VectorNormOne (XYZ  *v);        In UTIL\vectutil.c
WaitDrawAndSwap ( );        In PMAIN\pmain.c
WaitStartOrC ( );        In PMAIN\pmain.c
WaitTimerOrStart (UInt16  t);        In PMAIN\options.c
XRotPts (Fixed32  angle, XYZ  *ptsIn, XYZ  *ptsOut, UInt16  count);        In 3DMODEL\3DModel.c
YRotPts (Fixed32  angle, XYZ  *ptsIn, XYZ  *ptsOut, UInt16  count);        In 3DMODEL\3DModel.c
ZRotPts (Fixed32  angle, XYZ  *ptsIn, XYZ  *ptsOut, UInt16  count);        In 3DMODEL\3DModel.c
作者: szxyz    时间: 2013-9-10 10:09

进不去,打开里面是空的,这资源分享是怎么回事?
作者: 三井    时间: 2013-9-10 11:11

引用:
原帖由 szxyz 于 2013-9-10 10:09 发表
进不去,打开里面是空的,这资源分享是怎么回事?
已经修正了呢,可以下载了现在
作者: poloevo    时间: 2013-9-10 12:31

收藏了,感谢分享
作者: dtxyy    时间: 2013-9-10 19:23

哪来这么多绝版资源
作者: md2    时间: 2013-9-10 20:42

后面的是函数说明?




欢迎光临 TGFC Lifestyle (http://tgfcer.com/) Powered by Discuz! 6.0.0