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.

Newcomers DBPro Corner / A strange problem with sprites in DBPro

Author
Message
ATHAN
21
Years of Service
User Offline
Joined: 11th Sep 2003
Location:
Posted: 29th Sep 2004 18:27
Hi,
I try to use the following code (that is working fine in DB ) with DBPro 5.6 that displays a single image on screen and waits for a keystroke.
The problem is that when I call load_dice function before the display_image, I see the image for a second or less, and then I get a blue screen!
After debugging I discover that the problem is with sprite commands! When I rem them there is no problem.

Why is happening and what is the solution on that?

thanks
Cybermind
Valued Member
21
Years of Service
User Offline
Joined: 28th Nov 2002
Location: Denmark
Posted: 29th Sep 2004 20:32
try and make a loop where you COPY BITMAP 20,0 and don't delete bitmap 20, that should keep bitmap on screen, that worked for me in DBC.
Sparda
20
Years of Service
User Offline
Joined: 13th Jan 2004
Location: Pacifica
Posted: 30th Sep 2004 00:15
If you delete the image that your sprite is using for it's source, than the sprite will also change. Finally, the blue screen appears because sprites are rendered as textured 3d plains. The blue screen is the infamous default backdrop for a 3d scene.

Is that your full code or just a piece of it? You need a loop or else your program will close. I guess I'm also not sure what the point of this is:


All it does is load a sprite and then instantly delete it. Maybe that is why you are not seeing your sprite on the screen?

My modification of your code:




Login to post a reply

Server time is: 2024-09-23 01:23:31
Your offset time is: 2024-09-23 01:23:31