Could you specifically outline the code thats "broken" and what your specific problem is? Most of us really dislike having to download source, get the libraries, compile/build, then figure out whats wrong (can vary depending on what your view of 'wrong' is).
Also, for future reference: http://www.pastebin.com is a fantastic site for collaborative debugging.
Thanks.
Isaac Asimov wrote:Part of the inhumanity of the computer is that, once it is competently programmed and working smoothly, it is completely honest.
One way you might consider when writing argument names which are almost identical to some members in your class, is using the this keyword and the arrow operator (->) to make things clearer (it also means you don't have to worry about running out of relevant keywords)
for example, you would implement your first chunk of code like this:
void GameSetUp::SetCoor(int x, int y, int Tempx, int Tempy)
{
this->x = x;
this->y = y;
this->tempx = Tempy;
this->tempx = Tempy;
}
PS: I didn't look at the rest of your code, I really don't have the time at the moment, but I hope you solve the problem in a stress-free and timely manner.
Maybe you should explain exactly what's wrong, if you need anymore help.
---------------------------------------------------------------------------------------
I think I can program pretty well, it's my compiler that needs convincing!
--------------------------------------------------------------------------------------- And now a joke to lighten to mood :D
I wander what programming language anakin skywalker used to program C3-PO's AI back on tatooine? my guess is Jawa :P
Click here to see the hidden message (It might contain spoilers)
PART 1
R: What do you want for breakfast, L?
L: Well, let's see. I want tacos, waffles, and snickerdoodle.
A: Snickerdoodle?
R: Tacos and waffles don't go together, L.
L: I know that, R. A, snickerdoodle is a German cookie.
A: Well, whay didn't you say so, L? My butt just got equiped with a cookie gun!
R and L: Gun?
R: Run, L, A is gonna shoot us with his...
...whatever it is called!!!! Come on, L!
(L gets hit in the back of the head with a cookie and becomes unconsis.)
R: L!?
(Cookies fly everywhere, but R manages to escape)
A: It's going out of control!!!!! I can't stop it! Ohh......
(A explodes with a loud and thunderous BAM POP SLASH!)
The house (which belongs to L) no longer existed. A blew up and left R wondering what happened to A and L. R checked out the scene and saw no trace of A or L. There were many questions to be asked: Where is L and A? Is L and A alive? How did A get a cookie gun in his a**? No one knew the answer.
Arrays start at 0, so what you're doing here is assigning the value that happens to reside somewhere outside the array m to the array map; or actually you're not assigning it to the map array, it's outside that one too.
You should read more on arrays and understanding them, it will make this task much easier.
Arrays start at 0, so what you're doing here is assigning the value that happens to reside somewhere outside the array m to the array map; or actually you're not assigning it to the map array, it's outside that one too.
You should read more on arrays and understanding them, it will make this task much easier.
also, you can't just assign an array to an array in c++ AFAIK, you initialise an array by either including braces and the list of values you wish to initialise the array with, or you could use some iteration to assign those values to the correct corresponding arrays, for example, for a 2 dimensional array, some nested for loops will usually suffice.
for(int i = 0; i < 24; i++)
{
for(int j = 0; j < 32; j++)
{
map[i][j] = m[i][j]
}
}
// just as a side note, I would recommend using constants instead of 24 and 32
// you'll end up having inconsitent numbers which could lead to bugs if you
// don't have identifiers that you only have to change once
---------------------------------------------------------------------------------------
I think I can program pretty well, it's my compiler that needs convincing!
--------------------------------------------------------------------------------------- And now a joke to lighten to mood :D
I wander what programming language anakin skywalker used to program C3-PO's AI back on tatooine? my guess is Jawa :P