Game Development Community

Collision with mounted objects

by Bruno Grieco · in Torque Game Engine · 06/22/2004 (4:51 pm) · 5 replies

Guys,

Continuing Crowmania development, I've installed a very nice extensible propeler on my plane. When I click the mouse it extends in a cartoonish way to chop off those damn crows...

The problem : It doesn't collide with crows. It passes right thru them. The crows do collide with the plane ( which is the way they are meeting their fate ) but they don't collide with the propeller itself.

I beleive that's because the propeller is a mounted weapon. Is there any workaroud for this ? How do you manage spears and swords for close combat ?

#1
06/22/2004 (5:37 pm)
Mounted objects can have collision with other objects ,the problem is because you dont have a collision mesh with your weapon.
#2
06/22/2004 (6:03 pm)
I checked that out.

I'm using Lightwave and I have the collision mesh exported as a bounding box option checked.

So unless there is something else I have to do, it's being exported.
#3
06/22/2004 (6:19 pm)
Its as a mountedImage I suggest you look through that class (vaguely remeber a comment about image collision in there). I know its already possible as they did weapon pushback before 1.2
#4
06/22/2004 (8:52 pm)
Are you using animation for the propeller or rotating it in code? I don't think the collision meshes animate with the model. (At least, I don't know how.)
#5
06/23/2004 (7:32 am)
Ok, here goes the report :

Cameron is right, collision meshes don't like to be animated. So I used it on my behalf.
I created a new object to serve as the colision mesh that represents the whole extended propeller.
When idle, I EXPORT the collision node with the animation. That makes the collision mesh disappear ( I'checking with a visible colmesh ). When I push the trigger I don't export the node, so the colmesh appears hence yielding collisions !

But still : The collision reports as being with the flying vehicle. I will have to test if I can set the proppeler::onCollision now.

Thanks guys.