Animated Door and Collision

Blitz3D Forums/Blitz3D Beginners Area/Animated Door and Collision

shawn4186(Posted 2008) [#1]
I know some similiar questions have been asked but I'm still having trouble with this - so I apologize in advance if it has been asked before. I have a door which I made and animated in 3D Canvas and has been converted to a B3D file. I have the code set up so that when the pivot/camera collides with the door it animates - rotates 90 degrees. This all works fine, but the problem is when I move through the now open doorway the camera/pivot still stops where the door used to be. Its as if Blitz3D does not realize the door has moved or in this case does not realize the animation has changed the position of the door. For the moment, to get around this and be able to move through the door, I simply set the doors collision type to zero after the animate command. I'm at work as I type this so can'y post any code.
Thanks you for any help!


Ross C(Posted 2008) [#2]
Your best to attach the door as a seperate entity, with it's own collision properties. Animated entities only check against the static first position. Also, make sure your collision sphere is small enough to go through the doorway.


shawn4186(Posted 2008) [#3]
OK thanks. So sounds like instead of checking to see if the camera pivot hit a door, I should loop through all the doors and see if they have hit the camera pivot? Is that what you mean by setting the doors up with their own collision properties?

Thanks again.


John Blackledge(Posted 2008) [#4]
As Ross C says, what's happening here is that Blitz is only checking for collisions against the first frame of the animation - the new opened position has not updated the collisions internal data.

When I realised this I let out a huge groan, and had to start a new piece of doors code based on pivots.


Naughty Alien(Posted 2008) [#5]
..and i will personally run away rom animated doors as a B3D files..instead, place pivot properly(at place where rotation center of the door is), and simply rotateentity it or turnentity it, depending what you prefer..thats way better method than use animated geometry for such task..