I underlined and bold print my files.
I need to know how to make this code into a working game.
The object of the game is to have two players 1- belle and 2-beast.
I want them to lose and gain strength and health, when 0 die.
I need to know how to make them interact.
I need to know what to do with teraform (creek, pasture, brick road) how to add.
I need the public interface to look like the forest.
classes need to function the program needs to function.
The purpose of this assignment is to use the character concept below in stars and implement the main (in stars).
************************************************** *************************************
#include <iostream>
#include <string>
using namespace std;
class Character {
private:
string hair,eyes;
int strength, health;
public:
Character();
Character(string, string, int, int);
Character(const Character&);
void setHair(string);
void setEyes(string);
void setStrength(int);
void setHealth(int);
string getHair()const;
string getEyes()const;
int getStrength()const;
int getHealth()const;
void addStrength(int);
void addHealth(int);
void loseStrength(int);
void loseHealth(int);
void interact(Character&);
void print()const;
void read();
};
Character:: Character (string 1, string 2, int a, int b){
1= hair;
2= eyes;
A= strength;
B= health;
}
Character:: Character (const Character & d) {
1= d.hair;
2= d.eyes;
3= d.strength;
4= d.health;
}
Void Character:: setHair (string 1){
1= hair;
}
Void Character:: setEyes (string 2){
2= eyes;
}
Void Character:: setStrength (int a){
A= strength;
}
Void Character:: setHealth (int b){
B= health;
}
String Character:: getHair () const{
String 1;
Return 1;
}
String Character:: getEyes() const{
String 2;
Return 2;
}
Int Character:: getStrength () const{
Int a;
Return a;
}
Int Character:: getHealth () const{
Int b;
Return b;
}
Void Character:: addStrength (int a){
Strength= strength +1;
}
Void Character:: addHealth (int b){
Health = health +1;
}
Void Character:: loseStrength (int a){
Strength= strength – 1;
}
Void Character:: loseHealth (int b){
Health= health – 1;
}
Void Character:: print () const {
Cout<< “Enter patient’s hair color”<<endl;
Cin>> hair;
Cout<< “Enter patient’s eye color”<<endl;
Cin>> eyes;
Cout<< “Enter the patient’s strength”<<endl;
Cin>> strength;
Cout<< “Enter the patient’s health”<<endl;
Cin>> health;
}
Int main (){
//Character Person A, Person B(“black”, “brown”, 100, 100);
//Person B.print();
//character Person C (Person B);
//Person C.print();
Return 0;
}
************************************MAIN********** ***************************************
int main(){
Game g1(parameters);
Character p1 (parameters), p2 (parameters);
Venue forest (parameters);
g1.setLevel(5);
g1.setPlayerOne(p1);
g1.setPlayerTwo(p2);
g1.setLocation (forest);
meet(g1.playerone, g1.playertwo);
cout<<g1.playerone<<g1.Playertwo<<endl;
g1.teraform(50);
cout<<g1.Location<<endl;
int s=g1.Playerone.getStrength();
...........
************************************************** *****************************************
HERE IS THE OTHER CODE I HAVE SO FAR
Game.cpp
#include <string>
using namespace std;
#include "game.h"
Game:: Game (string 1, string 2, string 3, int a, int b, int c, int t){
1= PlayerOne;
2= PlayerTwo;
3= location;
a= level;
b= health;
c= strength;
t= teraform;
}
Game:: Game (const Game & d) {////maybe change the d see what it does- change rest of code
1= PlayerOne;
2= d.PlayerTwo;
3= d.location;
a= d.level;
b= d.health;
c= d.strength;
t= d.teraform;
}
Void Game:: setPlayerOne (string 1){
1= PlayerOne;
}
Void Game:: setPlayerTwo (string 2){
2= PlayerTwo;
}
Void Game:: setlocation (string 3){
3= location;
}
Void Game:: setlevel (int a){
a= level;
}
Void Game:: sethealth (int b){
b= health;
}
Void Game:: setstrength (int c){
c= strength;
}
Void Game:: setteraform (int t){
t= teraform;
}
String Game:: getPlayerOne () const{
string 1;
return 1;
}
String Game:: getPlayerTwo () const{
string 2;
return 2;
}
String Game:: getlocation () const{
string 3;
return 3;
}
String Game:: getlevel () const{
int a;
return a;
}
String Game:: gethealth () const{
int b;
return b;
}
String Game:: getstrength () const{
int c;
return c;
}
Int Game:: getlevel () const {
int a;
return a;
}
Int Game:: gethealth () const {
int b;
return b;
}
Int Game:: getstrength () const {
int c;
return c;
}
Int Game:: getteraform () const {
int d;
return d;
}
Void Game:: addlevel (int a) {
level= level +1;/////////// zero
}
Void Game:: addhealth (int b) {
health= health +1;
}
Void Game:: addstrength (int c) {
strength= strength +1;
}
Void Game:: addteraform (int t) {
teraform= teraform +1;////category rain fog sunny snow or do we need it
}
Void Game:: looselevel (int a) {
level= level -1;
}
Void Game:: loosehealth (int b) {
health= health -1;
}
Void Game:: loosestrength (int c) {
strength= strength -1;
}
Void Game:: looseteraform (int t) {
teraform= teraform -1;
}
Void Game:: print () const {
Cout<< PlayerOne <<endl;//change cout<<PlayerOne<<endl;
Cin>> PlayerOne;////change cin>>PlayerOne;
}
character.cpp
#include <string>
using namespace std;
#include "character.h"
Character:: Character (string 1, string 2, string 3, int a, int b, int c,){
1= PlayerOne;
2= PlayerTwo;
3= location;
a= level;
b= health;
c= strength;
}
Character:: Character (const Character & d) {////maybe change the d see what it does- change rest of code
1= PlayerOne;
2= d.PlayerTwo;
3= d.location;
a= d.level;
b= d.health;
c= d.strength;
}
Void Character:: setPlayerOne (string 1){
1= PlayerOne;
}
Void Character:: setPlayerTwo (string 2){
2= PlayerTwo;
}
Void Character:: setlocation (string 3){/////maynot need
3= location;
}
Void Character:: setlevel (int a){
a= level;
}
Void Character:: sethealth (int b){
b= health;
}
Void Character:: setstrength (int c){
c= strength;
}
String Character:: getPlayerOne () const{
string 1;
return 1;
}
String Character:: getPlayerTwo () const{
string 2;
return 2;
}
String Character:: getlocation () const{
string 3;
return 3;
}
String Character:: getlevel () const{
int a;
return a;
}
String Character:: gethealth () const{
int b;
return b;
}
String Character:: getstrength () const{
int c;
return c;
}
Int Character:: getlevel () const {
int a;
return a;
}
Int Character:: gethealth () const {
int b;
return b;
}
Int Character:: getstrength () const {
int c;
return c;
}
Void Character:: addlevel (int a) {
level= level +1;/////////// zero
}
Void Character:: addhealth (int b) {
health= health +1;
}
Void Character:: addstrength (int c) {
strength= strength +1;
}
Void Character:: looselevel (int a) {
level= level -1;
}
Void Character:: loosehealth (int b) {
health= health -1;
}
Void Character:: loosestrength (int c) {
strength= strength -1;
}
[