Assignment title: C++
Question
CSP2151 Assignment
Q
This assignment is an extension of the Workshops you have been doing all semester. Where appropriate, the standards set out in previous workshops should be followed.
Design and Implement a character generator for Dungeons and Dragons. It is to have the following specifications:
· The program should ask for a Level.
· The program should offer a selection of Races, to choose from and accept a choice
o Races should be read in from a file (races.chr) and stored in a linked list.
· The program should offer a selection of Classes to choose from and accept a choice.
o The Classes should be read in from a file (classes.chr) and stored in a linked list.
o New Classes should be able to be added by adding the information to the file only.
o Every Class should have an attribute that is considered Primary
· The program should then offer a variety of methods of generating the attributes
o The attributes should be: Str, Dex, Con, Int, Wis, and Cha
o The program should offer a selection of methods of generation such as:
§ Entering the attributes directly
§ Roll 4d6 and discard the lowest value.
§ Roll 4d6 and discard the lowest value and if the attribute is 16 or higher, add the value of an additional 1d6.
§ Roll Method IX:
· Each class should weight each attribute from most to least important. In Method IX, the most important attribute rolls 9d6 and keeps the highest 3. The second most important rolls 8d6, keeping the highest 3. This follows in this pattern of 7d6, then 6d6, then 5d6 and finally 4d6 for the least important.
· This information is part of the Class information and is used to generate the attributes in the Character structure.
· ie: A Fighter would probably rate Str highest, then Con and so on until you get to Chr at the lowest. This would result in something like:
Str: 9 Dex: 6 Con: 8 Int: 7 Wis: 5 Chr: 4
· Meaning 9d6 is rolled for Str, 6d6 is rolled for Dex, etc.
· Every attribute is the sum of the highest 3 dice regardless of the number of dice rolled.
· Each attribute confers a bonus or penalty. Through the Workshops you should have deduced that the pattern for the bonuses follows the formula y = (x/2)-5.