nvm got it.
Type: Posts; User: kpridd
nvm got it.
I have a fighting game where one player attacks another computer player causing both players to lose health.. I want to end the program once either players health gets to 0.. How would i go about...
thanks i tried something exactly like that i did user +1 guess that isn't incremental.. appreciate it.
I'm trying to figure out how to get a counter that will keep score so far everything i've tried wont work. I tried saying that if (outcome = lose) computer + 1 or something like that.. any ideas.
...
The way I have done it essentially works however
#include<iostream>
#include<string>
#include<cstdlib>
#include<ctime>
using namespace std;
Using inheritance, this program will allow the creation of different types of soldiers based on the Soldier base class. Each type of soldier should handle marching and fireing differently.
For...
thanks found them all
I'll mark where errors are coming up..
#include<iostream>
#include<string>
#include<cstdlib>
#include<ctime>
using namespace std;
Thanks I figured it out just wasn't putting them in brackets i guess.. Appreciate all your help
#include<iostream>
#include<ctime>
#include<cstdlib>
#include<string>
using namespace std;
int length, index1, index2, input, num, i, tries = 0;
string guess;
char temp;
okay last question and i think i got it why does it say i'm "jumping to case label" whenever i add case 2: into this
#include<iostream>
#include<ctime>
#include<cstdlib>
#include<string>
...
#include<iostream>
#include<ctime>
#include<cstdlib>
#include<string>
using namespace std;
int length, index1, index2, input, num, i, tries = 0;
string guess;
char temp;
Thanks everything seems to be working it gives me the correct numbers and it mixes them up. Only problem is that sometimes it randomly gives an empty space as a character? what could be causing that
cout << "Enter the number of symbols you would like to guess" << endl;
cin >> length;
sequence += SYMBOLS[GetRandNum(4)];
for (int...
what would "your_number" be equivalent too? the number they type in or just a randomly generated number?
i think one of the problems is because i reset length when i say
int length = sequence.size()
not sure what to do
ya thanks i just figured out the array i have this for my code to jumble
string sequence = SYMBOLS;
int length = sequence.size();
for (int i = 0; i <...
okay i get everything you stated except how to store the 4 symbols
const char SYMBOLS{ !, %, &, @}
i know what an array is.. would it be a two-dimensional array or just one? i tried this it...
This game should create a series of hidden symbols which the player needs to guess which symbols and the order. The symbols are !, @, &, and %. The string created using these symbols should have...