C ++ 공부중인데요 .. 도와주세요 opengl game programming 책 소스갖고계신분 ㅠ
제가 얼마전에 openGL Game Programming 책을 구해서 공부를 하는데요 ㅠ
뒤에 CD 가 없어서 소스를 책보고 하는데 오류가 너무 많이 나네요 ..
누가 도와주세요 ㅠㅠ
책저자는 Hawkins ,Astle
아 추가로
#include
#include
#include
#include "Object_ha.h"
#include "Vector.h"
#include "Table_ha.h"
static float puckData[32][3] =
{{0.0, 0.01, 1.0}, {0.3827, 0.01, 0.9239}, {0.7071, 0.01, 0.7071} ,
{0.9239, 0.01, 0.3827}, {1.0, 0.01, 0.0} , { 0.9239, 0.01, -0.3827} ,
{ 0.7071, 0.01, -0.7071} , {0.3827, 0.01, -0.9239}, {0.0, 0.01, -1.0} ,
{ -0.3827, 0.01, -0.9239} ,{ -0.7071, 0.01, -0.7071}, {-0.9239, 0.01, -0.3827} ,
{ -1.0, 0.01, 0.0} , { -0.9237, 0.01, 0.3827},{ -0.7071, 0.01, 0.7071} ,
{ -0.3827, 0.01, 0.9239}, {0.0, 0.07, 1.0}, {0.3827, 0.07, 0.9239},
{ 0.7071, 0.07, 0.7071} , {0.9239, 0.07, 0.3827} , { 1.0, 0.07, 0.0},
{0.9239, 0.07, -0.3827}, { 0.7071, 0.07, -0.7071} , { 0.3827, 0.07, -0.9239},
{ 0.0, 0.07, -1.0}, { -0.3827, 0.07, -0.9239} , { -0.7071, 0.07, -0.7071},
{-0.9239, 0.07, -0.3827}, { -1.0, 0.07, 0.0} , { -0.9237, 0.07, 0.3827} ,
{ -0.7071, 0.07, 0.7071} , {-0.3827, 0.07, 0.9239}};
class CPuck : public CObject_ha
{
private:
float radius;
public:
CPuck(void);
CPuck(float);
public:
~CPuck(void);
void Load();
void Unload();
void Draw();
void Animate(scalar_t deltaTime);
void Animate(scalar_t deltaTime, CTable_ha * table);
};
이거 전역선언 하는데서
c:\program files\microsoft visual studio\myprojects\game\puck.h(25) : error C2059: syntax error : '{'
이런 오류나는데요 이유아시는분 좀 가르쳐주세요 ㅠ
...;;;
신택스 오류라고 써이쓴데요... "{" 가 어딘가에 빠져 있다고...;;
봄들판에서다
봄들판에서다
이게요..
다른 소스창에다가 싱글로실행시키면 돌아가요 -_-;
유독 여기에 삽입하믄 저렇게떠요 ;
c:\program files\microsoft
c:\program files\microsoft visual studio\myprojects\game\puck.h(25) 이 파일
25번째줄이라는데요....;;;;;;;;
봄들판에서다
봄들판에서다
아 ㅋㅋ
음..그 위치가요...요기에요
잠시만요
#include
//#include
//#include
//#include
#include
//#include
#include
#include "Object_ha.h"
#include "Vector.h"
#include "Table_ha.h"
#include "puck.h"
static double playerData[32][3] =
{ <--------------------요기
{0.0, 0.01, 0.1}, { 0.3827, 0.01, 0.9239},
{0.7071, 0.01, 0.7071},{0.9239,0.01,0.3827},{1.0,0.01,0.0},
{0.9239, 0.01,-0.3827},{0.7071,0.01,-0.7071},{0.3827,0.01,-0.9239},
{0.0,0.01,-1.0},{-0.3827,0.01,-0.9239},{-0.7071,0.01,-0.7071},
{-0.9239,0.01,-0.3827},{-0.1,0.01,0.0},{-0.9237,0.01,0.3927},
{-0.7071,0.01,0.07071},{-0.3827,0.01,0.9239},
{0.0, 0.8, 0.1}, { 0.3827, 0.8, 0.9239},
{0.7071, 0.8, 0.7071},{0.9239,0.8,0.3827},{1.0,0.8,0.0},
{0.9239, 0.8,-0.3827},{0.7071,0.8,-0.7071},{0.3827,0.8,-0.9239},
{0.0,0.8,-1.0},{-0.3827,0.8,-0.9239},{-0.7071,0.8,-0.7071},
{-0.9239,0.8,-0.3827},{-0.1,0.8,0.0},{-0.9237,0.8,0.3927},
{-0.7071,0.8,0.07071},{-0.3827,0.8,0.9239}
};
#include
#include "Object_ha.h"
#include "Vector.h"
#include "Table_ha.h"
#include "puck.h"
이 파일중에 에러가 있을 거요.
잘 찾아보쇼.
댓글 달기