Csce.uark.edu



CSCE 2014 – Programming Project 1Midpoint Due Date – 01/24/2020 at 11:59pmFinal Due Date – 01/31/2020 at 11:59pm1. Problem Statement:The popularity of Magic: The Gathering has grown so much since its initial release in 1993 that according to Wikipedia there are now more than 20 billion Magic cards in player and collector decks all over the world. The goal of this programming project is to create a program that Magic lovers could use to keep track of the Magic cards in their collection (and perhaps Magic cards that are on their wish list).Your first task is to create a data structure to store vital information about each Magic card in the collection. You will do this by defining and implementing a “Magic” class that has FIVE fields that describe the card itself (CardName, ManaCost, Type, CardText, and CardNumber) and FIVE fields that describe its value in the collection (Rarity, Condition, PurchasePrice, CurrentValue, and Quantity). Your C++ class should contain constructor, destructor functions, get and set methods, and a method to print all information about the card.Your second task is to create a data structure that stores information about the whole Magic card collection. You will do this by defining and implementing a “MagicDeck” class that contains an array of Magic objects. For this class, you are required to implement FIVE methods that make use of this array of Magic objects (ReadDeck, PrintDeck, TotalValue, MostValuable, MostNumerous). The first methods will let you initialize a MagicDeck object by reading information from a file. The second method will then print this information out again. The next three methods make use of the CurrentValue and Quantity of cards in the deck to calculate and print the specific information about the collection.Finally, your main program should declare and initialize a Magic object and a MagicDeck object, and test the methods in both classes with a sequence of “hand coded” method calls, without any input from the user. To do this, you will have to create an ASCII text file containing information about at least TEN Magic cards. 2. Design:Your first design task is to decide what data types and initial values are appropriate for all of the data fields in the Magic class. Once you have this worked out, it should be straightforward to design and implement the constructor and destructor functions, the get and set methods, and the print method.Your second design task is to decide what private variables needed in the MagicDeck class. You can assume that no collector will have more than 1000 Magic cards. Your third design task is to develop the algorithms needed to implement the FIVE MagicDeck methods listed above. One important aspect here is to decide how to store the attributes of a Magic card in an ASCII text file so it is easy to for someone to type and also easy for your program to read. Finally, you need to create an ASCII text file that contains information about at least TEN Magic cards. You are welcome to make up any card descriptions you want or you can look online at to view real card descriptions. The “random card” button should give you some inspiration.3. Implementation:To implement your project, you should break your code down into FIVE files: Magic.h, Magic.cpp, MagicDeck.h, MagicDeck.cpp and main.cpp. If you use NetBeans, you can create these classes using the method described in lab. If you create your program on OnlineGDB you will have to create the files and create everything yourself.As always, it would be a good idea to start with "skeleton methods" to get something to compile, and then add the desired code to each method incrementally writing comments, adding code, compiling, debugging, a little bit at a time. Once you have the methods implemented, it should be fairly simple to create a main program that calls these methods to complete your project.Remember to use good programming style when creating your program (good names for variables and constants, proper indenting for loops and conditionals, clear comments). Be sure to save backup copies of your program somewhere safe. Otherwise, you may end up retyping your whole program if something goes wrong.4. Testing:Test your program to check that it operates correctly for all of the requirements listed above. Also check for the error handling capabilities of the code. Try your program with several input values, and save your testing output in text files for inclusion in your project report.5. Documentation:When you have completed your C++ program, write a short report using the project report template describing what the objectives were, what you did, and the status of the program. Does it work properly for all test cases? Are there any known problems? Save this report to be submitted electronically.6. Project Submission:In this class, we will be using electronic project submission to make sure that all students hand their programming projects and labs on time, and to perform automatic plagiarism analysis of all programs that are submitted. When you have completed the tasks above go to Blackboard to upload your documentation (a single docx or pdf file), and all of your C++ program files. Do NOT upload an executable version of your program.The dates on your electronic submission will be used to verify that you met the due date above. All late projects will receive reduced credit:10% off if less than 1 day late,20% off if less than 2 days late,30% off if less than 3 days late,no credit if more than 3 days late. You will receive partial credit for all programs that compile even if they do not meet all program requirements, so handing projects in on time is highly recommended.7. Academic Honesty Statement:Students are expected to submit their own work on all programming projects, unless group projects have been explicitly assigned. Students are NOT allowed to distribute code to each other, or copy code from another individual or website. Students ARE allowed to use any materials on the class website, or in the textbook, or ask the instructor and/or GTAs for assistance.This course will be using highly effective program comparison software to calculate the similarity of all programs to each other, and to homework assignments from previous semesters. Please do not be tempted to plagiarize from another student.Violations of the policies above will be reported to the Provost's office and may result in a ZERO on the programming project, an F in the class, or suspension from the university, depending on the severity of the violation and any history of prior violations. ................
................

In order to avoid copyright disputes, this page is only a partial summary.

Google Online Preview   Download