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! / Sprite collision glitch

Author
Message
Levanthus
20
Years of Service
User Offline
Joined: 17th Apr 2003
Location: Cumbria, UK
Posted: 5th Sep 2003 20:44
I'm trying to make an adventure game in the same vein as MYST with mouse pointers that change as you move them over an image. i have it so that at the edges of the screen the pointer turns to point in the direction you can turn HOWEVER when i put the pointer over an item on the main part the pointer flickers between one and the other.... Any ideas people?

Are you a tool? can I step through to find another plane or just the shadow of a man?
CloseToPerfect
21
Years of Service
User Offline
Joined: 20th Dec 2002
Location: United States
Posted: 6th Sep 2003 00:19
sync
Levanthus
20
Years of Service
User Offline
Joined: 17th Apr 2003
Location: Cumbria, UK
Posted: 7th Sep 2003 16:31
good idea but sadly it didn't work
any others?

Are you a tool? can I step through to find another plane or just the shadow of a man?
IanM
Retired Moderator
21
Years of Service
User Offline
Joined: 11th Sep 2002
Location: In my moon base
Posted: 7th Sep 2003 17:35 Edited at: 7th Sep 2003 17:35
No

The reason? We have no idea what you have coded. Post some code and someone may be able to help you get it working
Levanthus
20
Years of Service
User Offline
Joined: 17th Apr 2003
Location: Cumbria, UK
Posted: 7th Sep 2003 18:32
Ok here's the code i can't see anything wrong with it hey who knows right?

Are you a tool? can I step through to find another plane or just the shadow of a man?
ReD_eYe
20
Years of Service
User Offline
Joined: 9th Mar 2003
Location: United Kingdom
Posted: 7th Sep 2003 21:35
i don't get why you hide the sprites every loop? surely you could put that outside the main loop?


Mentor
21
Years of Service
User Offline
Joined: 27th Aug 2002
Location: United Kingdom
Posted: 7th Sep 2003 21:36 Edited at: 7th Sep 2003 21:48
same with positioning them, you only need to position the pointer.




should work fine (haven`t tested it)

Mentor.

*********WARNING.. FORUM ATE BACKSLASHES****************************
Levanthus
20
Years of Service
User Offline
Joined: 17th Apr 2003
Location: Cumbria, UK
Posted: 8th Sep 2003 18:35
Thanks guys for the ideas, i am new at this HOWEVER i didn't solve the problem!! It only happens when pointerE (image 12/line 16) collides with Sprite 6!! if i use any other pointer it works fine it just doesn't like that specific one!? any ideas?? i don't know what to do it's driving me mad!!

Are you a tool? can I step through to find another plane or just the shadow of a man?
CloseToPerfect
21
Years of Service
User Offline
Joined: 20th Dec 2002
Location: United States
Posted: 9th Sep 2003 08:08
can you try this out? just paste it over the code after your load image commands.



I think it might work for you, But I didn't make any images to test it out.

CTP
Levanthus
20
Years of Service
User Offline
Joined: 17th Apr 2003
Location: Cumbria, UK
Posted: 9th Sep 2003 18:41
Thanks for all the help and advice, i have the problem solved now thank you all for your help... believe it or not, it was the colour of the sprite apparently, the one i was TRYING to use was originally dark red, i re-coloured the sprite to be white and it worked fine. sorry if i wasted anyones time but again thanks for the ideas and help.
Levanthus

Are you a tool? can I step through to find another plane or just the shadow of a man?
heartbone
21
Years of Service
User Offline
Joined: 9th Nov 2002
Location:
Posted: 10th Sep 2003 08:15
It sounds strange but the sprite color does make a difference in collision detection using DBClassic.
Three sprites (rgb values)
one 255,0,0
one 0,255,0
and the third 0,0,255
That combination will not allow collisions to be detected.

After many long hours of debugging I had a desperate strange thought,
maybe Windows was assuming something about the sprite colors

So on that hunch I made them
255,32,32
32,255,32
32,32,255
and the code started working!

I guess there has to be some commonality of color before a collision can be detected. Windows strangeness?

The more you see, the more you know.
The more you know, the more you see.

Login to post a reply

Server time is: 2024-03-02 17:16:24
Your offset time is: 2024-03-02 17:16:24