Project Description

    This will be a race among all programming languages. War of the languages!!! The human player will be the Assembly Mobile, and the other AI routines will be named C-Mobile, Fortran Mobile, Basic Mobile, etc. There will be point and time bonuses. Running over (picking up) certain items like a RAM chip, resistors, capacitors, intel symbol, etc. can be used for point bonuses. Time bonuses are possible only through the pick-up of a clock symbol. Obstacles are included in this game also. Such obstacles include undefined variable , mismatch arguments, char-to-int warnings, etc. This will result in points taken away. Objective: be the first to terminate successfully. i.e. Don`t: lose to another (AI) player, or run over an infinite loop symbol or segmentation fault.


Main Game Control

GameMain    By Charlinda Catchings

Purpose:  Control/maintain game flow
  1. Initialize registers to correct segment
  2. Initialze for correct mode (video, text, etc.)
  3. Set up and maintain music
  4. Set up Introduction Screen
  5. Set up Selection Screen
  6. Respond to player's keyboard input:
  7. Continuous updates of:
  8. If player wins/crashes, set up Win/Lose Screen
Inputs: Outputs:


AI

Variables:

Procedures:

EnemyAI:  Written by Il-Sun Park

Purpose:  EnemyAI will be called for every computer challenger in JICE’s racers.  The AI, which will have varying degrees of intelligence for each computer challenger, will determine through a number of factors what the next x-y coordinate and speed the computer challenger will have.  The top computer challenger will be at 94% of the players maximum speed reached- this will offset the fact that the computer maneuvers more skillfully than a human player.  As the intelligence of the AI player goes down, so does its top speed.  The AI will be able to bump opponents, by sensing if anyone is near, then changing direction and speed accordingly.  It will be able to dodge obstacles in the same fashion.  This will be a c-style procedure.

Inputs:


Outputs:

UpdateMaxSpeed:  Written by Il-Sun Park

Purpose:  UpdateMaxSpeed takes previous PlayerMaxSpeed, checks whether current speed is faster, if so, updates PlayerMaxSpeed.  C- style procedure.  Called by EnemyAI.

Inputs:

Outputs:

CheckEnemy:  Written by Il-Sun Park

Purpose:  CheckEnemy checks a 20x20 grid in front of the computer challenger to see if any enemy cars are there.  If so, tells EnemyAI to maneuver towards them. C-Style procedure called by EnemyAI.

Inputs:

Outputs:

CheckCourse: Written by Il-Sun Park

Purpose: CheckCourse checks a 30x30 grid in front of the computer challegner to see if any obstacles, powerups, etc. are there.  If so, tells EnemyAI to maneuver away/towards them, depending on what it is.  C-Style procedure called by EnemyAI.

Inputs:

Outputs:

User Interface

Purpose:  This portion of the project deals with the user of the game.  It takes all the inputs given by the user and outputs to the proper screens or playing of the actual game.  The screens that will be used will be an Introduction Screen, Options Screen, Instruction Screen, Player Screen, and Win/Lose Screens.  This portion will also deal with the user moves.  It takes the variables of his direction, acceleration, and so on.

Variables:

Procedures:

Introduction:   By Eilleen Berganos

Purpose:  Introduction of Game to User

Inputs: Enter_Key

Outputs:

Notes: LoadPCX is used

OptionsScreen:   By Eilleen Berganos

Purpose: Inputs: Outputs:

SelectLanguage:   By Eilleen Berganos

Instructions:    By Eilleen Berganos

Purpose:
Inputs: None
Outputs:

WinScreen:    By Eilleen Berganos

Purpose:
Inputs: None

Outputs:

LoseScreen:    By Eilleen Berganos

Purpose: Inputs: None

Outputs:

CreditsScreen:   By Eilleen Berganos

Purpose:


Inputs: None

Outputs:

InstTimer, DeInstTimer, MyTimerHandler:  By E. Berganos

Purpose:  Controls pace of the game similar to what was used in MP3 but with some modifications for our game.
Inputs: Outputs:

InstKey, DeInstKey, MyKeyHandler: By Eilleen Berganos

Purpose:  Sets game controls when key is pressed.  Similar to what was used in MP3 but with large variation because of the number of variables that is controlled. Inputs: Outputs:

Graphics and Sound

Variables:

Procedures:

LoadPCX by John Smolen

Purpose: This function takes a 320x200 PCX file and decompresses it into a buffer for later use.
Inputs: Outputs:

Splash by John Smolen

Purpose: This function takes a segment containing a 320x200 image, and puts it into the ScreenBuffer
Inputs: Outputs:

InitBuf by John Smolen

Purpose: This function initializes ScreenBuffer and ZBuffer to default values
Inputs: Outputs:

ModeText from MP4 - See MP4

ModeGraph from MP4 - See MP4

PlaySound by John Smolen

Purpose: This function takes a sound file, loads it, initializes the sound card, plays the sound, then cleans up.
Inputs: Outputs: Notes: Will call helper functions that have not yet been defined.

DrawScreen by John Smolen

Purpose: This function takes the values in ScreenBuffer and ZBuffer to create a completed image on the user's screen
Inputs: Outputs:

DrawPoint by John Smolen

Purpose: This function (C-style) places a point into the ScreenBuffer and ZBuffer at the given coordinates with the given color and type.
Inputs: Outputs:

PutBkGd by John Smolen

Purpose: This function (C-style) draws the background image based on a 320xN-sized image.  It will repeatedly place the image, so that the background looks continuous.  It will begin placing the image at any specified line, to allow the background to "shift" up or down, giving the appearance of motion.
Inputs: Outputs:

PutImage by John Smolen

Purpose: This function (C-style) places a square image at X,Y within ScreenBuffer and ZBuffer.
Inputs: Outputs:

DrawStatus by John Smolen

Purpose: This function draws the status bar (the area of the screen containing the score, speed, etc. of the player).
Inputs: Output:

DrawText by John Smolen

Purpose: This function (C-Style) draws text starting at X,Y
Inputs: Outputs: