Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Dark GDK / collision help

Author
Message
Patrick987
15
Years of Service
User Offline
Joined: 22nd Jun 2009
Location:
Posted: 26th Jun 2009 00:03
im trying to make an asteroids clone but whenever an asteroid hits a bomb i place the bomb disappears but the asteroid keeps moving down even though i call dbDeleteSprite() on the asteroid
Marsh0
15
Years of Service
User Offline
Joined: 18th Mar 2009
Location:
Posted: 26th Jun 2009 03:20
Are you recreating the asteroid in the loop?

Try dbHideSprite() instead of Delete.

Also i cant really tell without the source code.
Patrick987
15
Years of Service
User Offline
Joined: 22nd Jun 2009
Location:
Posted: 26th Jun 2009 20:21
i figured it out but thanks for the suggestion im havin a new problem now whenever a meteor gets destroyed an animation for an explosion is supposed to play but it stops at the first frame void cMeteor::drawMeteor()
{
dbSprite( spriteID, xpos, ypos, spriteID );
if( destroyMeteor( spriteID, 4 ) == true )
{
dbCreateAnimatedSprite( 5, "explosion.png", 3, 3, 5 );
dbSprite( 5, xpos, ypos, 5 ):
dbPlaySprite( 5, 2, 7, 0 );
ypos = 0;
xpos = dbRND( 464 );
dbDeleteSprite(4);
}
}
Patrick987
15
Years of Service
User Offline
Joined: 22nd Jun 2009
Location:
Posted: 26th Jun 2009 20:54
i figured it out but thanks for the help and i have a new problem now whenever an asteroid is destroyed an animation is supposed to play but only the first frame plays

Login to post a reply

Server time is: 2024-11-25 08:26:11
Your offset time is: 2024-11-25 08:26:11