Project Specification

Due: 11:59 P.M. Tuesday, December 7, 2010

“The Molinator” or “Make My Day”

This is a team project, with three students on a team. The instructor will assign the teams. (Note: If there are any problems with your team assignment, please talk to your TA or Dr. Daugherity promptly.) There are two choices for the project. Each team needs to decide which project they will do.

Project 1 – “The Molinator” project is to write a C++/FLTK GUI program which simulates the game of “Whack-a-mole” (like that at Gattitown, etc.). The “game board” is a 10 by 10 grid. When the player clicks the “Start” button, a mole pops its head up in a random square. (The mole is represented by a circle of a random color with a random point score [5, 10, 20, 50, or 100] displayed in the circle.) When the user clicks the mole, that score is added to the player’s total for the game, and the mole disappears. The program checks to see if 60 seconds have elapsed since the start of the game; if so, the game is over. If not, another mole appears, and so on. Hint: std_lib_facilities.h has a function randint(n) which returns a random int in the range [0,n).

The program should start by giving instructions on how to play the game and asking the player’s name. At the end of the game update a disk file of the top five scores and player names, and display those. (The list starts out blank.)

Extra credit (up to 10 points) will be given for additional features such as images (maybe pictures of Alvin and the other chipmunks???), animation, sound effects (check out PulseAudio or SDL), making the mole disappear after 2 seconds, a clock showing the time left in the game, several levels of play, etc.

Hints: Find time-related functions by typing “man -k time” and “man -k clock”. You may also want to look at “timers” (alarm clocks) in the “real” FLTK—see the documentation at fltk.org.

Also see the section labeled “Both Projects” below.
Project 2 – The “Make My Day” project is to write a C++/FLTK GUI monthly planner page program along the lines of Outlook. The program should start with a description of what it does and then ask for a month and year and the file name of the appointment file (described below). The program then displays the requested month with appointments from the file. It should look something like this:

Allow the user to add additional appointments, which are then displayed on the calendar and also added to the appointment file (hint: “append” to the existing file).

Here is the format for the appointments file: Each line begins with either a month/day, month/day/year, or three-letter days of week. For example,

1/1 New Year’s Day

4/1 April Fool’s Day

4/8/2007 Easter

3/23/2008 Easter

4/12/2009 Easter

4/4/2010 Easter

7/4 Independence Day

12/25 Christmas

Tue CSCE 111

Thu CSCE 111

Hint: To calculate the day of the week, look up “Zeller’s congruence”.

Extra credit (up to 10 points) will be given for additional features such as implementing the “previous month” and “next month” buttons (at the top left of the picture above), which will display the new month and reread the appointments file; implementing the “Search Calendar” box; etc.

BOTH PROJECTS: Your program should run without change (other than recompiling) on the Visual C++ environment in the lab or unix.cse.tamu.edu with X windows.

Your program must be written with a GUI in C++ using FLTK and be submitted both to CSNET and also on a CD formatted for Windows. The project report (described below) should be submitted on paper to your TA, along with your CD. You only need to submit one report, CD, and CSNET file per team. Write a report according to the outline below. All team members will receive the same project grade, unless some team member does not do his/her part (see report outline below).

Important! You must demonstrate your project to your TA or it will not be graded!

The TA’s will vote on the best projects, which (with your permission) will be posted on the course web site for everyone to play!

REPORT OUTLINE

The project report must be printed on a laser printer. The report should include the following sections:

1. Team information (team name, members’ names, who did what, did each member do a fair share of the work)

2. Statement of the problem, significance, etc.

3. Restrictions and limitations

4. Explanation of your approach (analysis to choose a strategy for programming the project, how you coded it, etc.)

5. Sample run (screen shots)

6. Results and analysis

7. Conclusions - What did you show? What did you learn?

8. Future research (how your program could be improved or extended)

9. Instructions on how to run your program

10. Listing of the COMMENTED program

11. Bibliography - references used, if any