thanks so much for your help, guys. I really appreciate it. As you might guess, im rather new to c++, and don't know all the ins and outs of the language (such as enums).
You're right, I should...
Type: Posts; User: SnS CEO
thanks so much for your help, guys. I really appreciate it. As you might guess, im rather new to c++, and don't know all the ins and outs of the language (such as enums).
You're right, I should...
Zuk, when you get back online, I hope you can still see this message :P
I suspected that the problem was with offsets. Just to clarify, the x and y positions are 1-8, and the if a white piece...
Which line are you talking about?
This one?
int matrix[8][8] = { 1,0,1,0,1,0,1,0,
0,1,0,1,0,1,0,1,
1,0,1,0,1,0,1,0,
0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,
I once did a projectile motion program with inelastic bouncing, etc.
Unfortunately, I only did a simple air resistance based on the square of the velocity of the object, and not based on the...
Well, for the last week I've been at a dead end and have no idea whats wrong with my program. I am really hesitating on posting my whole entire program, just because I don't want to waste your whole...
caught my mistake, I just had a misplaced )
so I <i>was</i> passing it the right data type...
My specific question is: how do I fix this problem:
if(whitepiece[index].jumpup(xposition2, yposition2, matrix) == 0 && whitepiece[index].moveup(xposition2, yposition2, matrix == 0))
...
[DELETE]
I found it :p
well, it gives me the error on the first { of those 2 functions:
int getxcoord(void)
{ //The error it gives is on this line
char letter;
int x = 9;...
couldn't find anything... :(
was it a brace or a bracket that would be missing?
For some reason these 2 functions (which I copied from another program of mine that compiles fine) give me this error:
C:\Program Files\Microsoft Visual...
bump...
does anyone know why my program doesn't create all 8 instances, only the 1st 3rd 5th and 7th?
also:
xcoord = whitepawn[looper2].givexposition;
ycoord =...
hmm... I already changed my code over to that tut's format. I'm using VC++ 6.0. what's g++? I'm very new to advanced compiling.
and, strangely, it seems like only the 1st 3rd 5th and 7th pawns...
yea, ignore that earlier post, I completely replaced it.
you also bring up a good point. The name of the instance and the name of the class were the same. I have changed that now so that the...
UPDATE:
I have narrowed down my problem to using class arrays as function inputs. So...how do you use class arrays as function inputs?
also, to Orbitz:...
One quick question, I had a nice constructor for the old set up that took 2 values (x and y coordinates). I'm new to using arrays and classes in conjunction, so how exactly would I initialize the...
Ahh! An array! Why didn't I think of that? yes, that would solve the problem.
Thanks for the help! :)
Ok, so I have a class called wpawn (making a chess game) and have instances of wpawn called wpawn1 through wpawn8 (8 pawns on a chess board per side). I have a function that can "select" a piece by...