sprite to background collision ?

Blitz3D Forums/Blitz3D Beginners Area/sprite to background collision ?

Dax Trajero(Posted 2004) [#1]
I need to check if the non-transparent areas of my 32x32 sprite have collided with the non-transparent pixels of a collision bitmap

Can someone advise the best command to use for this.


Dax Trajero(Posted 2004) [#2]
ok, ok, I got it

for my large collision bitmap, I have to use LoadAnimImage and
create 1 big frame

then use

imagescollide(sprite,x,y,SprFrame,bitmap,x,y,BitmapFrame)


LarsG(Posted 2004) [#3]
if the collision bitmap is very big, then you can also grab the area around the 32x32 sprite (after drawing the background, but before drawing it on screen), and check collisions against those two..