Functional decomposition implementation of the algorithm

Assignment Help C/C++ Programming
Reference no: EM131103331

You will be writing a text-based role playing game. The game will include the following:

- A main menu from which the user will choose:

1) See Rules

2) Play Game

3) Quit-

If the user chooses to play the game, menus will be shown from which the user willchoose his/her character and weapon. The course of the game will depend upon theuser's choices.The following menu will be displayed for the user to select a character:

1) Human

2) Ogre

3) ElfNext,

you will display the following menu from which the user will choose a weapon:

1) Flame Thrower

2) Bow and Arrow

3) Magic Potion

- A score will be kept throughout the game based on the user's selections.

You will assign the following point values, but the user will not know these values:Human - 100Ogre - 200Elf - 300If the user chooses Flame Thrower or Bow and Arrow, a practice session will start in whichthe computer will randomly generate a number from 1 - 4, which will determine whattarget is hit.

Assign the following point values:

1 - Target A is hit, worth 100 points2 - Target B is hit, worth 200 points3 - Target C is hit, worth 300 points4 - No target is hit, 0 pointsIf the user chooses Magic, he/she will try to make a potion. The computer will randomlygenerate a number from 0 - 1 to determine if the potion is successful.If the potion is a success, 200 points will be awarded, if it fails, 100 points will be deducted from the score.

- At the end of the game, display the user's score on the screen.

- You will also have a high score file called "highscore.txt" that contains a name and ascore.At the end of the game, read in the score stored in "highscore.txt".

o If the file does not exist, create one with the current player as the high score (name &score)

o If the user has scored higher than the value in the file, replace the value in the text filewith the current player's name and score. Otherwise, do not change the text file.

- The user should be able to play as many times as he/she wishes.Have fun and be creative!!

Notes about Functionality, Implementation & Program Requirements:

1. The program should validate the information entered by the user and display theappropriate error messages.

2. The code should be self-documented, including:

- Descriptive Comment indicating- Author- Program Summary- IPO Chart

- Appropriate comments throughout the code that highlight, among other things, the implementation of the algorithm.

- Adequate use of spaces and indentation so the source code is easy to readwhen printed out.

3. Functional decomposition implementation of the algorithm. Must define at least four different functions. Make sure to include functions that exemplify void vs. return-type,and value vs. reference parameters

Reference no: EM131103331

Questions Cloud

Business leader that you believe demonstrates : Select a known business leader that you believe demonstrates strong leadership traits and write a research paper on this individual. This leader should not be someone you know personally.
Why should we pay special attention to our cmc : What function of nonverbal communication did your interactions illustrate? How important was nonverbal communication in all of your computer-mediated interactions? Or, how did the lack of nonverbal communication allow you to think about a function..
What is the role of inherited genes in cancer : What is the role of inherited genes in cancer? What is the role of newly acquired mutations in cancer? Although numerous family members can develop cancer in the same tissue, each person's cancer is unique.
What are the implications of this extension : What are the implications of this extension?
Functional decomposition implementation of the algorithm : Functional decomposition implementation of the algorithm. Must define at least four different functions. Make sure to include functions that exemplify void vs. return-type,and value vs. reference parameters
An existing company or a new company idea : Write about an existing company or a new company idea.  Be sure to choose one concept.. The following details below include what should be included in each section of the business plan.
Explain the relationship between chromosomes and dna : Describe the relationship between chromosomes and DNA. Identify an example of a genetic disorder and describe the genetic disorder including symptoms, impact on quality of life, and life expectancy.
Identify the features of the fastica algorithm : Identify the features of the FastICA algorithm that are responsible for this important property
Assignment on discussion-course reflection : Based on your learning and experiences going through this course as well as the research you conducted, do the following:

Reviews

Write a Review

C/C++ Programming Questions & Answers

  Create program that uses functions and reference parameters

Create program that uses functions and reference parameters, and asks user for the outside temperature.

  Write a program using vectors and iterators

Write a program using vectors and iterators that allows a user to maintain a personal list of DVD titles

  Write the code required to analyse and display the data

Calculate and store the average for each row and column. Determine and store the values for the Average Map.

  Write a webservices application

Write a webservices application that does a simple four function calculator

  Iimplement a client-server of the game

Iimplement a client-server version of the rock-paper-scissors-lizard-Spock game.

  Model-view-controller

Explain Model-View-Controller paradigm

  Design a nested program

How many levels of nesting are there in this design?

  Convert celsius temperatures to fahrenheit temperatures

Write a C++ program that converts Celsius Temperatures to Fahrenheit Temperatures.

  Evaluate and output the value in the given base

Write C program that will input two values from the user that are a Value and a Base with which you will evaluate and output the Value in the given Base.

  Design a base class shape with virtual functions

Design a base class shape with virtual functions

  Implementation of classes

Implementation of classes Chart and BarChart. Class barChart chould display a simple textual representation of the data

  Technical paper: memory management

Technical Paper: Memory Management, The intent of this paper is to provide you with an in depth knowledge of how memory is used in executing, your programs and its critical support for applications.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd