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.

2D All the way! / Truley the most stupid sprite problem

Author
Message
Penfold
20
Years of Service
User Offline
Joined: 3rd Dec 2003
Location: RED postbox houses of parliment
Posted: 19th Jan 2004 16:36 Edited at: 19th Jan 2004 16:59
I've been having abit of a problem with some code i've been writing....

text will not overlay a sprite unless its a sprite image itself

also now I've found out the sprite with the highest number will always overlay the lower number sprite,... this causes me a few problems to say the least..

I was wondering is there a way to fix these problems?

Oh and btw sprite collision only happens with the current sprite(targeter) and the topmost sprite of a stack if you have a stack.

'Ooh 'eck chief'...'crumbs'
the_winch
21
Years of Service
User Offline
Joined: 1st Feb 2003
Location: Oxford, UK
Posted: 20th Jan 2004 17:46 Edited at: 20th Jan 2004 17:49
Quote: "Oh and btw sprite collision only happens with the current sprite(targeter) and the topmost sprite of a stack if you have a stack."


Its a bug http://developer.thegamecreators.com/?m=forum_view&t=20670&b=15
To get correct collision you need to test for collision twice, once with one sprite as the target and the second time with the second sprite as the target. If both tests show a collision then there is a collision.

I think you can change the draw order of the sprites using SET SPRITE PRIORITY. I think the info in the dbpro helpfile may be slightly incorrect and I am not sure if SET SPRITE PRIORITY works properly.

The way I avoid the probelms is to avoid sprites. Use images and paste image, them you can draw the sprites in the order you want, overlay text and use your own accurite collision.

Can I scream?
Penfold
20
Years of Service
User Offline
Joined: 3rd Dec 2003
Location: RED postbox houses of parliment
Posted: 20th Jan 2004 20:06
@ the winch If I use images..which would be fine how would I get a transparency map on them.?

btw I'm using db classic.. so I'm not even sure theres a set sprite priority function.

'Ooh 'eck chief'...'crumbs'
Pincho Paxton
21
Years of Service
User Offline
Joined: 8th Dec 2002
Location:
Posted: 20th Jan 2004 20:28
If you want a scoreboard onscreen then you could put a border around the screen where sprites can't go. That's what I've done with my game.

Pincho.

Penfold
20
Years of Service
User Offline
Joined: 3rd Dec 2003
Location: RED postbox houses of parliment
Posted: 20th Jan 2004 20:44 Edited at: 20th Jan 2004 20:45
I've got a border round my screen...lol..but not for score boards...the problem is with the movable G.U.MPS...(they are currently the coloured spots.)

Graphical User Muppets...Lol

they don't want to overlay how I want them to...lol

'Ooh 'eck chief'...'crumbs'

Login to post a reply

Server time is: 2024-05-12 06:38:24
Your offset time is: 2024-05-12 06:38:24