Hiii!!
I have done this code:
Code:typedef struct strBlock { int x; //Position board int y; } Block; /* The structure Card, is a form with four blocks */ typedef struct strCard { int type; Block Bl[4]; //Each card is 4 blocks } Card;But I think that this part is wrong:Code:// movement of block down void downblock(block * l) { int i; for(i=0;i<4;i++) l->Bl[i].y++; }
someone can help me?Code:// movement of left block void leftblock(block * l) { int i; for(i=0;i<4;i++) l->Bl[i - 1].y++; } // movement of right block void rightblock(block * l) { int i; for(i=0;i<4;i++) l->Bl[i + 1].y++; }
Thanks^^




Reply With Quote