That did not work because you cant see the bounds for polygon objects. Here is the code, mabey you can work it out from this because I cant :
// Dark GDK - The Game Creators - www.thegamecreators.com
// the wizard has created a very simple project that uses Dark GDK
// it contains the basic code for a GDK application
// whenever using Dark GDK you must ensure you include the header file
#include "DarkGDK.h"
#include "SC_Collision.h"
void update_objects(void);
// the main entry point for the application is this function
void DarkGDK ( void )
{
SC_Start();
// turn on sync rate and set maximum rate to 60 fps
dbSyncOn ( );
dbSyncRate ( 60 );
dbLoadObject("Media//Atomiser.x",10);
dbLoadObject("Media//l1.X",20);
dbPositionObject(20,0,0,100);
SC_SetupObject(10,1,0);
SC_SetupObject(20,2,0);
dbRotateObject(20,0,-135,55);
dbRotateObject(10,-90,0,0);
dbPositionObject(10,10,-15,20);
dbLockObjectOn(10);
// our main loop
while ( LoopGDK ( ) )
{
SC_DrawObjectBounds(20);
update_objects( );
// update the screen
dbSync ( );
}
// return back to windows
return;
}
void update_objects(void)
{
int collides=0;
if (SC_ObjectCollision (10,20));
{
collides=1;
}
char diff[256]; //show the time
sprintf(diff,"collide: %d",collides );
dbText( 10, 50, diff);
dbPositionCamera(dbCameraPositionX(),50,dbCameraPositionZ());
dbControlCameraUsingArrowKeys(0,2.0f,2.0f);
}