Help with "bug" in animcoll, Gernot.

Previous topic - Next topic

ampos

It seems that the reason my program crashes is due to ANIMCOLL.

I need to check collision between a non-anim sprite and an animated sprite, so I used:
(brick is the animated sprite)

col=animcoll(ball,0,xb,yb,brick,xbr,ybr)

at first I though that the error is because using frame 0 as frame for the non-anim sprite, and changed to 1. It seems to work for a while, but again it crashes again.

Can a non-animated sprite used in animcoll?

I would try to change the sprites, so to sent as first param the anim sprite and the 2nd the non-anim, but I think it will no be the solution.

should I change the ball into an anim sprite to avoid the error?

MrTAToad

Animated and non-animated sprites can be used with ANIMCOLL - the non-animated sprite should have an tile1 or tile2 value of 0

Kitty Hello

Make a reproducible example, please.

ampos

Quote from: Kitty Hello on 2011-Jan-13
Make a reproducible example, please.

Buff, I will try.

As few test has been done, ANIMCOLL has a bug. I have changed ANIMCOLL with SPRITECOLL and got no crashes.

If you want to check something, I am using coordinates with decimals, .types, around 30 collision detections per frame.

MrTAToad

Trouble is, we need to see your code :)

Kitty Hello

You can email it to me, if you have a way to really reproduce it.

ampos

I will sent later from home.

They way to reproduce it is playing. If in 1 minute it did not crash, stop, F5 and try again.