forums

TNT Basic Forums > Programming Q&A
Sprite Col
< Last Thread     Next Thread >
Author
Thread        Post A Reply

04-02-2003 14:10

Posted by:
eekaydee

Location:
CA, USA

Click Here to Email eekaydee   Find more posts by eekaydee

Hello.

I'm a little confused with the

Sprite Col(forSprite,fromSprite to toSprite)

command. This tests for collisions between forSprite and any sprite whose ID is between fromSprite and toSprite, right? In what form does this return values if there are multiple sprites colliding with forSprite?

04-02-2003 14:57

Posted by:
matteo

Location:
Venice, ITALY!

Click Here to Email matteo   Find more posts by matteo

<quote>
This tests for collisions between forSprite and any sprite whose ID is between fromSprite and toSprite, right?
<\quote>

yes

<quote>
In what form does this return values if there are multiple sprites colliding with forSprite?
<\quote>

this is the problem: it gives only one of the multiple sprites. Finally, I decided you better do your own loop to see if a sprite collides with others

i.e

for i=10 to 19
if sprite col (0,i)>-1 then sprite off i
next

instead of

a=sprite col (0,10 to 20)
if a >-1 sprite off a

04-02-2003 15:15

Posted by:
eekaydee

Location:
CA, USA

Click Here to Email eekaydee   Find more posts by eekaydee

Thanks!

All times are GMT        Post A Reply

Forum Jump:
< Last Thread     Next Thread >

< Contact Us - TNT Basic >

Powered by: vBulletin Lite Version 1.0.1 Lite
Copyright © Jelsoft Enterprises Limited 2000.