Soft Collision
by rpi (#0009) · in Torque Game Engine · 03/24/2005 (5:31 pm) · 2 replies
Hello,
I am working on a game and I'm having a problem with an item (or rather, the result of an item) and it's collision detection. The item is a bottle of glue, and it is supposed to pour out a puddle of glue onto the floor, which works just fine, the trouble is that when a player walks over the puddle they rarely collide with it. Walking over the puddle of glue slows the player's movement speed for a while, which also works fine, when the collision does happen.
I do not understand what the collison on the puddle is doing. It seems to work at random. The only thing that consistently works to trigger a collision is jumping on the object. Walking over it will collide sometimes and not others and the direction you walk over it from does not seem to be a determining factor in the collision working or not. The glue puddle model (and it's collision mesh, which is the same shape as the model) is raised slightly up off the floor and the player seems to walk right over it without touching it most of the time, but then sometimes it will collide and work fine.
Does anyone have any idea why it would act this way?
Thanks
I am working on a game and I'm having a problem with an item (or rather, the result of an item) and it's collision detection. The item is a bottle of glue, and it is supposed to pour out a puddle of glue onto the floor, which works just fine, the trouble is that when a player walks over the puddle they rarely collide with it. Walking over the puddle of glue slows the player's movement speed for a while, which also works fine, when the collision does happen.
I do not understand what the collison on the puddle is doing. It seems to work at random. The only thing that consistently works to trigger a collision is jumping on the object. Walking over it will collide sometimes and not others and the direction you walk over it from does not seem to be a determining factor in the collision working or not. The glue puddle model (and it's collision mesh, which is the same shape as the model) is raised slightly up off the floor and the player seems to walk right over it without touching it most of the time, but then sometimes it will collide and work fine.
Does anyone have any idea why it would act this way?
Thanks
#2
B--
03/24/2005 (7:15 pm)
Have you considered making the collision mesh taller? Why not make it half the height of your other models, instead of it being just a little off the ground. Just a thought...B--
Torque Owner Ishbuu
If it is a very complex model (I've been stuck with this before) you might want to call an "onEnter" function. You could do this by setting the blob as an item (itemdata) and then slowing the player that enters the blob down. You'll need some speed variables in the player, I found a thread on it looking around a while ago, take a look Here
Note that I'm not sure this works completely, but might be worth a look. :)
[Ishbuu]