Collision between 2 objects help plz :)

Blitz3D Forums/Blitz3D Programming/Collision between 2 objects help plz :)

CodeOrc(Posted 2004) [#1]
I have a small character and a rotating hammer (level hazard). I have an interesting problem that I'm sure is my fault.

If I run straight into the hammer, then my health -1 just as it should.

But, if I stand still in the hammers path and the hammer comes around and hits me, nothing at all happens. The hammer just goes right through me.

What is it with the collision I am doing wrong? I have all the usuals, type, const, collision, entitycollided...

All my other collisions work just fine, object collection and other things like that. Does it have something to do with the character standing completly still?

thanx


jhocking(Posted 2004) [#2]
You've probably setup character to hammer collision detection but not vice versa. That said, just setting up hammer to character collision detection probably won't work well for you since Blitz collision detection is all sphere to something. You can use a trick like putting a collision sphere in the head of the hammer to just detect that, or use MeshesIntersect for exact collision detection, or invest in a collision detection dll like Nuclearglory.


jfk EO-11110(Posted 2004) [#3]
Additionally I want to mention that blitz may omit collsions (at least partially), when both objects are moving. probably you may call UpdateWorld(0) after moveing the first Object, and call it one more time, but this time as usual after moving the second object.