well....i am farily new at this, and i just wanted to test out placing objects around, so i loaded a skybox, and then loaded an object, but when i run it, it freezes up on me, and i have to do CTRl + ALT + DEL to fix, and its aggrivating, but when i delete the code that the object is it runs fine showing the skybox and moving, its something wrong with the object, can some one please look at the code and help me out, thank you
// whenever using Dark GDK you must ensure you include the header file
#include \"DarkGDK.h\"
// the main entry point for the application is this function
void DarkGDK ( void )
{
// go fullscreen
dbSetWindowLayout(0, 0, 0);
dbMaximizeWindow();
// turn on sync rate and set maximum rate to 60 fps
dbSyncOn ( );
dbSyncRate ( 60 );
dbSetCameraRange ( 1.0f, 30000.0f );
// load a model for our sky
dbLoadObject ( \"pln.x\", 2 );
dbSetObjectLight ( 2, 0 );
dbSetObjectTexture ( 2, 3, 2 );
dbScaleObject ( 2, 30000, 30000, 30000 );
//load plane model
dbLoadObject (\"plane.3ds\", 3 );
dbPositionObject (3,200,200,200);
// position the camera
dbPositionCamera ( 0,50, -80 );
// camera variables
float fCameraAngleX = 0.0f;
float fCameraAngleY = 0.0f;
// our main loop
while ( LoopGDK ( ) )
{
// move the camera using the arrow keys
dbControlCameraUsingArrowKeys ( 0, 5.0f, 0.3f );
// create a rotation axis based on mouse movement
fCameraAngleX = dbWrapValue ( fCameraAngleX + dbMouseMoveY ( ) * 0.4f );
fCameraAngleY = dbWrapValue ( fCameraAngleY + dbMouseMoveX ( ) * 0.4f );
// rotate camera
dbXRotateCamera ( fCameraAngleX );
dbYRotateCamera ( fCameraAngleY );
// update the screen
dbSync ( );
}
// return back to windows
return;
}